简体   繁体   中英

Codeigniter form_dropdown issues

I need a bit of help.

I have this in my view

$salutation = array(
        'Mr.' => 'Mr.',
        'Mrs.' => 'Mrs.',
        'Dr.' => 'Dr.',
        );    

    echo form_open('membership/update');

    echo form_dropdown('Salutation', $salutation, 'Mrs.');

The dropdown works in all but one fashion, it does not pre-select 'Mrs.'. How can I get that to work properly. According to the Codeigniter userguide, I have the proper syntax.

Good News!

I got it to work. After cnanney said it worked for him, I checked the cache in firefox, for some reason it was old cache from a while ago, refreshing and deleting did not help. After a restart, things are good.

Thanks!

When you F5, this change will not appear in the form. You need to hit enter next to the URL in your browser for these kind of changes to appear.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM