Lompat ke konten Lompat ke sidebar Lompat ke footer

Codeigniter Select Option Set_Value

Codeigniter Select Option Set_Value. I already try for many ways but it doesn't work. The first parameter will contain the name of the field, the second parameter will contain an associative array of options, and the third parameter will contain the value you wish to be selected.

javascript - AJAX filling dropdown in codeigniter - Stack ...
javascript - AJAX filling dropdown in codeigniter - Stack ... from i.stack.imgur.com
However, if you are a beginner in codeigniter i suggest you. If you want to know: This tutorial shows you how to fetch data from database in codeigniter.

So you have to check the value of the $option variable with each iteration of the loop and if it matches another variable (which you should set in your controller) it sets the true.

In this tutorial, i show how you can load data remotely in a select2 element in the codeigniter project. The codeigniter documentation is vague on how to set the default value in a select tag when you are using the form helper. Select2 is easier to initialize on the html <select > element. Here is the steps to create helper , just crate a file called.


Posting Komentar untuk "Codeigniter Select Option Set_Value"