GeorgeFowler Posted October 9, 2014 Share Posted October 9, 2014 Every other time a user/users click on a link I want the link to change to a different url the next time a user clicks onto that link. For example two links url1.html url2.html url1.html shows up when a user clicks that link the link auto changes to then when a new user clicks the linke url2.html then back to url1.html and so on? Don't know where to start on how I would do this let alone have the server remember to keep which ever link to be held for the next user? Quote Link to comment https://forums.phpfreaks.com/topic/291528-change-link-every-other-click-on-page/ Share on other sites More sharing options...
ginerjm Posted October 9, 2014 Share Posted October 9, 2014 Is this link on the page at all times? Meaning - when they click the link and it goes to url 1, does the link still show up on wherever url1 is? Or do they end up somewhere else and you want to remember where they went so that if and when they use this starting page again, you can direct them to url2 the second time? Quote Link to comment https://forums.phpfreaks.com/topic/291528-change-link-every-other-click-on-page/#findComment-1493129 Share on other sites More sharing options...
GeorgeFowler Posted October 9, 2014 Author Share Posted October 9, 2014 I want it so on page load the server can deside which url was last posted and clicked this way the other url can be posted this time in the clickable link onto that page. Basically I have a regular link on the page and I want every other user that clicks that link to be sent to an ad while the other half of users clicks go through content. Quote Link to comment https://forums.phpfreaks.com/topic/291528-change-link-every-other-click-on-page/#findComment-1493149 Share on other sites More sharing options...
ginerjm Posted October 9, 2014 Share Posted October 9, 2014 By the time your process reaches 'page load' the server is out of the picture. And if this is all about sending un-suspecting users to an ad with your links instead of where they think they are going - Shame! Quote Link to comment https://forums.phpfreaks.com/topic/291528-change-link-every-other-click-on-page/#findComment-1493155 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.