What version of PHP are you using that

echo date("l","2005-08-13");
doesn't give you "Thursday"?
 (or "w" for "3" or "N" for "4")
 Ian
 On 10/10/05, Paul Menard <[EMAIL PROTECTED]> wrote:
>
> Gordon,
>
> Not sure there is a 'direct' way to obtaint this. I'm assuming your date
> value is something like
> '2004-07-13' which is standard format for a DATE in MYSQL.
>
> The way I would do this is via the mktime() function. Something like:
>
> $mydate = "2004-07-13";
> // Split the Date var into seperate fields
> list($Year, $Month, $Day) = split("-", $mydate);
>
> // Use mktime to get the UNIX long.
> $date_ulong = mktime(0,0,0,$Month, $Day, $Year);
>
> $time_array = getdate($date_ulong);
>
> //At this point the $time_array contains the assoc. array information for
> the date including the
> DOW.
>
> P-
>
>
>
> --- Gordon Stewart <[EMAIL PROTECTED]> wrote:
>
> > Is there a way I can obtain the day of week - If I have the day, month,
> year ?
> >
> > (not via the time function - But from a database....)
> >
> > Im looking through the calendar and date functions -But can't locate
> > anything suitable...
> >
> > http://php.inspire.net.nz/manual/en/ref.calendar.php
> >
> > http://php.inspire.net.nz/manual/en/ref.datetime.php
> >
> > --
> > G Stewart
> > http://e-services.kwister.com/
> > NZ community groups - [EMAIL PROTECTED]
> >
>
>
>
> Community email addresses:
> Post message: [email protected]
> Subscribe: [EMAIL PROTECTED]
> Unsubscribe: [EMAIL PROTECTED]
> List owner: [EMAIL PROTECTED]
>
> Shortcut URL to this page:
> http://groups.yahoo.com/group/php-list
>
>
>
> SPONSORED LINKS
>   Php 
> mysql<http://groups.yahoo.com/gads?t=ms&k=Php+mysql&w1=Php+mysql&w2=Job+postings&c=2&s=33&.sig=FLGkJVBUdDMln4PBO26sng>
>  Job
> postings<http://groups.yahoo.com/gads?t=ms&k=Job+postings&w1=Php+mysql&w2=Job+postings&c=2&s=33&.sig=cV3rp9pSpCxahJy7imon_w>
>  ------------------------------
> YAHOO! GROUPS LINKS
>
>
>    - Visit your group "php-list<http://groups.yahoo.com/group/php-list>"
>    on the web.
>     - To unsubscribe from this group, send an email to:
>    [EMAIL PROTECTED]<[EMAIL PROTECTED]>
>     - Your use of Yahoo! Groups is subject to the Yahoo! Terms of
>    Service <http://docs.yahoo.com/info/terms/>.
>
>
>  ------------------------------
>


[Non-text portions of this message have been removed]





------------------------ Yahoo! Groups Sponsor --------------------~--> 
Fair play? Video games influencing politics. Click and talk back!
http://us.click.yahoo.com/T8sf5C/tzNLAA/TtwFAA/HKFolB/TM
--------------------------------------------------------------------~-> 

Community email addresses:
  Post message: [email protected]
  Subscribe:    [EMAIL PROTECTED]
  Unsubscribe:  [EMAIL PROTECTED]
  List owner:   [EMAIL PROTECTED]

Shortcut URL to this page:
  http://groups.yahoo.com/group/php-list 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/php-list/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 




Reply via email to