What is the purpose of the unset() function in PHP?
- To destroy a session
- To remove a cookie
- To unset a variable
- To clear the Memcached cache
The unset() function in PHP is used to unset a variable, freeing up the memory associated with it. This function can be used to remove a variable or an element of an array. Learn more: http://php.net/manual/en/function.unset.php
Loading...
Related Quiz
- Which of the following are true about the echo statement in PHP?
- What is the function to round a floating-point number in PHP?
- You are writing a PHP script and you need to include a file. How would you do this?
- The require statement in PHP will cause a fatal error if the file to be included is not found.
- Which of the following are true about comments in PHP?