*the question has been answered but is replaced with a problem*
the problem is this:
I'm sending some info to flash.php with this code
HTML Code:
<form id="form1" action="flash.php" method="get">
<input type="hidden" name="value1" id="value1" value="SOMEVALUE">
<a href="flash.php" onclick="document.getElementById('form1').submit(); return false;">Flash</a>
</form>
and im trying get that info out on the page with this:
PHP Code:
$val = $_GET['value1'];
echo $val;
I don't get any value from:" echo $val; but the info shows up in the url(since its a get form)
.../flash.php?value1=SOMEVALUE
If anyone could think of any reason why echoing the variable doesent work then please post it
----
helpers that made me get this far:
nayes84 ,
lynxus
----
----
original post
----
hey everyone. I have a question about forms.
ive seen examples in diffrent tutorials about forms that send user input to other pages.
Code:
<form action="welcome.php" method="post">
Name: <input type="text" name="fname" />
</form
in my code i'm trying to use this method on a link so i can get diffrent values
i thought i neaded to add a value to the post(since none gets inputed)
Code:
<form action="flash.php" method="post" value="flash">
<a href="flash.php" >Flash</a>
</form>
and then i would simply get the value using $_POST
unfortunately for me it doesn't work
would really appreciate if someone could tell me what im doing wrong or if you just cant do it in the way i tried
thanks a bunch for looking
would save me a lot of work if i can get this working so please help me out
