00:00
00:00
Newgrounds Background Image Theme

Yevs just joined the crew!

We need you on the team, too.

Support Newgrounds and get tons of perks for just $2.99!

Create a Free Account and then..

Become a Supporter!

How would I find out how many peopl

1,149 Views | 2 Replies
New Topic Respond to this Topic

I am nearing completion of my game, and I just got a website with a mysql data base. I don't have much experience with php or mysql but I am pretty good at coding so I am sure with a little bit of help I thought I could figure this thing out.

I am trying to figure out how many people loaded my game, like a page view counter, so if my game gets stolen on a bunch of different websites that I didn't upload it to then I can still keep track of how many people loaded into the game. I also wanted the same thing added to each level of my game so I can figure out witch levels are the most popular.

Thank You!


Avocado's Crazy Castle! Free to Play

https://www.youtube.com/watch?v=3mbVqm7qKI8


PHP is used for server side, so I don't think you will be needing that (At least for level counting) assuming your game is coded in just HTML and JS. Instead you should be using Node.JS to create connections to your database(thats one way that I know of) to preform your queries. From there you can run a command like UPDATE `tablename` SET `views` = `views` + 1 WHERE <condition>.

As for flash and actionscript I am unsure how it would be done.


EDIT: If you want to do a page counter, you can run a php script on your website (On page load or whenever) to preform the same action as above. Using PHP's PDO's, you will be able to create and manage your connection.


Tempus Edax Rerum

BBS Signature

Thank you. I will have to learn php soon this is still beyond my understanding.


I was able to find out about Unity Analytics and Game Analytics to track how many people are playing my game... though I don't think they are exactly accurate. Anyway they work for me right now.


Avocado's Crazy Castle! Free to Play

https://www.youtube.com/watch?v=3mbVqm7qKI8