value in text box

General discussions related to php

Moderators: egami, macek, gesf

Post Reply
superman
New php-forum User
New php-forum User
Posts: 36
Joined: Fri Jun 27, 2003 11:54 pm

Thu Jul 10, 2003 9:33 pm

how can i show the value in the input text box when i click edit from the previous form? so i can edit the value. thanx a lot.

User avatar
frogrocker
New php-forum User
New php-forum User
Posts: 97
Joined: Mon Jul 07, 2003 10:30 pm
Location: Manchester

Thu Jul 10, 2003 10:20 pm

presuming you mean changing the value in a database, this can be done easily in Dreamweaver...

There is a change record command... this requires a form, and you can make a record set, and then drop the bindings onto the forms, to make 'dynamic initial values'..

However, if you aren't using DW, I can't really help.
"Don't look at the trombones - it only encourages them..."

willplatts@gmail.com

User avatar
swirlee
Moderator
Moderator
Posts: 2257
Joined: Sat Jul 05, 2003 1:18 pm
Location: A bunk in the back
Contact:

Fri Jul 11, 2003 5:47 am

superman wrote:how can i show the value in the input text box when i click edit from the previous form? so i can edit the value. thanx a lot.


Presuming you've stored value somewhere, then the user clicks on Edit you need to send them to a script where:

1. The stored value is retrieved and put into a variable, e.g. $myval
2. The value is displayed in a form text field, like so:

Code: Select all

<?
   echo '<input type="text" name="mynewval" value="' . $myval . '">';
?>


3. When the user submits the form, the form data is sent to another script which updates the stored data with the new value.
Image

superman
New php-forum User
New php-forum User
Posts: 36
Joined: Fri Jun 27, 2003 11:54 pm

Sun Jul 13, 2003 7:09 am

thank you

Post Reply
  • Information
  • Who is online

    Users browsing this forum: No registered users and 1 guest