Ell20 Posted October 14, 2008 Share Posted October 14, 2008 Hi, I have been dabbling in PHP/MySQL for a month or two now so I know a little bit about it. However I have come across something which I am unsure how to do so I was hoping you guys/girls could help me. I am helping a friend run a MMORPG (Online Game) and basically we want our users to vote for our site on gamer websites so that we become more popular. Now we have added ourselves to these voting site we are given a direct link to give to our users to vote. Now I need to: 1) Count the vote when they vote and add it into the database. 2) If they dont vote and they just close the pop up then dont count their vote. I am very unsure on whether number 2 is possible, if its not, would it possible to have a timer, so if they close the window within 3 seconds then they dont get their voted counted? Appreciate any help with this Elliot Quote Link to comment Share on other sites More sharing options...
grim1208 Posted October 14, 2008 Share Posted October 14, 2008 in your pop up insert this <meta http-equiv="refresh" content="6 ; url=javascript:parent.close()"> content 6 is the timer i believe represent 10seconds ... but in the pop up if the user doesn't click vote w/ in the alotted time then, poof it's closed have you used php/mysql succefully enough to connect to db and able to access mysql queries? Quote Link to comment Share on other sites More sharing options...
Ell20 Posted October 14, 2008 Author Share Posted October 14, 2008 Thanks for your answer but I dont want to close the popup on the user. I want them to click the link, then the pop up displays. Then if they close the popup within 3 seconds then allow it, but display a message saying "Vote not counted you need to vote before closing the window" Thanks Quote Link to comment 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.