JSFiddle - React, Tailwind, and code Playground

by bmarsh123

HTML

<link rel="stylesheet" href="http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css">
<script src="http://code.jquery.com/jquery-1.9.1.js"></script>
<script src="http://code.jquery.com/ui/1.10.3/jquery-ui.js"></script>
<select id="mySelection">
    <option value="1">Item 1</option>
    <option value="2">Item 2</option>
</select>
<input type="text" id="datepicker" />
<div id="results"></div>

JavaScript

$('#datepicker').datepicker();
$('#mySelection').change(function () {
    
    var selection = $(this).val();
    
    var data = {
        text: selection,
        parl: selection
    }
    $.ajax({
        // Make a GET request to http://jsfiddle.net/echo/jsonp
        url: 'http://jsfiddle.net/echo/jsonp/',
        dataType: 'jsonp',
        data: data,
        success: function(data) {
            // Get back the same object you sent
            //alert(data.text);
            $('#results').html(data.parl);
        },
        type: 'GET'
    });
});