Let's Get Started with a PHP Page!

  1. Open Notepad++
  2. Choose: File -> New
  3. Copy the First PHP Template (PHP) code (below)
  4. Paste that code into your new file
  5. Change the put-title-of-this-page-here, put-welcome-heading-here, and put-welcome-paragraph-here strings.
  6. Click: File -> Save As
  7. Name your file: \www\variables.php
  8. Change the Save as type: to: PHP Hypertext Preprocessor (*.php)
  9. Click: Save
  10. Visit your page (http://buffalo.edu/first.php) in your favorite web browser
  11. Make any changes
  12. Save your changes

First PHP Template (PHP)

<!doctype html>
    <title><?php echo("put-title-of-this-page-here"); ?></title>
    <h2><?php echo("put-welcome-heading-here"); ?></h2>
    <p><?php echo("put-welcome-paragraph here"); ?></p>