1/23/24, 11:27 PM PHP Introduction
Tutorials Exercises Services Sign Up Log in
HTML
CSS JAVASCRIPT SQL PYTHON JAVA PHP HOW TO W3.CSS C
PHP Introduction
❮ Previous Next ❯
PHP code is executed on the server.
What You Should Already Know
Before you continue you should have a basic understanding of the following:
HTML
CSS
JavaScript
If you want to study these subjects first, find the tutorials on our Home page.
What is PHP?
PHP is an acronym for "PHP: Hypertext Preprocessor"
PHP is a widely-used, open source scripting language
PHP scripts are executed on the server
PHP is free to download and use
PHP is an amazing and popular language!
It is powerful enough to be at the core of the biggest blogging system on the web
(WordPress)!
https://www.w3schools.com/php/php_intro.asp 1/6
1/23/24, 11:27 PM PHP Introduction
It is deep enough to run large social networks!
It is alsoTutorials
easy enoughExercises Services
to be a beginner's language!
server side
first Sign Up Log in
HTML
CSS JAVASCRIPT SQL PYTHON JAVA PHP HOW TO W3.CSS C
What is a PHP File?
PHP files can contain text, HTML, CSS, JavaScript, and PHP code
PHP code is executed on the server, and the result is returned to the browser as
plain HTML
PHP files have extension " .php "
What Can PHP Do?
PHP can generate dynamic page content
PHP can create, open, read, write, delete, and close files on the server
PHP can collect form data
PHP can send and receive cookies
PHP can add, delete, modify data in your database
PHP can be used to control user-access
PHP can encrypt data
With PHP you are not limited to output HTML. You can output images or PDF files. You
can also output any text, such as XHTML and XML.
ADVERTISEMENT
Sider - Free ChatGPT Chatbots
ChatGPT Browser Plugin as your AI assistant on any page
Sider Open
https://www.w3schools.com/php/php_intro.asp 2/6
1/23/24, 11:27 PM PHP Introduction
Tutorials Exercises Services Sign Up Log in
Why PHP?
HTML
CSS JAVASCRIPT SQL PYTHON JAVA PHP HOW TO W3.CSS C
PHP runs on various platforms (Windows, Linux, Unix, Mac OS X, etc.)
PHP is compatible with almost all servers used today (Apache, IIS, etc.)
PHP supports a wide range of databases
PHP is free. Download it from the official PHP resource: www.php.net
PHP is easy to learn and runs efficiently on the server side
What's new in PHP 7
PHP 7 is much faster than the previous popular stable release (PHP 5.6)
PHP 7 has improved Error Handling
PHP 7 supports stricter Type Declarations for function arguments
PHP 7 supports new operators (like the spaceship operator: <=> )
❮ Previous Log in to track progress Next ❯
ADVERTISEMENT
https://www.w3schools.com/php/php_intro.asp 3/6
1/23/24, 11:27 PM PHP Introduction
Tutorials Exercises Services Sign Up Log in
HTML
CSS JAVASCRIPT SQL PYTHON JAVA PHP HOW TO W3.CSS C
https://www.w3schools.com/php/php_intro.asp 4/6
1/23/24, 11:27 PM PHP Introduction
COLOR PICKER
Tutorials Exercises Services Sign Up Log in
HTML
CSS JAVASCRIPT SQL PYTHON JAVA PHP HOW TO W3.CSS C
ADVERTISEMENT ADVERTISEMENT
Sider - Free ChatGPT Sider - Free ChatGPT
Chatbots Chatbots
ChatGPT Browser Plugin as your AI ChatGPT Browser Plugin as your AI
assistant on any page assistant on any page
Sider Sider
SPACES UPGRADE AD-FREE
NEWSLETTER GET CERTIFIED REPORT ERROR
Top Tutorials Top References
HTML Tutorial HTML Reference
CSS Tutorial CSS Reference
JavaScript Tutorial JavaScript Reference
How To Tutorial SQL Reference
SQL Tutorial Python Reference
Python Tutorial W3.CSS Reference
W3.CSS Tutorial Bootstrap Reference
Bootstrap Tutorial PHP Reference
https://www.w3schools.com/php/php_intro.asp 5/6
1/23/24, 11:27 PM PHP Introduction
PHP Tutorial HTML Colors
Java Tutorial
Tutorials
C++ Tutorial
Exercises Services Java Reference
Angular Reference
Sign Up Log in
jQuery Tutorial jQuery Reference
HTML
CSS TopJAVASCRIPT
Examples SQL PYTHON JAVACertified
Get PHP HOW TO W3.CSS C
HTML Examples HTML Certificate
CSS Examples CSS Certificate
JavaScript Examples JavaScript Certificate
How To Examples Front End Certificate
SQL Examples SQL Certificate
Python Examples Python Certificate
W3.CSS Examples PHP Certificate
Bootstrap Examples jQuery Certificate
PHP Examples Java Certificate
Java Examples C++ Certificate
XML Examples C# Certificate
jQuery Examples XML Certificate
FORUM ABOUT
W3Schools is optimized for learning and training. Examples might be simplified to
improve reading and learning.
Tutorials, references, and examples are constantly reviewed to avoid errors, but we
cannot warrant full correctness
of all content. While using W3Schools, you agree to have read and accepted our terms of
use, cookie and privacy policy.
Copyright 1999-2024 by Refsnes Data. All Rights Reserved. W3Schools is Powered by
W3.CSS.
https://www.w3schools.com/php/php_intro.asp 6/6