javascript - How to get html content of a input tag? -


i have input tag:

<input type="text" value="04/09/2013" class="date-time-date width-100 hasdatepicker" name="booking_info[to_time_24_date]" id="to_time_24_date" readonly="readonly"> 

i need content in input tag (all content shown above) when use

$('#to_time_24_date').html(); 

it returns nothing. how can content?

try this:

document.getelementbyid('to_time_24_date').outerhtml; 

Comments

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

javascript - storing input from prompt in array and displaying the array -