in reply to Re: Re: Perl and cookies...
in thread Perl and cookies...
#!/usr/bin/perl -T use strict; use warnings; use CGI; my $cgi = new CGI; my $cookie = $cgi->cookie(-name =>'somename', -value =>'somevalue', -path =>'/', -expires=>'+10y', #long cookie -domain =>'yourdomain.com', ); print $cgi->redirect( -cookie=>$cookie, -uri =>'http://yourdomain.com/someimage.png');
The only caveat is that some ad-blocking software blocks this as it is normally used to track people. This is especially true if you make the image a 1x1 transparent GIF. But if you aren't worried about that this should be the solution you are looking for.
Hope that helps
Chris
|
|---|