over
over

Reputation: 21

How to get "getValue" value from a var of type Datepicker

I'd like to get the date value from a variable of type jquery Datepicker for instance:

var dp = $("#datepicker")datepicker();

How should I get my "getDate" value from my dp variable?

Upvotes: 1

Views: 79

Answers (1)

Pranav C Balan
Pranav C Balan

Reputation: 115212

The datepicker() returns the reference of the jQuery element so you can use getDate method to get the date.

dp.datepicker('getDate')

Upvotes: 1

Related Questions