Jump to content

Recommended Posts

Hi, I am new to PHP and mySQL. I am working on a golf site where it will need to have the user update info through text boxes. There are two things: 1) It will need to keep an average of the last 6 rounds. The user will need to be able to input the current round score and have it bump the oldest score of the database. 2) Also, i have a database of players that will populate a <select>. Is there a way to have the user be able to add/delete player names from this database? My question is what functions are needed to get this done. And how does one go about implementing them.

Thanks in advance!

Taylor

Link to comment
https://forums.phpfreaks.com/topic/235644-user-updates/
Share on other sites

you basically need to build a cms to do it all, i know that sounds vague but its what the answer is.

 

this will involve a lot of rather involved code that a beginner might struggle with.

 

a good starting point would be to build a form that a user can enter a new players details with which then posts to a page that validates the input and save all of it to the database.

 

you will also need a page that lists the users, with links from each player to edit/or delete, the edit option can link to the original form for adding a user, and be adapted to be prepopulated with that users info for editting.

 

the database will need another table for scores, with a column that links to the users/players table so you can select scores filter by player, as well as some maths functions to show the last 6 rounds in averages.

 

you will also need to add security to prevent sql injection, unwanted users on the site, and preventing players altering each others scores!

 

its not a small undertaking for sure.

 

 

Link to comment
https://forums.phpfreaks.com/topic/235644-user-updates/#findComment-1211143
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.