I have cookie set - the problem is, that I can not read them correctly.
Here is code I use to print cookies:
$mail_prog = '/usr/sbin/sendmail' ;
use CGI;
$query = new CGI;
print "Content-type: text/html\n\n";
$answer = $query->cookie('answer');
($id, $status, $dobre, $spatne, $jmeno, $td, $celkem, $odpoved, $oprava, $nutnost) = split(/::/, $answer, 10);
print " $id, $status, $dobre, $spatne, $jmeno, $td, $celkem, $odpoved, $oprava, $nutnost";
exit;
Then I call script from web page:
Thing is that when I run script it self from browser
http://chicago-cz.com/cgi-bin/otazky/cook.pl it reads cookies. If I run script from webpage using
http://www.chicago-cz.com/2004/test.shtml
it does not read cookie values.
This problem is when I use Mozzila based browser. I tried the same thing with IE and it is working just fine.
Can somebody tell me how to read cookies or where the problem is?
Thank you
Here is code I use to print cookies:
Code:
!/usr/local/bin/perl $mail_prog = '/usr/sbin/sendmail' ;
use CGI;
$query = new CGI;
print "Content-type: text/html\n\n";
$answer = $query->cookie('answer');
($id, $status, $dobre, $spatne, $jmeno, $td, $celkem, $odpoved, $oprava, $nutnost) = split(/::/, $answer, 10);
print " $id, $status, $dobre, $spatne, $jmeno, $td, $celkem, $odpoved, $oprava, $nutnost";
exit;
Then I call script from web page:
Code:
<!--#exec cgi="/cgi-bin/otazky/zobrazeni.pl" -->Thing is that when I run script it self from browser
http://chicago-cz.com/cgi-bin/otazky/cook.pl it reads cookies. If I run script from webpage using
http://www.chicago-cz.com/2004/test.shtml
it does not read cookie values.
This problem is when I use Mozzila based browser. I tried the same thing with IE and it is working just fine.
Can somebody tell me how to read cookies or where the problem is?
Thank you