• 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

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource [duplicate]

How to submit a form when page loads using JavaScript?

selected value from the listbox in php

how to retrieve the first and last instance of a row in pdo dataset

Laravel database insert with combining array and string

Parameter is not sent to Laravel route in Ajax

Autoloading classes in PHPUnit using Composer and autoload.php

Laravel 5.1 how to use {{ old('') }} helper on blade file for radio inputs

How to make dot match newline characters using regular expressions

How can I make this nested location configuration use the correct path to call a php program?

zsh: command not found: php

Valet, Xdebug after reboot Big Sur not working

PHP Imap , php 7.4.3 on mac osx catalina

How can I format this number correctly using PHP?

Unable to guess the mime type as no guessers are available Laravel 5.2

About Contact Privacy policy Terms and conditions