diff options
author | Dries Buytaert <dries@buytaert.net> | 2002-08-16 07:21:01 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2002-08-16 07:21:01 +0000 |
commit | 333e47aced84cd1acf5cd4f4e05203883338699f (patch) | |
tree | 480fd7b872d2e00ed1dd2ecc6c57ba47648c9b4b /modules/taxonomy/taxonomy.module | |
parent | 2c77a38848d313a0e19fec4d60b2aa9f027e3de1 (diff) | |
download | brdo-333e47aced84cd1acf5cd4f4e05203883338699f.tar.gz brdo-333e47aced84cd1acf5cd4f4e05203883338699f.tar.bz2 |
- Made sure the selection boxes don't grow too long. Requisted by kika,
patch by Marco.
Diffstat (limited to 'modules/taxonomy/taxonomy.module')
-rw-r--r-- | modules/taxonomy/taxonomy.module | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/modules/taxonomy/taxonomy.module b/modules/taxonomy/taxonomy.module index b74480624..43bdb1c73 100644 --- a/modules/taxonomy/taxonomy.module +++ b/modules/taxonomy/taxonomy.module @@ -513,8 +513,7 @@ function _taxonomy_term_select($title, $name, $value, $vocabulary_id, $descripti $select .= "<option value=\"$key\"". (is_array($value) ? (in_array($key, $value) ? " selected=\"selected\"" : "") : ($key == $value ? " selected=\"selected\"" : "")) .">". check_form($choice) ."</option>"; } - // min 8, possibly options/3 (set max too?) - $size = max(8, round(count($options)) / 3); + $size = min(12, count($options)); return form_item($title, "<select name=\"edit[$name][]\"". ($multiple ? " multiple size=\"$size\"" : "") . ($extra ? " $extra" : "") .">$select</select>", $description); } |