hi
friends i’m new to use php,
and want to know how to start php
Install PHP on your computer (I don’t know much about that) or hire a standard hosting account and a domain name – very cheap – which has PHP installed: very standard. Then make a plain text file with some PHP in, eg
<?php
echo "<h1>1 + 1 = ", 1+1, “</h1>”;
?>
save it as test.php. Using a piece of FTP software (having inserted necessary details into it which you’ll get when opening hosting account) upload that file into the HTML/public directory. Then type yourdomain.com/test.php into address bar of browser.
The easiest way for starters is to use WAMP (a program that will install Apache, MySQL and PHP on a Windows computer) or XAMP (for MAC) to install PHP.
WAMP url (if you have windows) : http://www.wampserver.com/en/
XAMPP url (if you have a MAC) : https://www.apachefriends.org/index.html
Then, you should have a directory where you can put your PHP file (with WAMP it will be c:\wamp\www). The first thing you could do is create a file named ‘index.php’ with this in it:
<?php
phpinfo();
?>
Now, you should be able to call in your browser the URL http://localhost, which is the URL of your own computer where you just installed a PHP server (with WAMP or XAMPP). This URL will call your local PHP server and will execute the file index.php by default.
If it works, you should see a page with a lot of information about your PHP installation.
This is one of the best websites i have come across http://www.tizag.com/phpT/ i still use it as a quick lookup for certain things. Once you get the hang of PHP you will want to look at mysql which is a database you can access using your php pages.
hth