PHP: Finish Arrays, Functions, Regex, Forms, Files




CS174

Chris Pollett

Feb 27, 2017

Outline

More on PHP Arrays

Last week, we were talking about PHP arrays. Today, we start by finishing off this discussion...

Yet More on PHP Arrays

Iterating Through Arrays

Quiz

Which of the following statements is true?

  1. A PHP script starts in interpretive mode.
  2. Bob is a legal PHP variable name. Its default value would be 0.
  3. One could echo the elements of a PHP array $arr with the following code:
    foreach ($arr as $var) {
       echo $var;
    }
    

Functions

Variable Scope

Pattern Matching

Types of web forms

Built-in Globals

File Reading

File Writing