JavaScript Multiple date inputs for jquery UI datepicker

I have a datepicker, and I need to be able to enter a date manually in multiple different formats. For example, for May 7, 2015, I need to be able to enter:

05/07/2015 05072015 050715 5715

I understand how to format all these above based off of the the jquery docs, but I cannot figure out how to make the input box take multiple different dates. I can change the format to any one of these individually, which will allow me to type in that specific format, but I can only do this once by defining the "dateFormat".

I found another page where the same problem seems to have been answered, but after many attempts, I cannot figure out how to fit it into my code successfully, here is the link to this page:

Datepicker and allowing multiple input formats

How do I fit that solution into the following code:

<h3>Date Selection</h3>
<label for="from">From</label>
<input type="text" id="from" name="from" />
<input type="text" id="altdate" />
<label for="to">to</label>
<input type="text" id="to" name="to" />
<script>
    $(function() {
        $( "#from" ).datepicker({
            defaultDate: "+1w",
            changeMonth: true,
            numberOfMonths: 2,
            onClose: function( selectedDate ) {
                $( "#to" ).datepicker( "option", "minDate", selectedDate );
            }
        });
        $( "#to" ).datepicker({
            defaultDate: "+1w",
            changeMonth: true,
            numberOfMonths: 2,
            onClose: function( selectedDate ) {
                $( "#from" ).datepicker( "option", "maxDate", selectedDate );
            }
        });
    });
</script>

I have been stuck on this for days, any help is greatly appreciated!!

Answer:1

I want to send some JS Script from controller to GSP view . I do the following attempt. Controller(Purchase.groovy) : def myaction={ flash.script= 'jQuery("div#header").show(1000);' ...

I want to send some JS Script from controller to GSP view . I do the following attempt. Controller(Purchase.groovy) : def myaction={ flash.script= 'jQuery("div#header").show(1000);' ...

  1. send email javascript code
  2. send mail javascript code
  3. send email using javascript code
  4. send javascript alert from code behind c#
  5. send email through javascript code
  6. javascript send html code
  7. send mail using javascript code
  8. javascript send key code
  9. javascript send error code
  10. node.js send javascript code
  11. send verification code javascript
  12. send email html code javascript
  13. javascript send value to code behind

I am making a chrome extension that will take come content from the current selected tab. I am injecting a script file into the current page and that script communicates with the script from the ...

I am making a chrome extension that will take come content from the current selected tab. I am injecting a script file into the current page and that script communicates with the script from the ...

I have the following code in my javascript. I'd like the alert to happen wnen a user checks the radio button, but instead it happens when the page loads, and NOTHING happens when the radio button ...

I have the following code in my javascript. I'd like the alert to happen wnen a user checks the radio button, but instead it happens when the page loads, and NOTHING happens when the radio button ...

So this is what I am after, and I've been told it isn't possibly but I am not going to give up just yet! Let's say the user types in "London" into my location search box and clicks "Geocode" I am ...

So this is what I am after, and I've been told it isn't possibly but I am not going to give up just yet! Let's say the user types in "London" into my location search box and clicks "Geocode" I am ...