Hi People, i wanna ask you something.
i have a form with select box with different values
i want when one people choose one value of select box and click on submit
delete the value from the select box and remain the other value.
i have custom code with this code
and before i have the db save
with the table jos_chornoform and model id content
this is the debug:
nothing happen, it only create a new table in jos_chornoform with null value in the db
Help me please.
i have a form with select box with different values
i want when one people choose one value of select box and click on submit
delete the value from the select box and remain the other value.
i have custom code with this code
<?php
if ( $form->data['select'] == '1') {
$db =& JFactory::getDBO();
$query = 'UPDATE `jos_chronoforms` SET `content` = '<div class="ccms_form_element cfdiv_select multiline_start multiline_add" id="select_container_div"><label for="select">SELECT</label><select size="1" id="select" class="" title="" name="select"><option value="2">2</option><option value="3">3</option><option value="4">4</option></select><div class="clear"></div><div id="error-message-select"></div></div><div class="ccms_form_element cfdiv_submit" id="autoID-637e4a043cb63f2fc21335a1ede89e29_container_div"><input name="input_submit_12" class="" value="INVIA" type="submit" /><div class="clear"></div><div id="error-message-input_submit_12"></div></div>';
";
$db->setQuery($query);
$db->query();
}
?>
and before i have the db save
with the table jos_chornoform and model id content
this is the debug:
Data Array:
Array
(
[select] => 1
[input_submit_12] => INVIA
[039b288a50a4cb123270bd937576cb37] => 1
[option] => com_chronoforms
[chronoform] => PROVASELECT
[event] => submit
[Itemid] =>
[content] => Array
(
[cf_uid] => 53d0234d6057d4748471f208242f0bbc
[cf_created] => 2012-05-04 12:33:07
[cf_ipaddress] => some ip
[cf_user_id] => 0
[select] => 1
[input_submit_12] => INVIA
[039b288a50a4cb123270bd937576cb37] => 1
[option] => com_chronoforms
[chronoform] => PROVASELECT
[event] => submit
[Itemid] =>
[id] => 52
)
[content_id] => 52
)
nothing happen, it only create a new table in jos_chornoform with null value in the db
Help me please.