NYCPHP Meetup

NYPHP.org

[nycphp-talk] setcookie Pt. II

Wellington Fan wfan at encogent.com
Thu Sep 4 18:28:22 EDT 2003


Phil,

>From the setcookie page:

You may also replace any argument with an empty string ("") in order to skip
that argument.

the full signature (most of the parameters are optional ):
setcookie ( name , value , expire, path , domain , secure )

your call:
setcookie('nordicnet_registration', $uplinenumber, "", "/" );

Try that -- I'm guessing it will work.

--
Wellington

  -----Original Message-----
  From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org]On
Behalf Of Phil Powell
  Sent: Thursday, September 04, 2003 6:15 PM
  To: NYPHP Talk
  Subject: Re: [nycphp-talk] setcookie Pt. II


  That does not work either, it sets the cookie onto disk and instantly
deletes it.

  Phil
    ----- Original Message -----
    From: Patrick Hunt
    To: NYPHP Talk
    Sent: Thursday, September 04, 2003 5:56 PM
    Subject: Re: [nycphp-talk] setcookie Pt. II



    set the expire time to zero.


    --Original Message Text---
    From: Phil Powell
    Date: Thu, 4 Sep 2003 17:20:45 -0400

    setcookie('nordicnet_registration', $uplinenumber); // SESSION COOKIE TO
BE SET

    I have this cookie I have to set that will be session-based (cookie
deletes when browser session is closed, the classic). However, the cookie is
set in /Main_page/registrering.php so the path for the cookie is incorrect;
I want the path to be '/'. HOWEVER, PHP is strict on syntax so that if I set
a path, I have to set a time int value at the same time.

    I want to set the path and NOT the time int. How do I do that?

    Phil





----------------------------------------------------------------------------


    _______________________________________________
    talk mailing list
    talk at lists.nyphp.org
    http://lists.nyphp.org/mailman/listinfo/talk
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.nyphp.org/pipermail/talk/attachments/20030904/5196cc48/attachment.html>


More information about the talk mailing list