r/AskProgrammers • • Nov 03 '26

Javascript or SQL and PHP?

Hello. I recently thought to start learning how to code because it's something I've found quite interesting for the last year or so.

I was originally gonna start with Javascript, but I asked a few co-workers at work (I work in IT) and some of them told me to learn SQL and PHP first then Javascript.

So what would it be worth to learn first?. Sorry if this is a stupid question, but I thought to ask actual people instead of AI.

3 Upvotes

18 comments sorted by

6

u/OkNothing7293 Nov 03 '26

The language doesn’t really matter. My advice is to learn programming and not web development. Start from first principles and go from there.

1

u/isotonicNK Nov 03 '26

How do you think I should go about it?

2

u/theancientfool Nov 03 '26

If you want quick results, I'd say php. And to be honest, you will learn js anyway as it's used for front end. Learning two languages together worked better for me, as it meant my tought process was adaptable from the start. But others might differ.

1

u/feudalle Nov 03 '26

This is the answer. Over the years you are going to learn alot of languages. I know about 40. But as time goes on it what you use changes. I dont get a lot of calls for qbasic, fortran, perl, or asp classic these days. Learning the fundamentals is what's important after that its keywords and syntax.

1

u/Icemourne_ Nov 03 '26

It really depends what you want to make and why are you looking to learn if you want job PHP SQL if you just looking to make website or something for fun JavaScript or better typescript

1

u/isotonicNK Nov 03 '26

I wanna learn it for myself. I like learning new things

1

u/Icemourne_ Nov 03 '26

If you don't have anything specific in mind and just want to learn I would suggest browser extension adding something to some website and don't use libraries or AI

Reason it's difficult and requires fundamentals of language and understanding how stuff works but not something to difficult

1

u/Ronin-s_Spirit Nov 03 '26

These 2 things are entirely orthogonal.

1

u/isotonicNK Nov 03 '26

And that means?...

1

u/Ronin-s_Spirit Nov 05 '26

Google "orthogonal".

p.s. actually no, all 3 things are entirely separate. You can learn SQL or Python or JS, the last 2 being code and not needing a database language and the first one being a database language and neeing some code that doesn't even have to be Python or JS.

1

u/W31337 Nov 03 '26

JavaScript

1

u/Usual-Cricket-9817 Nov 03 '26

Weird options to choose from.

A) A programming language. B) Another programming language and DB language

1

u/atticus2132000 Nov 03 '26

More than likely you'll need to learn all at the same time, at least get functional working knowledge of each.

JavaScript controls front-end development--what happens on the user's computer as he or she is interacting with your webpage. PHP controls what happens on the back-end, the server. SQL is a way of storing information in a database on the server-side of things (SQLite would be a database on the user's computer).

More than likely your most involved scripting is going to be JavaScript with a few lines of PHP and SQL sprinkled in to handle user requests.

0

u/[deleted] Nov 03 '26

[removed] — view removed comment

1

u/isotonicNK Nov 03 '26

Should I not bother with PHP at all?

1

u/[deleted] Nov 03 '26

Choose one language to start off with. A lot of principles from javascript are similar to other higher level languages like php, python, etc. Once I got deep into learning js/ts it was easy for me to switch over to php/python/java