jquery - How to convert textbox value to date format in firefox and Internet explorer using javascript -


I have a textbox (id = 'txtCalendarSeventh') with a calendar control related to it. By selecting any date from the calendar I get the value in the text box in the format-April-21-2014.

I am using the following JavaScript code -

  var dateresult = document.getElementById ('txtCalendarSeventh') value; var d = new date (daterust); Warning (d);   

This code works fine in Chrome and leaves the correct value of the date. But in Firefox or Internet Explorer, this is the perfect date instead of Nain. Nain is showing etc.

"April-21-2014" is not a valid date string, although some browsers may recognize it For, "April 21 2014" should work.

Look for a comprehensive list.

Comments

Popular posts from this blog

Verilog Error: output or inout port "Q" must be connected to a structural net expression -

jasper reports - How to center align barcode using jasperreports and barcode4j -

c# - ASP.NET MVC - Attaching an entity of type 'MODELNAME' failed because another entity of the same type already has the same primary key value -