For Programmers: Free Programming Magazines  


Home > Archive > PHP Pear > June 2006 > QF: hierselect show, hide









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author QF: hierselect show, hide
Köteles Zoltán

2006-06-29, 3:59 am

Hi All,

Can I show or hide the second select box in a hierselect?

If I have a hierselect:
$lang_main[0] = "Single lang";
$lang_main[1] = "Multi lang";

$lang_sel[1][0] = "english";
$lang_sel[1][1] = "deutsch";

$opts[] = $lang_main;
$opts[] = $lang_sel;

$lang =& $form->addElement('hierselect', 'lang', 'Please select:', '',
'<br />');
$lang->setOptions($opts);

If someone select the "Single lang" option I don't want to show an empty
select box.

How can I do that?

Thanks a lot
ZoTyA
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com