change selectbox to a list of radiobuttons
Mantichora - September 27, 2007 - 16:58
| Project: | Private nodes |
| Version: | 5.x-1.x-dev |
| Component: | User interface |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Description
Hi,
I realize it's because of personal taste but I have changed the select-box to a list of radiobuttons.
The select-box looks OK on the edit profile page; but it really doesn't look that good on the edit node page.
So for those who feel the same:
Change
function private_nodes_form_alter($form_id, & $form) {
...
$form['account']['privacy'] = array(
'#type' => 'select',
'#title' => $title,
'#options' => $options,
'#default_value' => $current_level,
);To
function private_nodes_form_alter($form_id, & $form) {
...
$form['nodeoptions'] = array(
'#type' => 'fieldset',
'#title' => t('Access options'),
'#collapsible' => TRUE,
'#collapsed' => TRUE,
'#weight' => 20,
);
$form['nodeoptions']['privacy'] = array(
'#type' => 'radios',
'#title' => $title,
'#options' => $options,
'#default_value' => $current_level,
);
#1
This is a good idea, now I'll test it.