phpMyEdit - Viewing Bug Advanced Details [ Go Back ]
267 core / field option feature always 2004-09-22 02:21 2004-10-26 08:12
ned@kelly.org.au x86  
linux  
normal fedora core 1  
feedback current from CVS  
open  
none  
none  
[js][regexp] not working for dropdown list
Below is an example of [js][regexp] with a dropdown list, [js][regexp] works perfect for normal entry fields but doesnt seem to work when used in dropdown lists.

$opts['fdd']['client_on_tax'] = array(
'name' => 'Client on tax *',
'select' => 'D',
'maxlen' => 1,
'values' => array('','Y','N'),
'js' => array(
'required' => true,
'regexp' => '/^[0-9]*$/',
'hint' => 'Please enter a option for Client on Tax'
),
'required' => true,
'options' => 'ACV',
'sort' => true
);
refer
http://platon.sk/forum/projects/viewtopic.php?t=483
for more information on the issue

Bug Notes
hbernard   
2004-10-18 13:56   
Should the regexp match the key or the value of the drop down ?

This is more related with 'required' against dropdown, I think.

if we match the 'required' flag against value, then, this won't allow to put a nice label like "fill this box".

if we match the 'required' flag against the key, what should be the forbidden values (the values that won't allow user to be set).
NULL and "" would be a no-way because you can't properly set your 'values' with such key.

What do you think ?
ned@kelly.org.au   
2004-10-26 08:12   
hi hberhard

sorry, but whats your definition of 'key'

cheers

ned