• 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

How to pass security cloudflare server with php curl

Combine array with same value and add other [duplicate]

Cannot retrieve error message using Symfony HttpClient if the response is not "ok"

PHP array_filter with arguments

Facebook API, get page post link (PHP)

WooCommerce: Add/display Product or Variation custom field everywhere

How do I set the maximum php memory limit

Make certain characters of a word from string bold

Send Outlook 2010 email using PHP

PHPExcel file download using AJAX call

how to get value from array in laravel

Get all WooCommerce products within own plugin

Dropzone: Submit both form data and dropzone at once

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

Wordpress 'post_type_link' hides permalink

About Contact Privacy policy Terms and conditions