Page 1 of 1
Simple Post Problem
Posted: Fri May 21, 2004 11:44 am
by Eroc
I have the following link that I am passing the username to default.aspx to....
Code: Select all
I am passing this name: <br><br><?php echo $userdataї'username']; ?><br><br>With this link:<br><br>
<form action="http://localhost/clanmanager/default.aspx" method="post">
<input type="hidden" name="userid" value="<?php echo $userdataї'username']; ?>">
<input type="image" src="clickme.jpg" border="0">
</form> I have the following code:
Which displays the 'echo $userdata' fine... the problem is when it submits to the default.aspx it's not passing the username. I am overlooking something, can someone help me?
Thanks,
Eroc
Posted: Fri May 21, 2004 11:47 am
by jason
How do you know it's not passing the userid?
Posted: Fri May 21, 2004 11:50 am
by launchcode
View the HTML source of the page before submitting - is the hidden field with the userid in there?
If so the problem is in your ASPX file (and wouldn't that make a change

)
Posted: Fri May 21, 2004 12:13 pm
by feyd
is the code above on a live server? ... cause it's going to localhost..
Posted: Fri May 21, 2004 12:20 pm
by Eroc
localhost cause I am dialed in via Terminal Services....
How do I know? It's a script file that's worked for quite some time where other programs pass it the username.
when I look at the html source it has this:
Code: Select all
I am passing this name: <br><br>Anonymous<br><br>With this link:<br><br>
<form action="http://localhost/clanmanager/default.aspx" method="post">
<input type="hidden" name="userid" value="Anonymous">
<input type="image" src="clickme.jpg" border="0">
</form>
That help any?
Thanks for the input !
Eroc
Posted: Fri May 21, 2004 12:22 pm
by launchcode
Sure - providing that "Anonymous" is a valid userid it means there is nothing wrong with your PHP code at all. It is doing exactly what you told it to do.
This clanmanager ASPX script is either expecting a different value to be sent to it, or a different method (GET instead of POST maybe?) but the problem IS there.
Posted: Fri May 21, 2004 12:42 pm
by Eroc
Great I'll have them check their side of things. Appreciate the info !
Eroc