PDA

View Full Version : Need help with what I think would be considered PHP


bfd251
03-08-2006, 06:09 AM
I have a very simple idea that I need some direction with. I am trying to add to a web page 8 boxs that visitors can put there number in a box and then click on a submit button which would update the page with the information that they entered. I would like this to be live. I also need it to be able to remove their number at a later date if they want to.

Thanks

Fou-Lu
03-08-2006, 09:10 AM
This can be done with php assuming a static page usage.
However, what you are doing is not too clear. First, how are you planning on tracking information for a user? I would not recommend the use of cookies. The only real method you can look at is a membership based system or email, otherwise deletion would not be possible. You also need to consider your methods for storing and retreival, whether it be by sql, xml, textfiles, etc.
Hope that gives you some direction.

Yaggles
03-08-2006, 11:05 AM
You are wanting for users to enter something into a text box, for the server to save it, and for the user to be able to go back and edit it?

First, yes that can be accomplished with PHP. But you will need to store the information somewhere, be it in a .txt file, a database (mysql, mssql, etc.), or some other creative method. And then you will need to be able to authenticate the user so that they will only be able to edit or delete thier own information. My suggestion is that you find a host that allows mysql, because it is the easiest, and fastest, way to retrieve data like you are wanting. Then, you will need a database, two tables (one for authentication, one for the information the user submits), a form for registration, a form for submitting the data, code to retrieve and show data from the database, based on the user, and a link that goes to a page that deletes the data if the user clicks it, but only their data. It's not too hard, really, but it will take time to code. I would actually do it for you if I knew more about what you were wanting, AND if I had enough time, But sorry I don't have time to do it for you. ;) If you need a few code snippets to get you started, however, I might be able to help! :)

degsy
03-08-2006, 01:29 PM
Here is a good PHP turorial
http://www.zend.com/php/beginners/index.php
Databases - http://www.zend.com/php/beginners/php101-8.php

A basic membership tutorial
http://www.phpfreaks.com/tutorials/40/0.php