1

I saw some examples cookies enabled and disabled but all of them giving disabled in first time visit.

I tried this example: https://www.w3schools.com/php/showphp.asp?filename=demo_cookie5

or

http://www.learningaboutelectronics.com/Articles/How-to-check-if-cookies-are-enabled-using-PHP.php

But see, first time always giving the message cookies are disabled!

enter image description here

Sérgio Thiago Mendonça
  • 1,161
  • 2
  • 13
  • 23

1 Answers1

0

Answering because I can't comment, but try this answer linked here: https://stackoverflow.com/a/6663901/11261849 . Try the javascript method described there and see if that one works on first visit. Checking for cookies enabled in PHP can be hard to check for the first time because the page usually needs to be refreshed in order to check for them being enabled.