In this lesson our instructor talks about user-defined function. First, he discusses defining functions, function parameters, and return statements. Then he talks about where to define functions, include_once construct, and reasons to use functions. He also lectures on version 10.0 of the web application development, outputting HTML in functions, and some coding conventions. He ends the lesson with a helpful homework challenge.
Function parameters are variables defined in a function’s definition
that can be used within the function’s body. They are initialized by arguments
passed to the function each time it is called.
Return values of functions are specified using a return
Return values can be of any PHP data type. If a return statement is
never executed within a function, NULL is returned.
The include_once construct functions exactly as an include
statement, except that if the file specified has already been included it will not be
included again. require_once functions like a combination of
include_once and require .
Lecture Slides are screen-captured images of important points in the lecture. Students can download and print out these lecture slide images to do practice problems as well as take notes while watching the lecture.