Menu
I’m just wondering how I get the value of a text box which has the same name as the paragraph it is in.
In javascript I used:
[CODE]document.forms[0].UserInfo.value
but in php I tried:
[CODE]<?php echo $_POST[‘UserInfo’]; ?>
to get the value and display it as text.
I’m guessing it is because the html looks like this:
[CODE]<p id=”UserInfo”>What is your name?</p>
<div>
<input type=”text” name=”UserInfo” size=”40″ />
</div>
The HTML is all in one form and I do not have access to it to change it.
Any help would be appreciated.