DiigIT | IT Community
No Profile Image
Welcome Guest
New User? Register | Login
DiigIT » PHP »

Trying to automatically put a button value in a textbox..

By: | 05 Aug 2009 12:06 pm

Hello all! I'm trying to put a button value in a textbox. See, a username is a button and when another user wants to send a message to that user it pops up the send message page in which I want the username to be in the "TO:" textbox.

 

Any help?

This is what I have:

The button:

<input type="submit" onClick="document.location.href='http://revideolution.com/senduser.php'" name="tousercommunity" value="conrad" />

Message on a different page:

<label>To:<input type="text" id="tousercommunity" value="<?php print($_SESSION['tousercommunity']); ?>"/>

Comments

No Comments Posted for this Article.

Leave a comment

Enter the text in the image
img
Can't read?
Type the characters you see in the picture below.


Close Move