HTML QuickForm Stumper
| From: | James Reinke | Date: | Thu, 23 Mar 2006 04:54:42 +0000 |
| Subject: | HTML QuickForm Stumper | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-23405@lists.php.net to get a copy of this message | ||
I've been experimenting with using HTML QuickForms to
do something, and cannot figure out a way to do
it...Nested PHP code displayed within QuickForm
elements.
Basically, I need QuickForms to print out php code,
within the JavaScript/HTML code that I'm already
printing out using the HTML QuickForms addElement
function.
For example: (what I ultimately need)
<INPUT TYPE="RADIO" NAME="PaymentType"
VALUE="debitcard"
ONCLICK="Show('debitcarddiv');Hide('creditcarddiv');Hide('checkingaccountdiv')"
<? if($_SESSION['account']->PayType=="debitcard") {
print "CHECKED"; } ?>>Pay by debit card<br />
(what I currently have)
$form->addElement('radio', 'PaymentType',
array('value' => 'creditcard', 'onclick=' =>
'Show(\'creditcarddiv\');Hide(\'debitcarddiv\');Hide(\'checkingaccountdiv\')'));
Is there any way I can have this DHTML page load the
correct div, as well as inserting the CHECKED value?
If anybody has any work arounds or if I missed
something, please advise, thanks!
_____________________
James Reinke
CLEVERSAFE
MOBILE 847.340.7581
jreinke@cleversafe.com
_____________________