Affiliate Marketing
Forum Search


Reply
 
LinkBack Thread Tools Display Modes

  #1 (permalink)  
Old 01-05-08
Registered User
 
Join Date: Jan 2007
Posts: 223
Thanks: 4
Thanked 3 Times in 3 Posts
hairycornflakes is an unknown quantity at this point
  Redirects... cant seem to get it running smoothly!

if you goto nrbet.com - Betfair BFB425 £25 Free Sign Up Offer

then click on one of the links to betfair, u can see the redirect page, i want it so you cant see the redirect page.

any ideas welcomed

hc
__________________
Early to bed and early to rise makes a man healthy, wealthy and wise
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 01-05-08
Registered User
 
Join Date: Dec 2006
Posts: 16
Thanks: 0
Thanked 1 Time in 1 Post
paulb567 is an unknown quantity at this point
  Post Re: Redirects... cant seem to get it running smoothly!

Something like this in your betfair.php file.

PHP Code:
<?php
   $url 
"http://ads.betfair.com/redirect.aspx?bid=2005&pid=4824&zid=0&pbg=0&cid=0";
   
header("Location: $url");
   exit;
?>
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 01-05-08
Registered User
 
Join Date: Jan 2007
Posts: 223
Thanks: 4
Thanked 3 Times in 3 Posts
hairycornflakes is an unknown quantity at this point
  Re: Redirects... cant seem to get it running smoothly!

legend, that seems to have worked

iv got a php file with that php code, then iv made a body code to have my statcounter code in, will this work ok?

could some1 possibly goto nrbet.com - Betfair BFB425 £25 Free Sign Up Offer and click on the banner to betfair, and ill check my stats to see if its worked ok

thanks so much for your help, looks so much smarter!

i really need to learn php, it always seems to be the answer!
__________________
Early to bed and early to rise makes a man healthy, wealthy and wise
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 01-05-08
Registered User
 
Join Date: Jan 2007
Posts: 223
Thanks: 4
Thanked 3 Times in 3 Posts
hairycornflakes is an unknown quantity at this point
  Re: Redirects... cant seem to get it running smoothly!

any ideas, what that were A with teh ^ is all about in the title of that page?
__________________
Early to bed and early to rise makes a man healthy, wealthy and wise
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
  #5 (permalink)  
Old 02-05-08
tbp tbp is offline
Registered User
 
Join Date: Dec 2006
Posts: 1,999
Thanks: 0
Thanked 18 Times in 18 Posts
tbp is an unknown quantity at this point
  Re: Redirects... cant seem to get it running smoothly!

The odd character is just an encoding issue with the forum, looks fine on your site so don't worry about it.

From what I understand from your previous post, you have your html code under the PHP redirect code?

If this is correct, it's not going to work because usually once the page has redirected any code after it isn't run.

You can't have html before the redirect though either because if anything is output to the browser before the header() command will close the header sent to the browser and then then the redirect won't work.

The normal way to get round it is to use a database to record the click, and have that code before the header() command which is allowed as its just writing to the database.

Alternatively, you may be able to call the external script through PHP, so it will still register the hit. If you can post the code you put on the page normally for the tracking I`ll see if it can work by calling it through PHP.

I`ve clicked on the banner so you can see if its working or not.

Incidentally, Kaspersky Internet Security is blocking the redirect on the Betfair site, looks like its on their blacklist. Nothing you can do about this though.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 02-05-08
Registered User
 
Join Date: Jan 2007
Posts: 223
Thanks: 4
Thanked 3 Times in 3 Posts
hairycornflakes is an unknown quantity at this point
  Re: Redirects... cant seem to get it running smoothly!

Quote:
Originally Posted by tbp View Post
The odd character is just an encoding issue with the forum, looks fine on your site so don't worry about it.

From what I understand from your previous post, you have your html code under the PHP redirect code?

If this is correct, it's not going to work because usually once the page has redirected any code after it isn't run.

You can't have html before the redirect though either because if anything is output to the browser before the header() command will close the header sent to the browser and then then the redirect won't work.

The normal way to get round it is to use a database to record the click, and have that code before the header() command which is allowed as its just writing to the database.

Alternatively, you may be able to call the external script through PHP, so it will still register the hit. If you can post the code you put on the page normally for the tracking I`ll see if it can work by calling it through PHP.

I`ve clicked on the banner so you can see if its working or not.

Incidentally, Kaspersky Internet Security is blocking the redirect on the Betfair site, looks like its on their blacklist. Nothing you can do about this though.
thanks tbp, heres the php redirect I have currently

PHP Code:
<?php
   $url 
"http://promo.betfair.com/index25.asp?clkID=11047_15D995B040634C289ABE266EF58969&rfr=11047&ttp=111";
   
header("Location: $url");
   exit;
?>
and heres the statcounter code id like to have on the page, any help appreciated

HTML Code:
<!-- Start of StatCounter Code -->
<script type="text/javascript" language="javascript">
var sc_project=2223115; 
var sc_invisible=1; 
var sc_partition=20; 
var sc_security="54e63ad3"; 
</script>

<script type="text/javascript" language="javascript" src="http://www.statcounter.com/counter/counter.js"></script><noscript><a href="http://www.statcounter.com/" target="_blank"><img  src="http://c21.statcounter.com/counter.php?sc_project=2223115&java=0&security=54e63ad3&invisible=1" alt="free statistics" border="0"></a> </noscript>

<!-- End of StatCounter Code -->
thanks

hc
__________________
Early to bed and early to rise makes a man healthy, wealthy and wise
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 02-05-08
Registered User
 
Join Date: Dec 2007
Posts: 17
Thanks: 0
Thanked 0 Times in 0 Posts
polishben is an unknown quantity at this point
  Re: Redirects... cant seem to get it running smoothly!

as tbp has explained - the PHP redirect header is not going to work with your counter code.
The redirect header basically tells the browser "the page you want isn't here, go there instead". Therefore any client side code (such as the javascript your counter uses) which follows the header will be ignored by the browser.
__________________
exercise bikes | Jewellery Thief
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
  #8 (permalink)  
Old 02-05-08
tbp tbp is offline
Registered User
 
Join Date: Dec 2006
Posts: 1,999
Thanks: 0
Thanked 18 Times in 18 Posts
tbp is an unknown quantity at this point
  Re: Redirects... cant seem to get it running smoothly!

Thanks for posting the code. There might be a way around it by calling the file through PHP. Will have to test though and unfortunately I`m really busy at the moment as some stuffs come up, but i`ll have a look at it this evening for you.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #9 (permalink)  
Old 02-05-08
Registered User
 
Join Date: Jan 2007
Posts: 223
Thanks: 4
Thanked 3 Times in 3 Posts
hairycornflakes is an unknown quantity at this point
  Re: Redirects... cant seem to get it running smoothly!

Quote:
Originally Posted by tbp View Post
Thanks for posting the code. There might be a way around it by calling the file through PHP. Will have to test though and unfortunately I`m really busy at the moment as some stuffs come up, but i`ll have a look at it this evening for you.
thanks m8
__________________
Early to bed and early to rise makes a man healthy, wealthy and wise
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #10 (permalink)  
Old 12-05-08
Registered User
 
Join Date: Jan 2007
Posts: 223
Thanks: 4
Thanked 3 Times in 3 Posts
hairycornflakes is an unknown quantity at this point
  Re: Redirects... cant seem to get it running smoothly!

hi mate, sorry to be so annoying, dont suppose ye got a second to give this a quick go did ya?
__________________
Early to bed and early to rise makes a man healthy, wealthy and wise
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
  #11 (permalink)  
Old 12-05-08
tbp tbp is offline
Registered User
 
Join Date: Dec 2006
Posts: 1,999
Thanks: 0
Thanked 18 Times in 18 Posts
tbp is an unknown quantity at this point
  Re: Redirects... cant seem to get it running smoothly!

Hi,

Really sorry, totally forgot about this! Got so much work on at the moment my brains all over the place.

Try adding the following code to your redirect (obviously before the redirect t