Sr. PHP Programmer Question:
Download Questions PDF

How will you set cookies using PHP?


PHP provided setcookie() function to set a cookie. This function requires upto six arguments and should be called before <html> tag. For each cookie this function has to be called separately.

setcookie(name, value, expire, path, domain, security);

Download Senior PHP Programmer Interview Questions And Answers PDF

Previous QuestionNext Question
How will you destroy the session?How can you sort an array?