Saving the Order ID as a cookie

This is an archive of old posting to the User Forum

Saving the Order ID as a cookie

Postby Sherry Land » Tue Nov 12, 2002 9:40 am

I am trying to save the Order ID on a customer's computer as a cookie by
modifying the perl script custom-dump.pl.

I'm a fairly experienced web programmer and am comfortable with perl,
but I've spent hours on this thing and can't see the cookie appearing in
my cookies folder.

There must be some fundamental issue I am not understanding. I've tried
writing this cookie in both perl and in javascript. I see the shopsite
"pre-baked" cookies, but mine are never written.

Can anyone give me some pointers!!!
Thanks,

Sherry Land
sland@neuralog.com
Sherry Land
 

Re: Saving the Order ID as a cookie

Postby loren_d_c » Tue Nov 12, 2002 1:02 pm

Sherry,

I've read cookies via an Order API script before, I have not set them there,
but should be the same principle, and I don't think there would be any
tricks to it or anything that ShopSite would be doing to get in the way.
What is the cookie code you are using? Are you doing it manually or are you
using the CGI perl module's functions for settings cookies?

-Loren


Sherry Land wrote:

I am trying to save the Order ID on a customer's computer as a cookie by
modifying the perl script custom-dump.pl.

I'm a fairly experienced web programmer and am comfortable with perl,
but I've spent hours on this thing and can't see the cookie appearing in
my cookies folder.

There must be some fundamental issue I am not understanding. I've tried
writing this cookie in both perl and in javascript. I see the shopsite
"pre-baked" cookies, but mine are never written.

Can anyone give me some pointers!!!
Thanks,

Sherry Land
sland@neuralog.com
loren_d_c
 
Posts: 2571
Joined: Fri Aug 04, 2006 12:02 pm
Location: Anywhere

Re: Saving the Order ID as a cookie

Postby Sherry Land » Tue Nov 12, 2002 3:13 pm

I was using a library I found called cookie-lib.pl. Then I tried using the
Set-Cookie command manually. The script hung. Do you know of some recommended
perl cookie code? Then I tried using perl-generated Javascript. But I think by
that point I too frustrated to get that to work. Too many escape characters.

I am suprised that ShopSite doesn't provide some mechanism to store the Order ID
on a client machine for the SW digital download to access. We were planning on
writing the OrderID as a cookie and having the SW installation program read it.

Sherry

Loren wrote:

Sherry,

I've read cookies via an Order API script before, I have not set them there,
but should be the same principle, and I don't think there would be any
tricks to it or anything that ShopSite would be doing to get in the way.
What is the cookie code you are using? Are you doing it manually or are you
using the CGI perl module's functions for settings cookies?

-Loren

Sherry Land wrote:

I am trying to save the Order ID on a customer's computer as a cookie by
modifying the perl script custom-dump.pl.

I'm a fairly experienced web programmer and am comfortable with perl,
but I've spent hours on this thing and can't see the cookie appearing in
my cookies folder.

There must be some fundamental issue I am not understanding. I've tried
writing this cookie in both perl and in javascript. I see the shopsite
"pre-baked" cookies, but mine are never written.

Can anyone give me some pointers!!!
Thanks,

Sherry Land
sland@neuralog.com
Sherry Land
 

Re: Saving the Order ID as a cookie

Postby loren_d_c » Tue Nov 12, 2002 5:52 pm

What is SW and why would ShopSite by default need to set a cookie for some other
software program?

I am not familiar with the cookie-lib.pl library, in the past I have used the
functions built-in to the CGI perl module, which is installed by default with almost
every perl installation I have seen in years. The functions are pretty simple and
fairly well documented online, see the syntax explained at www.perldoc.com here:

http://www.perldoc.com/perl5.8.0/lib/CG ... TP-COOKIES

-Loren


Sherry Land wrote:

I was using a library I found called cookie-lib.pl. Then I tried using the
Set-Cookie command manually. The script hung. Do you know of some recommended
perl cookie code? Then I tried using perl-generated Javascript. But I think by
that point I too frustrated to get that to work. Too many escape characters.

I am suprised that ShopSite doesn't provide some mechanism to store the Order ID
on a client machine for the SW digital download to access. We were planning on
writing the OrderID as a cookie and having the SW installation program read it.

Sherry

Loren wrote:

Sherry,

I've read cookies via an Order API script before, I have not set them there,
but should be the same principle, and I don't think there would be any
tricks to it or anything that ShopSite would be doing to get in the way.
What is the cookie code you are using? Are you doing it manually or are you
using the CGI perl module's functions for settings cookies?

-Loren

Sherry Land wrote:

I am trying to save the Order ID on a customer's computer as a cookie by
modifying the perl script custom-dump.pl.

I'm a fairly experienced web programmer and am comfortable with perl,
but I've spent hours on this thing and can't see the cookie appearing in
my cookies folder.

There must be some fundamental issue I am not understanding. I've tried
writing this cookie in both perl and in javascript. I see the shopsite
"pre-baked" cookies, but mine are never written.

Can anyone give me some pointers!!!
Thanks,

Sherry Land
sland@neuralog.com
loren_d_c
 
Posts: 2571
Joined: Fri Aug 04, 2006 12:02 pm
Location: Anywhere

Re: Saving the Order ID as a cookie

Postby Sherry Land » Tue Nov 12, 2002 11:01 pm

Thanks to Loren and others who helped me.

The main problem was that I was making things way too complicated.

The second problem was that I was using IE and had the cookie setting on PROMPT (as
opposed to enable/disable). This is still failing.

FYI, the use I have for my cookies is this. My SW installation program will read the
cookies and have name, email, (possibly order ID) filled out. Just as a default; user
can always type them in. Then in our app install, the user will send an Activate
License email (we are also reading their ethernet ID or HD ID) and we send them the key
based on this info.

Again, Thank You!
Sherry Land
webmaster@neuralog.com
www.neuralog.com


Loren wrote:

What is SW and why would ShopSite by default need to set a cookie for some other
software program?

I am not familiar with the cookie-lib.pl library, in the past I have used the
functions built-in to the CGI perl module, which is installed by default with almost
every perl installation I have seen in years. The functions are pretty simple and
fairly well documented online, see the syntax explained at www.perldoc.com here:

http://www.perldoc.com/perl5.8.0/lib/CG ... TP-COOKIES

-Loren

Sherry Land wrote:

I was using a library I found called cookie-lib.pl. Then I tried using the
Set-Cookie command manually. The script hung. Do you know of some recommended
perl cookie code? Then I tried using perl-generated Javascript. But I think by
that point I too frustrated to get that to work. Too many escape characters.

I am suprised that ShopSite doesn't provide some mechanism to store the Order ID
on a client machine for the SW digital download to access. We were planning on
writing the OrderID as a cookie and having the SW installation program read it.

Sherry

Loren wrote:

Sherry,

I've read cookies via an Order API script before, I have not set them there,
but should be the same principle, and I don't think there would be any
tricks to it or anything that ShopSite would be doing to get in the way.
What is the cookie code you are using? Are you doing it manually or are you
using the CGI perl module's functions for settings cookies?

-Loren

Sherry Land wrote:

I am trying to save the Order ID on a customer's computer as a cookie by
modifying the perl script custom-dump.pl.

I'm a fairly experienced web programmer and am comfortable with perl,
but I've spent hours on this thing and can't see the cookie appearing in
my cookies folder.

There must be some fundamental issue I am not understanding. I've tried
writing this cookie in both perl and in javascript. I see the shopsite
"pre-baked" cookies, but mine are never written.

Can anyone give me some pointers!!!
Thanks,

Sherry Land
sland@neuralog.com
Sherry Land
 


Return to User Forum Archive

Who is online

Users browsing this forum: No registered users and 55 guests