Creating a dynamic website header

  • africancures
  • Newbie
  • Newbie
  • africancures
  • Posts: 5

Post 3+ Months Ago

I don't even know where to start with this one, let me try explain this:

I am looking for ideas on how to create some sort of dynamic header for an affiliate website, we have launched a new affiliate program for http://www.africancures.com/ the affiliate program is done through 1shoppingcart.com and each affiliate is given an ID like:

http://www.1shoppingcart.com/app/?af=812264

Once the affiliate signs up they choose their own website URL like: mikeshealth.com, then we point the affiliate URL mikeshealth.com to http://www.1shoppingcart.com/app/?af=812264 which in turn comes to our main website: http://www.africancures.com/ now here is where the problem comes in, how do I make the website display Mikes Health instead of African Cures .

I hope I was able to explain this well enough as it seems to be a bit confusing to me when I write it down. I really hope there is someone out there who has worked on something like this before or if there is someone who thinks they know how to do this.

Thank you

So here is something else I was thinking of, but I am not much of a programmer anymore:
Have a list of all the affiliate ids and their corresponding website names, eg:
Affiliate ID=812264 Website name= Mikes Health, then when someone comes to the site the jave works out which affiliate id sent them to the site, eg

Get(AffiliateID)from Refering.URL then Display.Header(AffiliateID) on main page.
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • UPSGuy
  • Lurker ಠ_ಠ
  • Web Master
  • User avatar
  • Posts: 2733
  • Loc: Nashville, TN

Post 3+ Months Ago

african cures, I believe you've answered your own question, all you need to do is specify the image you would like to display based on the id passed. I'm assuming there's a database involved in storing and retrieving your affiliate id and image key/values. That being said, what server-side language will you be using?
  • UPSGuy
  • Lurker ಠ_ಠ
  • Web Master
  • User avatar
  • Posts: 2733
  • Loc: Nashville, TN

Post 3+ Months Ago

Hrmm, if you wanted to avoid the database, you could always use the affiliate ID (assuming its unique) as the image name, for instance:

PHP:
Code: [ Select ]
echo "<img src=\"".$_REQUEST['af'].".jpg\" />";


Java:
Code: [ Select ]
<img src="<%= request.getParameter("af") %>.jpg" />


Both of these assume that you would have named the header '812264.jpg'
  • africancures
  • Newbie
  • Newbie
  • africancures
  • Posts: 5

Post 3+ Months Ago

UPSGuy,
Thank you for that response, I am hosting on GoDaddy Unix server and the affiliate program is run through 1shoppingcart.com, if you look at the current website (http://www.africancures.com) the heading it just text, it is not an image.

What code would I use to pull the affiliate ID 812264 out of the refering link: http://www.1shoppingcart.com/app/?af=812264, then check this against my own little list eg. 812264=Mike Health.

I am a chop when it comes to programming, would you help me for $50?
  • africancures
  • Newbie
  • Newbie
  • africancures
  • Posts: 5

Post 3+ Months Ago

I think it is even easier than what you think, I would need to have a list stored with all the affiliate IDs and then their related 'Web Names' eg: aff ID#812264 = 'Mikes Health Store'.
Then when the person types in MikesHealthStore.com the url redirects using http://www.1shoppingcart.com/app/?af=812264, somehow the site africancures.com pulls out the 812264 and then displays 'Mikes Health Store' in place of 'African Cures', and updates the title:
<title>African Cures | Prosit </title>
to
<title>Mikes Health Store | African Cures </title>

The other issue that I see is that when they go off the site for a while to purchase the product and they come back from the shopping cart, how will the site know it is them returning and then display 'Mike Health Store' again?
  • tastysite
  • Proficient
  • Proficient
  • User avatar
  • Posts: 349
  • Loc: Brighouse, West Yorkshire, England

Post 3+ Months Ago

africancures wrote:
The other issue that I see is that when they go off the site for a while to purchase the product and they come back from the shopping cart, how will the site know it is them returning and then display 'Mike Health Store' again?

You could set a cookie to save the ID for some time (Or even for ever if you wish) then get the site to look for that cookie and use the ID saved in it for the header! However the probelem you have there is telling the difference between "Mike Health Store" and say "The big store of health" or whatever so the cookie will have to not just save the name of the site i.e. Mike Health Store but also a ID not used by anyone else for that member/website but if each member has a ID anyway just use that!
  • kz1398
  • Born
  • Born
  • kz1398
  • Posts: 1

Post 3+ Months Ago

I hate to necro post a bit, but nothing in this thread worked for me. I tried $_GET, $_REQUEST, even $_POST.

I cannot get the ?af out of the original affiliate link.

Has anyone had experience with this before?
  • Bogey
  • Genius
  • Genius
  • Bogey
  • Posts: 8388
  • Loc: USA

Post 3+ Months Ago

It would be $_GET['af'] if the ?af is in the link (In the address bar).
  • africancures
  • Newbie
  • Newbie
  • africancures
  • Posts: 5

Post 3+ Months Ago

I got it to work!!! The site sends the people to a folder with the Aff ID, which then send the people to 1ShoppingCart and when they come back the cookie has their site header name;
  • africancures
  • Newbie
  • Newbie
  • africancures
  • Posts: 5

Post 3+ Months Ago

Sorry, I just didnt check back here for some reason, missing for two years, guess it would have been easier if some sent me mail at the website

Post Information

  • Total Posts in this topic: 10 posts
  • Users browsing this forum: No registered users and 57 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.