SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Zealot
    Join Date
    Dec 2006
    Posts
    120
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    getting the day of a selected date... how?

    hi, i'm using a javascript calendar to let my user to select the date...

    it is available at:
    http://www.mattkruse.com/javascript/calendarpopup/

    it enable the user to put the selected day in a textfield in "yyyy-MM-dd" format.

    however, i wish to display the day to another textfield
    PHP Code:
    <input type="text" name="day"
    is it possible to do so with the javascript? how?

  2. #2
    SitePoint Addict jtrelfa's Avatar
    Join Date
    Oct 2004
    Location
    Troy, Mi
    Posts
    231
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    If you look at some of his source code, you'll notice that the calendar links in his "simple" popup implementation calls a function:

    CP_tmpReturnFunction(2006,12,27);

    Which puts the date into the adjacent text field. You can check that function in his js file to see how it handles the date information.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •