On 15 Sep 98, at 6:37, [EMAIL PROTECTED] wrote:
> I have come to the conclusion that I need to write a script that
> issues a cookie, and another that retrieves a cookie and serves up a web
> page. To this end, I have looked at a few books, but they all seem to
> gyrate around calling all kinds of library subroutines (which are never
> shown,) etc. etc. making the topic totally opaque while sounding very...
> erudite and... well, generally obtuse.
>
> Me, I like to live close to the machine, not rely on all kinds of
> subroutines that I don't understand. I am a minimalist at heart.
Unfortunately I'm not familiar with Perl so I can't send any micro-
example (I'm a minimalist too) but this could be useful:
>From CGI Developer's Guide (Sams Net):
"
To send a cookie, you use the HTTP response header Set-Cookie.
Set-Cookie: NAME=VALUE; [EXPIRES=date; PATH=path;
DOMAIN]
"
NAME and VALUE are required!
Expires => Dayname, DD-MM-YY HH:MM:SS GMT
If you dont specify EXPIRES the cookie will be deleted at the
session end.
DOMAIN by default is your domain (domains that can read the
cookie)
PATH Dir in the specified domain that can access the cookie (also
the nested dir... default is / so that evry nested dir can access the
cookie)
For a NS bug its advisable to use PATH
When accessing a cookie you'll find in the browser request header:
Cookie: NAME1=VALUE1; NAME2=VALUE2;...
You'll find this string in HTTP_COOKIE
I dont know perl and in ASP there are prebuild function to do this
stuff... but you can reach also the HTTP level easily and manage
this things directly too. Since I can think a low level solution in
ASP without using prebuild function I think you'll be able to do the
same with perl...
I'm sure some of your colegues on the list (better skilled than me
with perl) will send a sniplet of code you'll just have to copy!
Good luck!
-------------------------------------------
Ivan Sergio Borgonovo [EMAIL PROTECTED]
Webmaster Gorilla Bookstore http://www.gorilla.it
Tel. +39 2 3311105/34530455 Fax. +39 2 34531591
Via Mac Mahon 9, Milano, Italy
-------------------------------------------
____________________________________________________________________
--------------------------------------------------------------------
Join The Web Consultants Association : Register on our web site Now
Web Consultants Web Site : http://just4u.com/webconsultants
If you lose the instructions All subscription/unsubscribing can be done
directly from our website for all our lists.
---------------------------------------------------------------------