A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: php? get the starting date of a month?

  1. #1
    Flashkit's Cheerbud LEXGRAPHICS's Avatar
    Join Date
    Dec 2001
    Location
    Miami
    Posts
    250

    php? get the starting date of a month?

    hey guys im trying to develop a dynamic calendar, now i have all the php/mysql/flash knowledge necesary, but i am missing an important piece of info. to make this calendar truly dynamic. i want to be able to see what day of the week does each month start at,

    whether its a sunday, monday,t,turs,fri,or sat. so that i can start day 1 from there. and i already know to set the months lengths and the february how to check for leap years.

    any help would be greatly appreciated, is there some sort of formula to do this?

    thanks in advance.

  2. #2
    Registered User
    Join Date
    Feb 2001
    Posts
    13,041
    Hi,

    in flash set a new Date object to the first of a month and then use getDay() to retrieve day of week

    Musicman

  3. #3
    Flashkit's Cheerbud LEXGRAPHICS's Avatar
    Join Date
    Dec 2001
    Location
    Miami
    Posts
    250

    im not exactly sure i understand

    i set as new date date object.

    myDate = new Date()

    then how do i use the getDay, dont i haveto supply it a month and a year????

    do you have a code example or is in in the flash help area?

    thanks

  4. #4
    Registered User
    Join Date
    Feb 2001
    Posts
    13,041
    Hi,

    myDate = new Date(2004, 7, 1);

    Note that days count from 1 and months count from 0

    Musicman

Posting Permissions

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




Click Here to Expand Forum to Full Width

HTML5 Development Center