Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    New to the CF scene
    Join Date
    Jun 2011
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    How do I display data from a certain date?

    Anyone know how I can display data from a specific date.

    for example posts from today

  • #2
    New Coder
    Join Date
    Aug 2007
    Posts
    35
    Thanks
    3
    Thanked 0 Times in 0 Posts
    It would be helpful to know what fields are available, of course we would need the record to hold a timestamp of date. Is this something for Joomla, Wordpress or alikes?

  • #3
    New to the CF scene
    Join Date
    Jun 2011
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I think you mean archiving. While publishing post just save the date of publish too. Retrieve those post with a particular date by using the condition where date="value"

  • #4
    New to the CF scene
    Join Date
    Aug 2011
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    These two steps, but I like it this way:

    First create a file with a date / time. In this case, the file is 01/10/2008 at midnight

    touch-t 0810010000 / tmp / t

    We can now find all files that are newer or more than the above file (is on file modification date. It can also be used to access cnewer anewer-and-file status changed).

    find /-new / tmp / t
    find / no-newer / tmp / t

    You may also search the files between dates determined by creating two files with the touch

    touch-t 0810010000 / tmp/t1
    touch-t 0810011000 / tmp/t2

    This files are located between the two dates and times

    find /-new / new tmp/t2 tmp/t1-y-no-más /
    Last edited by Fou-Lu; 08-23-2011 at 02:34 PM. Reason: Signatures through control panel only

  • #5
    Super Moderator guelphdad's Avatar
    Join Date
    Mar 2006
    Location
    St. Catharines, Ontario Canada
    Posts
    2,631
    Thanks
    4
    Thanked 147 Times in 138 Posts
    mrkaassis, your solution has nothing to do with mysql though.

  • #6
    Super Moderator guelphdad's Avatar
    Join Date
    Mar 2006
    Location
    St. Catharines, Ontario Canada
    Posts
    2,631
    Thanks
    4
    Thanked 147 Times in 138 Posts
    Fatdank, are your values DATE or DATETIME? if DATE use CURDATE() to find values matching today's date. If DATETIME use BETWEEN.


  •  

    Posting Permissions

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