0

Hi,

First up, I am a little lost with events.

I am trying to do this and I can almost say that its not doable:

"one.php"

<?php
echo '<input type="text" maxlength="5" name="bill" value="" /><br />';

$get_pass = 5;
$get_pass1 = 10;
?>

<a href="two.php?getpass=<? echo $get_pass ?>&getpass1=<? echo $get_pass1 ?>">test me</a>
"two.php"

<?php

$one=$_GET['getpass'];
$two=$_GET['getpass1'];

echo $one;
echo $two;

?>

The above works. I want to get at the data inside the text element. Is there anyway to do this or do I have to use forms to fire an event?

Thank you for answering.

sb

3
Contributors
3
Replies
4
Views
6 Years
Discussion Span
Last Post by stonybony
1

Without a form, you don't submit the input field value back to the server, so PHP cannot access the value.

You could therefore: a) wrap it in a form and post to two.php, b) use JavaScript to get extract the value.

Option A is the more reliable.

R.

Votes + Comments
clarified without a doubt
0

@blocblue,

Thank you for clarifying that. Appreciate your help.

I changed the whole thing to a form and now I have to code back some more stuff to make sure that it works well. Thanks again.

sb

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.