I tried to set the setcookie code on the tracker.php file with no such luck. The tracker.php file is encoded with zend optimizer. When I posted the setcookie code onto the tracker.php file, I got a screen stating that I needed the zend optimizer to decode the file. Once I reverted back to the backup tracker.php file I had saved before the adjustments, I uploaded the file and still got the zend optimizer window. I had to call my server up and get them to restore my site back to a previously saved position from this morning, which basically leaves me back to this point now. Does the tracker.php file have to have the setcookie code included? If so, I can talk to my adtracker company tomorrow about doing so. Thanks again for your time, John
If tracker.php is where the visitor lands, then yes, it needs the cookie code. Alternatively, you can make a new page "landing.php" which cookies the user and then forwards on to tracker.php.
Ok, I got the owner of my tracking program to send me the tracker.php file decoded so that I may implement the code. I added the setcookie code to the top of tracker.php and it didn't seem to work. The tracker.php is pretty extensive, so I don't really know where else I would try to put the setcookie code within that page. So I am going to post the tracker.php code here for you to look at when you have the time. I feel so close to getting this to work, yet so far. Im going to see if I can post this on the next thread.
Why don't you send that to me in PM-- the author probably wouldn't want the entire code posted publically. What was the error you got when you put the cookie code at the top of the script?
Hoff, your right, I deleted the code from the previous posts. I didn't get an error at all from implementing the code, it just didn't work in appending the sid value. I am sendin you a PM of the code now.
Put the cookie code at the very top, right after the first <?php then turn on cookie monitoring in your browser-- adjust the privacy settings so that it prompts you with every cookie that is set. Now test the file. It should set the cookie and then continue on. If not, put echo "hello"; exit; right after the cookie code and do it again. It should set the cookie, say hello, and exit. If that works then keep moving the exit statment down until you see that it actually fails somewhere.... so anyway, try that and see why it isn't setting the cookie. If you're talking to the guy who wrote the tracker anyway, he should be able to tell you how to do it pretty easily or what may be conflicting.
Ok...I did as you said and set the setcookie code at the beginning of the script. Still didn't set the cookie. I then used the echo "hello" code after the setcookie code, but and I got a white screen with the words "hello" but the screen never exited, it just stopped there. I set my browser privacy setting to low where it accepts all cookies. Never got a prompt though for a cookie being set. The guy I spoke to the other day regarding the adtracker was the co-owner of the adtracker program, but he is not the programmer. I will speak try and speak with him today and see if I can get in touch with his programmer so that I can see why this isn't working. Thank you very much for your time and efforts.........it is greatly appreciated. John
Oh...another thing..... I checked the cookies that get stored when I use the tracking script. Seems as if the cookie is being stored, just not appended to the affiliate url. There are two cookies that are being stored on my computer when I use the tracking url. One looks like this: 1. sid goinghome gamerentalguide.com/adwatcher/ 1024 2118632576 29862819 218511376 29789394 * The other one looks like this 2. ses_id23 db27db0d8a7efa067723758d19caf547 gamerentalguide.com/ 1024 3368632576 29862819 1463201376 29789394 * ses_time23 1149973709 gamerentalguide.com/ 1024 2118632576 29862819 218611376 29789394 * ses_ip23 68.224.95.21 gamerentalguide.com/ 1024 2118632576 29862819 218611376 29789394 * ses_fc23 3 gamerentalguide.com/ 1024 3368632576 29862819 1463301376 29789394 * ses_clid 15876 gamerentalguide.com/ 1024 2118632576 29862819 218711376 29789394 * ses_cid 23 gamerentalguide.com/ 1024 2118632576 29862819 218811376 29789394 * __utma 98837128.1733069504.1149973722.1149973722.1149973722.1 gamerentalguide.com/ 1088 2350186496 32111674 226221376 29789394 * __utmb 98837128 gamerentalguide.com/ 1088 2272472192 29789398 1460591376 29789394 * __utmz 98837128.1149973722.1.1.utmccn=(direct)|utmcsr=(direct)|utmcmd=(none) gamerentalguide.com/ 1088 3382970624 29826106 226521376 29789394 * Not sure if this tells you anything, but I thought I would let you know that the cookie is being stored.
OK well if the cookie is there, make a new file with <?php echo $_COOKIE['sid']."..."; ?> upload it and run it on the server. It should show you what is stored in the sid cookie and also three dots after. The dots are there incase the cookie is blank. So see if you can print out the cookie value like that. If so, the cookie is there and you need to look at the linking code.
Ok, but the cookie is being stored on my browser. When I open the cookie up it looks like this: sid testing gamerentalguide.com/adwatcher/ 1024 2118632576 29862819 218511376 29789394 * The "testing" word on the second line is the value that I put into the ?sid= parameter (example: www.domain.com/adwatcher/tracker.php?t=22&sid=testing The linking code that I currently show for the GameFly link is <a href="http://www.dpbolvw.net/click-1844536-10298583<? echo "&sid=".$_COOKIE['sid']; ?>" target="_blank">Gamefly</a> HTML: I think its the linking code that isn't appending the value. The code is on the page- http://gamerentalguide.com/index.php BTW- Would you have any problems with communicating with me on MSN Messenger? It would be ALOT faster. You can click on the MSN Icon next to my screenname here on the board in order to message me.
Damn, Hoff........i've said it before and I'll say it again.....YOUR DA MAN! That setcookie script works like a charm. Thanks to you I can now track all my CJ affiliate links! Man this is great! Thanks so much for your continued time and support. I don't know what I would have done without you. Thank you! John