Home > Article > Backend Development > Which one is more difficult, js or php?
There is no doubt that JavaScript is more difficult than other scripting languages, such as python, perl, and vbscript. The difficulty here is mainly that it is difficult to master and difficult to master.
Why is it so difficult? The main reason is that JavaScript does too many things and the details of processing are too trivial. It handles DOM, Ajax, BOM, and is compatible with browsers. To make animations, special effects, and operate mongo database b and subset json, you need to master not only JavaScript, but also css, html, web standards, etc.
There are also compatibility issues with various browsers, the complexity of the DOM itself, and various frameworks. Newcomers recommend jquery. Who said jquery is outdated? jquery provides a series of APIs for operating DOM, which is very convenient. Of course, Vue is not unusable, but for newbies, jquery is more intuitive and vue is more abstract.
Let’s take a look at what PHP does, handle the business logic, operate the database, return the results to the front end, do some image compression, generate some files... Is there anything else? It seems to be gone.
And the two methods are very similar. PHP has a large number of built-in functions. You basically don’t need to remember them. You can just check them as you go.
Talking about wheels, PHP only has a few things on the back end, so the number of wheels is very stable. The most popular one is OOPHP's Laravel, which also takes advantage of Vue. The wheels of JavaScript may be more hairy than my legs, so I won’t list them all.
I haven’t even mentioned node es6 yet. The front-end is developing so fast that even before a wheel is finished, newer and more advanced wheels are coming out. You have just learned a wheel halfway, and it is officially declared invalid. If you don't want to fall behind, you can't slack off.
For more PHP related knowledge, please visit php中文网!
The above is the detailed content of Which one is more difficult, js or php?. For more information, please follow other related articles on the PHP Chinese website!