My webapp has a login/logout function, In safari of iphone I can't logout, it seems like my php script can't cancle cookie

I create a login/logout function for my web project with php, It works fine with browser in pc and browser in Android. But in iphone it dosen't work, some time I can not logout, it seems like my php script can't cancle cookie.

I use this code for login by setting cookie:


setcookie("us", $email, time() + (86400 * 30), "/", $_SERVER['SERVER_NAME'], isset($_SERVER["HTTPS"]), true);

setcookie("ps",$password, time() + (86400 * 30), "/", $_SERVER['SERVER_NAME'], isset($_SERVER["HTTPS"]), true);

I use this for logout by cancle cookie:


setcookie("us", null, time()-3600, "/", $_SERVER['SERVER_NAME'], isset($_SERVER["HTTPS"]), true);

setcookie("ps", null, time()-3600, "/", $_SERVER['SERVER_NAME'], isset($_SERVER["HTTPS"]), true);

setcookie("PHPSESSID", null, time()-3600, "/");

$_SESSION = array();



header('Location: [login to view URL]');

When start my page the php will check if there is cookie for login automatic:



//verify this user...


Taidot: PHP, Web Development, Verkkoturva

Näytä lisää: the life of pablo i feel like pablo black long sleeve t shirt, the life of pablo i feel like pablo red long sleeve t shirt, Hello, I am very interested in the project and I would like to apply to it. I\ m a web developer with 7 years experience in PHP,, I need a php, python, Ruby developer to create an application in the cloud, i need to write a letter to my friend he passed grade 12 i write a letter to him about my 3rd time failure in grade 10 and my fe, i need graphic designer for my screen printing business in ludhiana, i illustrated my children's book in photoshop, how i bought my skin illustrator palette in the uk, where can i advertise my business for free in south africa, i want to write a letter to my telling him the standard of living in ghana and i want points to write this question, i am three months of visiter in dubai and i need a job my qualification is i com 12 year expirience data entry in pakistan urgen, i am a learner in grade 11 i need help i am worried about my future i want to become a lawyer how can i get a bursary in kzn, i need a spell caster to fix relationship with my husband post comment in united arab emirates facebook site 2015, i need a promoter to sell my dinner show tickets in las vegas, i need a php script for ecurency business, i have a list of 67 eminent medical people involved in sports and i would like their work email addresses they are all speakers , can i hire an attorney to speak with my managers concerning harrassmsnet in the work place, iphone imei check php script, iphone case design php script, iphone login function

Tietoa työnantajasta:
( 12 arvostelua ) Milano, Italy

Projektin tunnus: #17150624

Myönnetty käyttäjälle:


Hello There, I had read your job description and I know about the problem. There is no problem in your code, Iphone is not allow to save cookie. So you need to change the function from cookie to session in PHP Lisää

€29 EUR 1 päivässä
(200 Arvostelua)

6 freelanceria on tarjonnut keskimäärin %project_bid_stats_avg_sub_26% %project_currencyDetails_sign_sub_27% tähän työhön


We have a team of Skilled PHP professionals with expertise in Laravel, Codeigniter, Magento, WordPress and other open source packages. We are available from Monday To Friday, 9 hours a day. Our timezone is GMT+5.30. Lisää

€23 EUR 1 päivässä
(149 arvostelua)
€30 EUR 1 päivässä
(25 arvostelua)

I have read your full description, which has brought me to have a solution for your project. I have experience in completing a project like your project. I would like to discuss the details through the chart.

€23 EUR 1 päivässä
(21 arvostelua)

I can solve this issue

€14 EUR 3 päivässä
(17 arvostelua)

Hello Sir/Mam. I am a Computer Science Students and I am a passionate software developer. I am aware of all the latest technology trends. I have up to date skills in Latest Technologies and I am eagerly trying to satis Lisää

€8 EUR 1 päivässä
(0 arvostelua)