• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

how to insert data into select2 search input after scan using qrcode

javascriptphpcodeigniterjquery-select2


PHP Snippet 1:

$('#add_order').select2();

PHP Snippet 2:

$(function(){
  //Your script
  console.log($('#add_order').lenght);//should display 1!
  $('#add_order').select2();
   :
   :
});

PHP Snippet 3:

$('#add_order').val("yourvalue").trigger("change");

Related Snippets

Remove categories with all childs derived from parent category

getting error while enter Command => php artisan route:list

Refresh specific HTML content that retrieves data from MySQL

Auto increment id JSON

php 7 php.ini upload_max_filesize not working

How to change 'users' auth table and use another instead Laravel

how to remove %20 in the url in php

Laravel MSSQL Server Connection not working

How can i hide dt if dd got empty value

How to get median and quartiles/percentiles of an array in JavaScript (or PHP)?

RabbitMQ PRECONDITION_FAILED - unknown delivery tag

PHP header location absolute URL

*** ERROR *** The PHP configuration loaded file is: c:/wamp64/bin/php/php8.1.0/php.ini - should be: c:/wamp64/bin/apache/apache2.4.53.1/bin/php.ini

Using Associative arrays

Dropdown with current value from Mysql

About Contact Privacy policy Terms and conditions