[support] Betterselect module warning

Arto Pastinen arto.pastinen at gmail.com
Sun Aug 26 10:44:46 UTC 2012


 '#options' => locations_arr,  ->  '#options' => $locations_arr,

2012/8/26 Kamal Palei <palei.kamal at gmail.com>:
> Hi All
> I am using betterselect module. I have a custom form, part of code looks as
> below.
>
>    $locations_arr = array(
>     '0' => t('-Select-'),
>     '1' => t('Anywhere in India'),
>     '2' => t('Anywhere in North India'),
>     '3' => t('Anywhere in South India'),);
>
>  $form['name']['prefloc'] = array(
>  '#type' => 'select',
>  '#multiple' => TRUE,
>  '#title' => t('Preferred Work Location'),
>  '#options' => locations_arr,
>  );
> When I access the form page, I get warning "warning: Invalid argument
> supplied for foreach() in
> C:\http\wamp\www\netcloudjobs\sites\all\modules\betterselect\betterselect.module
> on line 104.".
>
> Please let me know, where I am wrong and how to fix this issue.
>
> Thanks
> Kamal
> NECS, Bangalore
>
>
>
> --
> [ Drupal support list | http://lists.drupal.org/ ]



-- 
regards, Arto Pastinen
GPG key on wwwkeys.de.pgp.net, FP: DF04 1644 0812 9633 306F  9CCA 660C
285F 501C 8312


More information about the support mailing list