Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7408167
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T05:51:51+00:00 2026-05-29T05:51:51+00:00

With affiliate marketing and PHP, I know how to make a tracking pixel like

  • 0

With affiliate marketing and PHP, I know how to make a tracking pixel like this:

<img alt="" src="http://example.com/pixel.php?tracking=43233" />

Then, in pixel.php I do something like:

<?php

$sTrack = @ $_GET['tracking'];
$sTrack = urldecode($sTrack);
$sTrack = strip_tags($sTrack);
$sTrack = trim($sTrack);
// do something with sTrack here
header('Content-type: image/gif');
readfile('images/invisible.gif');

Trouble is, on this offer page I’m receiving cname and cemail as query params on the URL, and the customer is hosting on something that doesn’t support PHP but does let me insert Javascript, and I CAN’T use jQuery in this case. Instead, I need to do this in 100% pure Javascript. So, I can’t read $_GET to pick up the cname and cemail.

I know that location.search will give me those parameters. I just need how to change the IMG tag so that like on a load event I can pass the location.search on the end. And I need it to work across all the browsers since IE7 and up, as well as Opera, Safari, and Chrome.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T05:51:52+00:00Added an answer on May 29, 2026 at 5:51 am

    You can just use the http://example.com/pixel.php as the img src, and then check the referral in that PHP script.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I know it's been asked before, but I need it for affiliate tracking... http://www.mysite.com/controller/method/params?affiliate=123&sub_id=456
On PageA.asp I set a session variable like so Session(affiliate) = xyz.com When I
I have a product table like this: Product name , Affiliate ID , ProductCode
This question refers to affiliate marketing, but really is a generic question about intercepting
I have an affiliate link with a product image http://www.myaffiliate.com/products/product.jpg I want to copy
Think of a small and basic affiliate system. I want an URL like www.myshop.com/mynewproduct.html?afid=123
Our company runs a web site (oursite.com) with affiliate partners who send us traffic.
I'm trying to make a select that calculates affiliate payouts. my approach is pretty
I'm implementing some affiliate tracking to my site. The affiliate network has asked that
I want to create a simple affiliate code. Currently I use PHP session to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.