1

i try to set a style to a form_dropdown of codeigniter but is not wokrk. my code is:

<?php echo form_dropdown('week_id',$weeklist,'class ="form-control selectpicker"'); ?>

Also i try to use the html code with this class and work prefect so my external links of .css and .js are true. Any suggestions? Thanks in advance.

1 Answer 1

3

leave third argument empty.Put class in 4th argument it will work.

<?php echo form_dropdown('week_id',$weeklist,'','class ="form-control selectpicker"'); ?>

3rd argument is to pre select a value in select box and 4th is to add id and class etc. Refer Here

form_dropdown('shirts', $options, 'large', $js);

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.