SunQuest
 
           Programming Tools
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsProgrammingProgramming Tools

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
  #1  
Old October 1st, 2002, 11:54 AM
Daniel Daniel is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Oct 2002
Posts: 1 Daniel User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Getting the value from an textbox

Hey guys i have a question about how i can get the value from a textbox creted dynamic. Let say i create 5 textbox with the following names : x_1,x_2,x_3. How can i get the values in php.


Thank's

Reply With Quote
  #2  
Old October 1st, 2002, 05:31 PM
fakker fakker is offline
The calm b4 the storm
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jul 2002
Location: Manchester, UK
Posts: 404 fakker User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 7
Send a message via Yahoo to fakker
hi daniel,

I presume you have the <form></form> tags already set up?

you need something like:

<form action="getinfo.php">
<input type="text" name="x_1">
<input type="text" name="x_2">
</form>

then you need to create the "getinfo.php" to actually gather the information....

something like:

<?php

echo "x_1 = " $x_1;
echo "x_2 = " $x_2;

?>

that's very basic, but it will output the values in the text boxes named x_1 and x_2.

Hope this helps!!
__________________
Matt 'Fakker' Facer

mattfacer.com

Reply With Quote
  #3  
Old October 1st, 2002, 05:49 PM
FrankieShakes FrankieShakes is offline
Frank The Tank!
Dev Articles Beginner (1000 - 1499 posts)
 
Join Date: Jun 2002
Location: Toronto, Canada
Posts: 1,246 FrankieShakes User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
Send a message via ICQ to FrankieShakes Send a message via MSN to FrankieShakes
Quote:
Originally posted by fakker
<?php

echo "x_1 = " $x_1;
echo "x_2 = " $x_2;

?>


Or you may want to use:

echo "x_1 = " . $_POST['x_1'];
echo "x_2 = " . $_POST['x_2'];

Depending on whether your <form> method is "POST" or "GET" you would use $_POST or $_GET.

As fakker said, these are just basic methods...
__________________
____________________________________________
Developer Shed Weekly Writer | DevArticles Forum Moderator
Build Your Own KlipFolio Klip With PHP
FrankManno.com - Under Construction
Design Interactive Group - Under Construction

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingProgramming Tools > Getting the value from an textbox


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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 On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway