create php table to input a string Can you hel ?
Posted by jesus000 (jesus000), 10 November 2003Can you help? I am novice in php. I have a webpage that I have to create a table with php. on focus with the mouse another window should be created, to input a string (eg. name and surname). On this window I have to create two buttons one for delete and another for add to increase the rows in the tables. thank youuuu
Posted by admin (Graham Ellis), 11 November 2003Scheme ...
b) In your popup, create an HTML form with TARGET= back to the original
c) Enter your text through a form, and append the information for each row of the table to a file, then refresh your target window with the entire contents of that file.
There's quite a lot to do / learn here; I'm concerned that there are a lot of technologies for a newcomer and I would suggest that you start with the form and the table in the same window, refreshing the whole window each time.
One question to ask very early on - will you have several users at the same time? If you will, you'll need to have a different file for each of them; I would suggest that you use PHP's session functions for this.
Posted by jesus000 (jesus000), 11 November 2003Thank you very helful ! any code that could inlight me more ?
Posted by admin (Graham Ellis), 11 November 2003on 11/11/03 at 19:25:33, jesus000 wrote:
I could give some snippets / thoughts, although not this evening. Please do answer my question about multiple users and persistance needed so I can better tune my answer, though!
Posted by jesus000 (jesus000), 11 November 2003Dear Graham
I already set it up for two users.
I will explain in more details what I need to do.
On my second page there should be the table. for a sequential list ( string ), containing text fields. You know ! " to - do " list. When one of the table cells is clicked a new window should open containing an editable version of the cell contents. By cliking a change button in this window should update the contents of the cell on the second page. Later if the page is revisited the change should be displayed. The new window should also contain a " delete " button which removes the cell from the table. and the second page should also contain a button to " add " a new cell to the list. Clear ? I hope so. common man I know you can do it. Chis.
Posted by admin (Graham Ellis), 12 November 2003This forum is very much intended to help people who have questions about PHP as they write their own code, rather than to write code that people need free of charge .... you're certainly right that I could do this (given perhaps a little bit of time), but you wouldn't learn, and you probably couldn't support the code once it was completed. I do notice that you're a PHP novice .... that's fine - start coding, and do post up any problems that you encounter and we'll help you through.
I am going to re-iterate. Take the exercise in gentle steps and do NOT start off with multiple windows as that over-complicates things. Start off with a test program that reads a file and produces a table in a loop ....
Then go on to write the code to handle the form that's submitted.
There's plenty of other resources available to help you too with this project as you work through it; as well as this forum, there are on line tutorials, books - see http://www.wellho.net/resources/phpbooks.html, training courses - see http://www.wellho.net/overview/hball.html etc
Posted by jesus000 (jesus000), 12 November 2003Thank youuuuu !
PH: 01144 1225 708225 • FAX: 01144 1225 899360 • EMAIL: email@example.com • WEB: http://www.wellho.net • SKYPE: wellho