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 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Nov 2004
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question show archives if date is after Now()

    How can i achive this:

    I have a archive database and i want the achives to show up on the page if the date is after the end date.

    The database is a employment database and it has a posting date on and a posting date off so when the date off is reached by the calendar the posting gose offline its then that i want it to show on the page as a linkable text stating that archives are available. Users will click the link and then that will bring them to the archives page.


    I need a example script that will do that for me please.

    Thanks.

  • #2
    Senior Coder
    Join Date
    Apr 2003
    Location
    England
    Posts
    1,192
    Thanks
    5
    Thanked 13 Times in 13 Posts
    shouldnt this just be possible by doing
    if rs("date") > now() then Response.Write rs("date")

    or something o.O

  • #3
    Regular Coder
    Join Date
    Aug 2002
    Location
    USA
    Posts
    478
    Thanks
    0
    Thanked 2 Times in 2 Posts
    And here's an example setting a date range based on posted fields:

    strSQL = "SELECT * FROM MyTable WHERE (TheDateField >= #" & Request.Form("MinDate") & "#) AND (TheDateField <= #" & Request.Form("MaxDate") & "#)"
    J. Paul Schmidt
    www.Bullschmidt.com - Freelance Web and Database Developer
    www.Bullschmidt.com/DevTip.asp - Classic ASP Design Tips


  •  

    Posting Permissions

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