|  | Posted by Wenting, Marcel on 06/13/96 11:57 
Hello Frits,
 I had this also, try to insert your domain and path into the set_cookie
 function according to the php.net function description.
 
 bool setcookie ( string name [, string value [, int expire [, string
 path [, string domain [, bool secure [, bool httponly]]]]]] )
 
 this will most prolly solve this problem.
 
 Marcel
 
 Frits van Leeuwen wrote:
 > I still do not understand.
 >
 > Index.php
 > ----------
 > <?php
 > setcookie("Leeuwendeel");
 > // controleer eerst of het cookie bestaat
 > if(isset($_COOKIE['LeeuwendeelTaal']))
 > {
 >  // cookie bestaat, lees de waarde uit
 >  $cookie_var = $_COOKIE['LeeuwendeelTaal'];
 >  // druk de waarde eventueel af (dit kan ook rechtstreeks natuurlijk)
 >  echo "cookie waarde: ".$cookie_var;
 > }
 > else
 > {
 >  // cookie bestaat niet
 >  echo "cookie bestaat niet.<br>";
 >  echo "Welke taal kiest u? <br>";
 >  "<a href="taal_nl.php">Nederlands</a> of <a
 > href="taal_en.php">Engels</a>?";
 > }
 > ?>
 >
 > taal_nl.php
 > -----------
 > <?php
 > setcookie("LeeuwendeelTaal", "nl", time()+7200));
 > Echo "De taal is Nederlands.";
 > ?>
 >
 > taal_en.php
 > -----------
 > <?php
 > setcookie("LeeuwendeelTaal", "en", time()+7200));
 > Echo "The language is English.";
 > ?>
 >
 >  I don't see a cookie at the cookie directory.
 > And also I dón't see any text at my screen.
 >
 >  Who knows what's wrong?
 >
 >
  Navigation: [Reply to this message] |