Thanks
Terion

Happy Freecycling
Free the List !!
www.freecycle.org
Over Moderation of Freecycle List Prevents Post Timeliness.
------------------------------------------------
Twitter?
http://twitter.com/terionmiller
------------------------------------------------
Facebook:
<a href="http://www.facebook.com/people/Terion-Miller/1542024891";
title="Terion Miller's Facebook profile" target=_TOP><img src="
http://badge.facebook.com/badge/1542024891.237.919247960.png"; border=0
alt="Terion Miller's Facebook profile"></a>
George Burns  - "I would go out with women my age, but there are no women my
age."

On Wed, Feb 18, 2009 at 8:29 PM, Paul M Foster <pa...@quillandmouse.com>wrote:

> On Wed, Feb 18, 2009 at 05:25:16PM -0600, Terion Miller wrote:
>
> <snip>
>
> >      What about just accepting any date in to the system, and defaulting
> to
> >      the current date if any numptys/users try to set one before?
> >
> >      Do something maybe like this (untested)
> >
> >      $userDate = strtotime($_REQUEST['date']);
> >      $startDate = ($userDate < time())?time():$userDate;
> >
> >      >From there, you can use the timestamp how you wish.
> >
> >      OOH found it:
> >      $startday  = mktime(0, 0, 0, date("m")  , date("d")+2, date("Y"));
> >
> >      Well no, guess I didn't find it because that code above gives me
> >      this 1235109600
> >
> >      What is that??
>
> It's a *nix timestamp number. Give it to date() this way:
>
> date('Y-m-d', $startday)
>
> And you'll see the date it represents. (It's actually the number of
> seconds since, the Unix epoch, in 1970.)
>
> Paul
>
> --
> Paul M. Foster
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

Reply via email to