date operations

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • toufik toufik

    #1

    date operations

    Hi,
    Are there operator for dates, I need a stuff like this
    dateX = today - x days

    Thanks


  • Jedi121

    #2
    Re: date operations

    toufik toufik a écrit le 27/02/2004 :[color=blue]
    > Hi,
    > Are there operator for dates, I need a stuff like this
    > dateX = today - x days
    >
    > Thanks[/color]

    If in database, use SQL statements otherwise see manual for date() and
    mktime() functions.
    PHP is a popular general-purpose scripting language that powers everything from your blog to the most popular websites in the world.



    Comment

    • Pedro Graca

      #3
      Re: date operations

      toufik toufik wrote:[color=blue]
      > Are there operator for dates, I need a stuff like this
      > dateX = today - x days[/color]

      if today (shouldn't it be $today?) is a Unix timestamp, do

      $dateX = $today - $x * (24*60*60);
      --
      --= my mail box only accepts =--
      --= Content-Type: text/plain =--
      --= Size below 10001 bytes =--

      Comment

      • Bob

        #4
        Re: date operations

        Try this: DATE_ADD(now(), INTERVAL-5 MINUTE) (if you wanna to have it
        in a mysql query!)




        Pedro Graca <hexkid@hotpop. com> wrote in message news:<c1m4vb$1j qu7u$3@ID-203069.news.uni-berlin.de>...[color=blue]
        > toufik toufik wrote:[color=green]
        > > Are there operator for dates, I need a stuff like this
        > > dateX = today - x days[/color]
        >
        > if today (shouldn't it be $today?) is a Unix timestamp, do
        >
        > $dateX = $today - $x * (24*60*60);[/color]

        Comment

        • R. Rajesh Jeba Anbiah

          #5
          Re: date operations

          "toufik toufik" <toufiki@sympat ico.ca> wrote in message news:<m8v%b.156 49$Mo4.549099@n ews20.bellgloba l.com>...[color=blue]
          > Hi,
          > Are there operator for dates, I need a stuff like this
          > dateX = today - x days[/color]



          --
          "Success is not what you achieve, but it is what you die for"
          If you live in USA, please support John Edwards.
          Email: rrjanbiah-at-Y!com

          Comment

          Working...