Tech
Forums
Jobs
Books
Events
Interviews
Live
More
Learn
Training
Career
Members
Videos
News
Blogs
Contribute
Article
Blog
Video
Ebook
Interview Question
Collapse
Feed
Dashboard
Wallet
Learn
Achievements
Network
Rewards
SharpGPT
Premium
Contribute
Article
Blog
Video
Ebook
Interview Question
Register
Login
An Introduction To PHP
WhatsApp
Monika Rameshkumar
4y
3.7
k
0
1
25
Blog
PHP1.zip
What is PHP?
PHP stands for Hyper Text Preprocessor.
It is an Open-Source widely used scripting language.
It works on server side scripting language.
It is easy to use and free to download.
What is PHP File?
It the combination of HTML, CSS, and JavaScript, along with PHP Code.
It has an extension as ".php".
Why PHP?
It supports and runs on various platfoms (Windows, Linux, Unix, etc.).
It is compatible with all servers used to date (XAMPP, Apache, etc.).
It supports a wide range of databases.
It is free to download from the official site of PHP:
www.php.net.
PHP Syntax
Basic PHP Syntax
The PHP script starts with<?phpand it ends with?>
It can be placed anywhere in the document..
<?php
//PHP Code
?>
Here is the first most basic coding for PHP.
I have written the basic code to print "ALL THE BEST".
Is PHP Case-Sensitive?
In PHP, classes, functions, keywords (eg: echo, if, else, etc..), user-defined functions are case sensitive.
PHP Comments
The Comment lines are used to make the code more understandable and for ease of use.
Mostly, Command lines let others understand your code.
Most programmers have a habit of looking back on their own code for future reference.
The comment lines helps you to remind you what you were thinking, when you wrote the code.
Two types of Comment Lines
Single Line Comment(// , #)
<?php
// This is a single-line comment
# This is also a single-line comment
?>
Multiple Line Comment (/*...*/
<?php
/*
This is a multiple-lines comment
*/
?>
These are all the basics for an Introduction to PHP.
Here I have attached example coding for the above topics. Kindly refer to it.
Thank you!.
PHP-echo
Up Next
CRUD Operation On A User Profile In PHP/ MySQL
Ebook Download
View all
Printing in C# Made Easy
Read by 22.3k people
Download Now!
Learn
View all
Membership not found