top button
Flag Notify
    Connect to us
      Facebook Login
      Site Registration

Facebook Login
Site Registration

What is difference between the function Unlink() and Unset()?

0 votes
131 views
What is difference between the function Unlink() and Unset()?
posted Jun 2, 2014 by Amanpreet Kaur

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

3 Answers

+1 vote

unlink() function : It is a function for file system handling. It will simply delete the file in context.

unset() function : It is a function for variable management. It will make a variable undefined.

answer Jun 3, 2014 by Vrije Mani Upadhyay
0 votes

Unlink () function deletes the given file from the file system. whereas Unset() function makes a variable undefined.

answer Jun 3, 2014 by Mohit Sharma
0 votes

unlink: It is used to remove the file from server.

unlink('/path/file.phtml');

unset: It is used to remove the variable.

unset($variableName);
answer Nov 5, 2017 by Jdk
Similar Questions
+3 votes

I have started learning PHP and got a thought about mysql.

I did google and found this stack overflow link
http://stackoverflow.com/questions/625930/what-is-the-maximum-size-of-a-mysql-database-in-version-5-and-up

But there are less answers and more discussions. Can someone give me the right answer which has full description in it.

Contact Us
+91 9880187415
sales@queryhome.net
support@queryhome.net
#280, 3rd floor, 5th Main
6th Sector, HSR Layout
Bangalore-560102
Karnataka INDIA.
QUERY HOME
...