ProductCart E-Commerce Solutions Homepage
Forum Home Forum Home > ProductCart > Customizing ProductCart
  New Posts New Posts RSS Feed - Affiliate from Form
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Affiliate from Form

 Post Reply Post Reply
Author
Message
Joker View Drop Down
Newbie
Newbie


Joined: 29-October-2010
Status: Offline
Points: 0
Post Options Post Options   Thanks (0) Thanks(0)   Quote Joker Quote  Post ReplyReply Direct Link To This Post Topic: Affiliate from Form
    Posted: 29-October-2010 at 8:03pm
I have a landing page for a specific product and affiliate that uses a different domain name. http://www.wisdomfilms.com/voiceforhope/ I am using the form code as below to try and pass the order and affiliate id to the cart (login would be even better). I don't want them to go to the product page as the affiliate link normally works. The quantity and the product both work but it doesn't appear to be reading the affiliate ID. I looked at the code in instPrd.asp and it appears to check for an affiliateid through pcStartSession.asp  Is what I am doing possible? Should this be working? Should I pass the idaffiliate as pidaffiliate?  Is there another way to track these affiliate sales? Does anyone know? Thanks
 
<form method="post" action="instPrd.asp"  name="additem">
<input name="quantity" type="text" value="1" size="2" maxlength="2" />
<input name="idproduct" type="hidden" value="71" />
<input name="idAffiliate" type="hidden" id="idAffiliate" value="138" />
 
Back to Top
Greg Dinger View Drop Down
Certified ProductCart Developers
Certified ProductCart Developers
Avatar

Joined: 23-September-2006
Location: United States
Status: Offline
Points: 238
Post Options Post Options   Thanks (0) Thanks(0)   Quote Greg Dinger Quote  Post ReplyReply Direct Link To This Post Posted: 29-October-2010 at 8:11pm
Have a look at pcStartSession.asp.  The part you are missing, I believe, is that affiliate needs to be established as a session variable.  pcStartSession.asp does just that, grabbing the querystring variable, and setting the session value.  To force your solution to work, you may need to carefully override that behavior.
 
Good luck.
Back to Top
Joker View Drop Down
Newbie
Newbie


Joined: 29-October-2010
Status: Offline
Points: 0
Post Options Post Options   Thanks (0) Thanks(0)   Quote Joker Quote  Post ReplyReply Direct Link To This Post Posted: 29-October-2010 at 8:47pm
Thanks Greg,
 
I am a complete newbie to asp and product cart so I appreciate the help. It would be much easier for me in php or if I had built the store from scratch.
 
This is what I am thinking, on pcStartSession.asp after it checks for a querystring,  I add this?
If session("idAffiliate")=1 then
               pcInt_IdAffiliate = request.form("idAffiliate")
    if validNum(pcInt_IdAffiliate) then
     session("idAffiliate")=pcInt_IdAffiliate
    else
     session("idAffiliate")=1
    end if
   End if
 
 Hmmm will instPrd.asp hold/pass the form variable while it runs pcStartSession.asp or maybe I should add this to the top of instPrd.asp and just establish the session variable then. Any suggestions?
Thanks again
Back to Top
Greg Dinger View Drop Down
Certified ProductCart Developers
Certified ProductCart Developers
Avatar

Joined: 23-September-2006
Location: United States
Status: Offline
Points: 238
Post Options Post Options   Thanks (0) Thanks(0)   Quote Greg Dinger Quote  Post ReplyReply Direct Link To This Post Posted: 29-October-2010 at 11:22pm
No, that's not going to work if the affiliate ID was 138.  The session var needs to contain the actual affiliate id that you want to inherit the credit for the sale.  Beyond a gentle push in the right direction, I can't direct your precise coding effort here.  However, there are a number of developers here, our team included, that know the application well and can tackle this for you.
 
Just keep in mind that you need to get that session value to carry your affiliate id, then establish a suitable test environment and debugging points.
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.078 seconds.