Introduction to PHP

In this online PHP course, you will learn the basics of PHP, which is still one of the most widely used server-side languages on the web. You will start by learning how PHP works and its basic syntax. You will then learn to create dynamic interactive pages, to work with arrays, to process and validate forms, and to write functions in PHP.

SHARE
3 Months / 32 Course Hrs
Open Enrollment
Offered in partnership with your preferred school

ed2go

Change School
Learning method

Course code: T14527

In this PHP training course, you will learn the basics of PHP, which is still one of the most widely used server-side languages on the web. You will start by learning how PHP works and its basic syntax. You will then learn to create dynamic interactive pages, to work with arrays, to process and validate forms, and to write functions in PHP. This will give you the groundwork you need to move on to a more advanced course that covers database-driven websites with PHP and MySQL.

What you will learn

  • Learn how PHP works
  • Learn the basic syntax of PHP
  • Learn to create dynamic interactive pages with PHP
  • Learn to work with arrays in PHP
  • Learn to process and validate forms with PHP
  • Learn to write functions in PHP

How you will benefit

  • Learn the basics of PHP both to build simple websites and to prepare yourself for learning to build database-driven websites
  • Although this course won't give you everything you need to be a successful PHP developer (you need to know MySQL and techniques for integrating database queries in your code for that), it will give you the prerequisite knowledge needed to go down that road
  • Prepare for further learning, either on your own or in an entry-level PHP developer job

How the course is taught

  • Self-Guided, online course
  • 3 Months access
  • 32 course hours
  1. PHP Basics
    1. Welcome to the Server-side
      1. What is a web server?
      2. Dynamic Websites
    2. Google Chrome DevTools: Network Tab
      1. Status Codes
    3. How PHP Works
      1. The php.ini File
      2. PHP Tags
      3. Hello, World!
    4. Comments
    5. PHP Statements and Whitespace
    6. PHP Functions
    7. php.net
    8. Variables
      1. Variable Types
      2. Variable Names (Identifiers)
      3. Type Juggling and Casting
      4. Hello Variables!
    9. Variable Scope
    10. Superglobals
    11. Single Quotes vs. Double Quotes
    12. Concatenation
    13. Passing Variables on the URL
    14. User-defined Functions (UDFs)
      1. Defining and Calling Functions
      2. Default Values
      3. Variable Scope
      4. By Reference vs. By Value
    15. Introduction to the Poet Tree Club
    16. Including Files
      1. require
      2. require_once
    17. Constants
    18. Error Reporting
    19. Displaying Errors
    20. Including a Secure Configuration File
  2. PHP Conditionals
    1. if / if - else / if - elseif - else
      1. Simple if Condition
      2. if-else Condition
      3. if-elseif-else statement
      4. False Equivalents: Falsy Values
    2. Testing for Variable Existence
    3. Exercise: Checking for Variable Existence
    4. switch/case
    5. Ternary Operator
    6. Null Coalescing Operator
  3. Arithmetic Operators and Loops
    1. Arithmetic Operators
    2. The Modulus Operator
    3. Loops
      1. while
      2. do while
      3. for
      4. break and continue
  4. Arrays
    1. Indexed Arrays
      1. Initializing Arrays
      2. Appending to an Array
      3. Reading from Arrays
      4. Looping through Arrays
    2. Associative Arrays
      1. Initializing Associative Arrays
      2. Reading from Associative Arrays
      3. Looping through Associative Arrays
      4. Superglobal Arrays
    3. Multi-dimensional Arrays
      1. Reading from Two-dimensional Arrays
      2. Looping through Two-dimensional Arrays
      3. Two-dimensional Associative Arrays
      4. Non-tabular Multi-dimensional Arrays
    4. Array Manipulation Functions
    5. in_array() Function
  5. PHP and HTML Forms
    1. HTML Forms
      1. How HTML Forms Work
    2. Form Submissions
    3. Sanitizing Form Data
      1. htmlspecialchars()
      2. htmlentities()
      3. filter_var()
      4. filter_input()
    4. Validating Form Data
      1. Was the Field Filled In?
      2. Is the Entered Value an Integer?
      3. Is it an Email?
      4. Is it a Valid Password and Do the Passwords Match?
      5. Do the Combined Values Create a Valid Date?
      6. Did the User Check the Box?
Self-Study

Prerequisites:

  • HTML
  • CSS is useful

Requirements:

Hardware Requirements:

  • This course can be taken on either a PC or Mac. Chromebooks are not compatible.

Software Requirements:

  • PC: Windows 8 or later.
  • Mac: macOS 10.10 or later.
  • Browser: The latest version of Google Chrome or Mozilla Firefox is preferred. Microsoft Edge and Safari are also compatible.
  • Adobe Acrobat Reader
  • Software must be installed and fully operational before the course begins. Setup instructions can be found here.

Other:

  • Email capabilities and access to a personal email account.

Instructional Material Requirements:

The instructional materials required for this course are included in enrollment and will be available online.

Your course begins immediately after you enroll.​

You have 3 months of access to the course. After enrolling, you can learn and complete the course at your own pace, within the allotted access period. You will have the opportunity to interact with other students in the online discussion area.

There is no time limit to complete each lesson, other than completing all lessons within the allotted access period. Discussion areas for each lesson are open for the entire duration of the course.

Because this course is self-guided, no extensions will be granted after the start of your enrollment.