- Posts: 44
- Thank you received: 0
Affliate ID
14 years 8 months ago #36740
by mohamed
Affliate ID was created by mohamed
I would like the customers of my website to be able to manually enter the ID of the affiliate that led them to the website without the use of the url. eg: There would be a field in the shopping cart to allow the customer to enter the affiliate ID. also how can I make it such that the customer is unable to buy without a valid affiliate ID.
Please Log in or Create an account to join the conversation.
14 years 8 months ago #36820
by nicolas
Replied by nicolas on topic Re: Affliate ID
Hi,
There is no such option. You would have to create some customization for that.
If you're interested for us to do it for you, you can request a quote via our contact form.
There is no such option. You would have to create some customization for that.
If you're interested for us to do it for you, you can request a quote via our contact form.
Please Log in or Create an account to join the conversation.
14 years 8 months ago #36823
by mohamed
Replied by mohamed on topic Re: Affliate ID
I am a programmer myself and have no problem playing with the code but this is my first time to use joomla or hikashop. If you could point me in the right direction such s which files control what and I will go on from there. That would be very much appreciated
Please Log in or Create an account to join the conversation.
14 years 8 months ago - 14 years 8 months ago #36829
by nicolas
Replied by nicolas on topic Re: Affliate ID
Then, you should create a page with a form asking for the affiliate id, with a joomla form extension or directly yourself, then redirect to some page of your website with the parameter &partner_id=ID
where the ID would be the id entered by the user.
Then he would be automatically affected to that partner.
For the restriction of the purchase, you could edit the file "step" of the view "checkout" via the menu Display>Views and add a check there by loading the information of the user from the hikashop_user table like that:
$user = hikashop_loadUser(true);
where the ID would be the id entered by the user.
Then he would be automatically affected to that partner.
For the restriction of the purchase, you could edit the file "step" of the view "checkout" via the menu Display>Views and add a check there by loading the information of the user from the hikashop_user table like that:
$user = hikashop_loadUser(true);
Last edit: 14 years 8 months ago by Jerome.
Please Log in or Create an account to join the conversation.
14 years 8 months ago #36896
by mohamed
Replied by mohamed on topic Re: Affliate ID
Ok so how do I redirect to my form from the cart (Any step in the checkout process would be fine).
also what does the line "$user = hikashop_loadUser(true);" actually do.
also what does the line "$user = hikashop_loadUser(true);" actually do.
Please Log in or Create an account to join the conversation.
14 years 8 months ago #36898
by nicolas
Replied by nicolas on topic Re: Affliate ID
You should redirect to the URL
yourwebsite.com/index.php?option=com_hik...l=checkout&task=step
That line of code loads the current user information that you can use to do your check on whether the user has entered his partner id or not.
That line of code loads the current user information that you can use to do your check on whether the user has entered his partner id or not.
Please Log in or Create an account to join the conversation.
14 years 8 months ago #36900
by mohamed
Replied by mohamed on topic Re: Affliate ID
What I mean is the user just added a few items to cart then he clicks checkout. At this point I want him to be forwarded to my custom form where he fills out the affiliate ID of the partner who lead him to the site. ie. I want to add an additional step in the checkout process where the user enters the affiliate id.
Please Log in or Create an account to join the conversation.
14 years 8 months ago #36905
by nicolas
Replied by nicolas on topic Re: Affliate ID
You should edit the file "step" of the view "checkout" via the menu Display>Views and add your redirect to your form there.
Please Log in or Create an account to join the conversation.
Time to create page: 0.245 seconds