PHP Interview Questions and Answers
Prepare for your Interview today!
Everything is passed by value.
parent::constructor($value)
__sleep returns the array of all the variables than need to be saved, while __wakeup retrieves them.
Because inside the single quotes the n character is not interpreted as newline, just as a sequence of two characters - and n.
Since the data inside the single-quoted string is not parsed for variable substitution, it's always a better idea speed-wise to initialize a string with single quotes, unless you specifically need variable substitution.
Most helpful rated by users: