Jump to content
php.lv forumi

Atkal problēmas ar cookie.


nemakuphp

Recommended Posts

Pārtaisi par:

setcookie ('nosaukums', $value, time() + 10800) or die('Āāāā! Viss ir slikti, raugs un milti beigušies!'); // :)

Iespējams, ka kaut kur ir sākusies datu izvade nevietā - kāds warnings vai kkas tamlīdzīgs (Par "Headers already sent").

Link to comment
Share on other sites

PaTH nav domēns - tie ir divi dažādi mainīgie.

path

 

The path on the server in which the cookie will be available on. If set to '/', the cookie will be available within the entire domain . If set to '/foo/', the cookie will only be available within the /foo/ directory and all sub-directories such as /foo/bar/ of domain . The default value is the current directory that the cookie is being set in.

domain

 

The domain that the cookie is available. To make the cookie available on all subdomains of example.com then you'd set it to '.example.com'. The . is not required but makes it compatible with more browsers. Setting it to www.example.com will make the cookie only available in the www subdomain. Refer to tail matching in the » spec for details.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...