Welcome to the dBforums forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions, articles and access our other FREE features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload your own photos and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact support.

If you prefer not to see double-underlined words and corresponding ads, place your cursor
here for ContentLink opt out.

Go Back  dBforums > Data Access, Manipulation & Batch Languages > PHP > help needed: how to update php values?

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 09-17-08, 13:00
susapra susapra is offline
Registered User
 
Join Date: Sep 2008
Posts: 9
Smile help needed: how to update php values?

Hi

I'm php newbie. For example, I have a php file like this:

php Code:

<?
$value1="content1";
$value2="content2";
?>

Now I want to create a HTML site with 2 input forms allow me change the values (content1, content2) without edit above file manually. I can enter new data and click update button, then it will update new values of above php file.

How do I create this file? There are no SQL DB or complicated functions.

Thank you

________________________________
christmas gift Audi A4 Clutch
Reply With Quote
  #2 (permalink)  
Old 09-17-08, 14:07
healdem healdem is offline
Jaded Developer
 
Join Date: Nov 2004
Location: out on a limb
Posts: 5,444
you need to define a form within your script whose action points to the same script
you need to define some user interface (two text boxes) names the same as your variables
you need to check if there is a value in the variables before assigning the variable

eg
if isset($Request['Value1']) {$Value1=$Request['Value1'];}
have a look at the examples of designing forms in PHP
__________________
Warning
May! contain traces of NUT. people with NUT allergies should not pay attention to any of the above
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On