Return to Snippet

Revision: 25058
at March 18, 2010 16:07 by tgbdad


Initial Code
$rows = array();
for ($i = -15; $i <= 15; $i++) {
  $rows[$i] = $i;
}
return $rows;

Initial URL

                                

Initial Description
This example will return values -15 through 15 to be presented to the user in a select list for an integer CCK field.

Initial Title
Set allowed integer values in CCK select list using PHP

Initial Tags
drupal

Initial Language
PHP