Let's say I am advertising a webpage in a search platform with two different banners,
and I want to track the conversions of each banner. 

If I set up the banners to point to these URLs: 

> 
> * www.domain.com/page.php?ref=banner1
> * www.domain.com/page.php?ref=banner2
> 
> 
> 

1. Should I be using a `?ref=`? Or I can use any `?word=` that I want?
2. Assuming all users enter my page following their individual search query, which I currently see in my server weblog as the referrer, what would I see after such set up?
Would the current referrer date be completely replaced by `banner1` and `banner2`? Or would it just show as the requested URL in my weblog, so I can still track the search queries?
3. I would want to have a link on my website that would contain a tag that would change according to the banner the user came from - `banner1` or `banner2`. How can I do this with PHP? I guess it should be something like:

```
$orig = basename($_SERVER['SCRIPT_FILENAME']);
//get rid of the filename besides the banner indicator
$new1 = str_replace('webpage.php?ref=', '', $orig);

```

But I'm not sure that the `"Script_Filename"` includes the `?ref=` in the first place.

UPDATE:

Thanks everyone this seems to work, however - what If I to get the http referrer as well, but only the search phrase part from that referrer? just like when a web log analayzer takes the full referrer but let you see what what the clean search phrase was. how can I create a PHP string that would only contain this clean phrase?

for example, the yahoo search referrer looks like:

```
http://search.yahoo.com/(bunch of strings)?p=keyword1+keyword2+keyword3&(bunch of strings)

```

how do I strip everything off besides the keywords?