Use app×
QUIZARD
QUIZARD
JEE MAIN 2026 Crash Course
NEET 2026 Crash Course
CLASS 12 FOUNDATION COURSE
CLASS 10 FOUNDATION COURSE
CLASS 9 FOUNDATION COURSE
CLASS 8 FOUNDATION COURSE
0 votes
384 views
in Server Side Scripting Using PHP by (29.4k points)
closed by

What is the difference between PHP and JavaScript?

1 Answer

+1 vote
by (30.3k points)
selected by
 
Best answer

Client side scripts(JavaScript) are run faster but it has some limitations. The limitations are we can view the source code hence it is less secure. On the other hand PHP is executed on the server and the result is sent back to the client(browser) so it is impossible to view the source code.

Benefits of using PHP

Client side scripts(JavaScript) are run faster but it has some limitations. The limitations are we can view the source code hence it is less secure. On the other hand PHP is executed on the server and the result is sent back to the client(browser) so it is impossible to view the source code.

Benefits of PHP are given below 

  • As PHP can be easily embedded into HTML moreover its easiness to convert a static website into a dynamic one.
  • It is compatible with almost all databases
  • It is platform independent can run on almost all OS (Windows, Linux, MAC)
  • It is simple and easy to learn 
  • It uses very small amount of system resources to run and faster.
  • PHP provides security to prevent malicious attacks.
  • Open source community supports PHP
  • It is a free s/w by all means hence can be used to develop all types of web sites.
by (10 points)
+1
PHP and JAVA Script  they both have different purposes for web-site development. PHP is a server-side scripting language while. JavaScript is a client-side scripting language and both are the versatile programming languages used for website development.
PHP can handle forms, save data to a file, return data to the user, gather data from files, etc and JavaScript is designed for creating network-centric applications.

Welcome to Sarthaks eConnect: A unique platform where students can interact with teachers/experts/students to get solutions to their queries. Students (upto class 10+2) preparing for All Government Exams, CBSE Board Exam, ICSE Board Exam, State Board Exam, JEE (Mains+Advance) and NEET can ask questions from any subject and get quick answers by subject teachers/ experts/mentors/students.

...