Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Passing a Value to Popup from Button OnClick

Status
Not open for further replies.

Mickbw

Programmer
Jul 9, 2001
84
US
Hi,

I'm sure there is a very simple answer to this question.

I have a form on which I will have several regular buttons. When one of these buttons are clicked it will pop up a window where the user can select a color for that value.

Code:
<td><input type=&quot;text&quot; id=&quot;MonthColor&quot; name=&quot;MonthColor&quot;>
<input type=&quot;button&quot; onclick=&quot;window.open('Colorbar.php','ColourIt', 'scrollbars, height=200,width=200');return true&quot; onfocus=&quot;this.blur()&quot; value=&quot;Month Color&quot;></td>

Is there a way to pass the name of the button to the popup page without using a submit button. I want to save the Submit for when I call the page based on these Properties that the user sets here.

Thanks for your time and any help you can provide,

Michael
 
Something like
[tt]<td><input type=&quot;text&quot; id=&quot;MonthColor&quot; name=&quot;MonthColor&quot;>
<input type=&quot;button&quot; onclick=&quot;window.open('Colorbar.php?button=monthcolor','ColourIt', 'scrollbars, height=200,width=200');return true&quot; onfocus=&quot;this.blur()&quot; value=&quot;Month Color&quot;></td>[/tt]
should do what you want. //Daniel
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top