Tutorial by Examples: dropdown

Create function in MyComponent.php namespace app\components; use Yii; use yii\base\Component; use yii\base\InvalidConfigException; use yii\helpers\Url; use yii\helpers\ArrayHelper; use app\models\User; class MyComponent extends Component ...
The following example creates a Bootstrap Drop-Down menu, using only Blaze and no JQuery. Document Object Model <nav class="nav navbar-nav"> <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="drop...
jQuery datepicker has two options to allow displaying dropdowns for month and year selection. These options make navigation through large timeframes easier. <input type="text" id="datepicker"> <script> $("#datepicker").datepicker({ changeMont...
(Caveat emptor: there are many, many programmers who go into absolute conniptions if they meet code that uses recordsets instead of commands and stored procedures.) <% dim rs, sql dim SelectedUser SelectedUser = request.form("user") if IsNumeric(SelectedUser) then SelectedUser...
Below is and HTML page <html> <head> <title>Select Example by Index value</title> </head> <body> <select name="Travel"><option value="0" selected> Please select</option> <option value="1">Car</option&...
Standard example: @models = Model.all select_tag "models", options_from_collection_for_select(@models, "id", "name"), {} This will generate the following HTML: David The last argument are options, which accepts the following: { multiple: false, disabled: false, ...
Suppose that you need to define a dropdown menu for a particular Acumatica screen, such as the Reports menu on the following screenshot. This can be achieved in three different ways: By adding a toolbar with a menu item to the screen's ASPX By declaring a special "folder" action to ...
In order to clear the selection of those values which are selected using a Select2 drop down,we can use the empty() function. <select id="select2_example"> <option>Option1</option> <option>Option2</option> <option>Option3</option> </select&...
This example will demonstrate the searchable select box in MVC. it uses Ajax to get all records from database as user types the new character. I'll consider Country and its City example to illustrate the functionality of Searchable dropdown box. Code behind is c# with MVC, but its easy to grasp wh...
This is continuation of previous example. Cascading DropDown for country's city name. This method will be called by Jquery when user is done with country selection in parent dropdown. I have followed MVC concept and provided the basic approach for cascading dropdown. Ajax will call GetCityName met...

Page 1 of 1