our approach
|
new tutorials
|
contact us
PHP Basics In Pictures
Basics
Variables
Numbers
User functions
Logic & Loops
Files
Write a script that creates a list (array) of presidents:
James Buchanan
George Washington
Millard Fillmore
...Prints the text
"This was the Revolution’s indispensable man:"
...Then prints the second name in the list.
Save the script as
presidents.php
in the
PRACTICEPHP
folder on your computer.
Upload it into the
practicephp
directory on the Web server.
Add the paragraph
"The indispensable man"
to
practice.html
, and link that paragraph to
presidents.php
.
View
practice.html
in the browser, then click the new link.
Its output should look like this:
<< BACK
NEXT >>