• 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

Loading data from MySQL and populating dropdown select with jQuery Mobile, PHP

phpmysqljquery-mobile


PHP Snippet 1:

header('Content-Type: application/json');
echo json_encode($data);

PHP Snippet 2:

$.each(data,function(index,item) 
{
    $('<option>').val(item.id).html(item.job_name).appendTo("#job_id");
});

Related Snippets

phpMyAdmin Accepts NULL in the NOT NULL field

how to check version of codeigniter framework?

CodeIgniter 3 is generating a session file on each request, why?

How to redirect to another page and call a Function there on Angular ng-click

Cannot pass null argument when using type hinting

How to get an Array value inside an object in an array Php [duplicate]

Log a user out of a website when they put their computer to sleep

PHP - installing Xdebug on Mac with XAMPP (Unix File)

How to read laravel_session cookies saved in cookie memory of browser in client side?

php mysql + create a friend request system

WHERE IN array binding in DB::raw laravel 5.4

PHP Startup Unable to load dynamic library /usr/lib/php/20151012/php_mysqli.dll

php: command not found Command PhaseScriptExecution failed with a nonzero exit code

How to loop a tree array with unknown depth and get array blocks?

Inserting data into SQL Server Db An Invalid direction was specified

About Contact Privacy policy Terms and conditions