Navigation Menu
Alphabetical Listing
Site Contents

Site FAQ
About JSS
JavaScript Forum
JavaScript Tutorial
Friends of JSS

Link to Us
JavaScript Help
Contribute a script
Technology Jobs

Become a Partner

Internet.commerce

Be a Commerce Partner














Internet.com

IT
Developer
Internet News
Small Business
Personal Technology

Search internet.com
Advertise
Corporate Info
Newsletters
Tech Jobs
E-mail Offers

Developer Channel

FlashKit.com
JavaScript.com
JavaScriptSource
Developer Jobs
ScriptSearch
StreamingMediaWorld
Web Developer's Journal
Web Developer's Virtual Library
WebDeveloper.com
Webreference
Web Hosts
XMLfiles.com

Great Sites

DocJavaScript.com
dhtml.com
The Freebie Directory
TheFreeSite.com

Browse Doc JS's Tips!


Hiermenus Central


Promotions

Free Announcements


Social Bookmark

General

Save a visitor's referral ID in a cookie ID on their computer. Then, you can you can access that ID cookie from the rest of your site. Useful to help you pay affiliate commissions or track Web site referrals.

When you first come to this page, it sets your ID cookie to "no id". Click here to reload with our referral ID. (note the ?JSS we added to that link!)


Notes

Source Code

Paste this source code into the designated areas.

External file

Paste this code into an external JavaScript file named: idTracker.js


Head

Paste this code into the HEAD section of your HTML document.


Body

Paste this code into the BODY section of your HTML document


User Comments

Add a comment, suggestion, or correction
[For questions about usage, consult the Notes tab above or visit the JavaScript forum. Do not include more than two (2) lines of code in your comments. If you have suggestions or corrections, you can submit them to us.]

    
   
       
[optional]
 
[optional]

   

Comments feed Comment Feed RSS 2.0

1. From: Matt Lynch
set up the script
10/31/2007 08:01:37

Hi,

Im currently trying to set up this script to use for my affiliate program, however it only seems to work if the affiliate ID is entered in the address on the same page as the box and button. however on my site I want the affiliates to direct people to the index page, they then look around, buy - so leave to go to paypal, and are returned to /payment_sucess.html and the referral id from the cookie set on the index page is not loading onto the payment success page. the only way i can get an ID up is to put it into the address bar on this page only. making the index page cookie irelevant. any help would be greatly appreciated.

2. From: Lee (Admin)
11/07/2007 15:54:19

Matt,
Due to the limitations of these comments, you will need to submit your question to the JavaScript Forum for further help.


Do you write JavaScripts?
If you do, why not submit them to us?
We'll give you credit and a link back to your Web site.