I like this module, thanks!
Only one thing...the usual -none- option is missing from the select widget when the field is not required. I don't know enough about CCK development to see where this is messed up.
-Ted
I like this module, thanks!
Only one thing...the usual -none- option is missing from the select widget when the field is not required. I don't know enough about CCK development to see where this is messed up.
-Ted
Comments
Comment #1
tbenice commentedfigured it out,
function revisionreference_allowed_values($field) {
$options = _revisionreference_potential_references($field, TRUE);
foreach ($options as $key => $value) {
$options[$key] = _revisionreference_item($field, $value);
}
if (!$field['required']) {
$options = array(0 => '<'. t('none') .'>') + $options;
}
return $options;
}
should be:
function revisionreference_allowed_values($field) {
$options = _revisionreference_potential_references($field, TRUE);
foreach ($options as $key => $value) {
$options[$key] = _revisionreference_item($field, $value);
}
if (!$field['required']) {
$options = array(0 => '-'. t('None') .'-') + $options;
}
return $options;
}
notice the '-'s around t('None'). the '<' and '>' are being filtered as html i think.
Comment #2
danielb commentedI changed it to use HTML entities and I've given it a quick test run and it does the job. Thanks for pointing that out.