ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Template showing another entry when trying to access expired entries

March 21, 2011 8:02pm

Subscribe [2]
  • #1 / Mar 21, 2011 8:02pm

    anitza

    14 posts

    So, we have a weblog with discount coupons that have all sorts of expiration dates. Some coupons are for wide release while others are for very small target demographics. Sometimes, when you click on a link that has been published somewhere to one of our expired coupons, it shows a blank page. Sometimes, it shows another coupon that the user was never intended to see. Is there a check that I can put in the template that will basically look to see if the page has expired and if it has to show a specific entry that says the offer has expired? I really don’t want them to see the other offers accidentally.

    I hope that was clear.

  • #2 / Mar 21, 2011 8:09pm

    require_entry=“yes” coupled with {if no_results} should get you where you want.

  • #3 / Mar 21, 2011 8:09pm

    anitza

    14 posts

    Thank you!

  • #4 / Mar 22, 2011 1:14pm

    Lisa Wess

    20502 posts

    Hey anitza - glad Dylan was able to help!  Are you all set now, and got everything working? Let us know if you need any more help.

    Thank you!

  • #5 / Mar 22, 2011 1:27pm

    anitza

    14 posts

    I gave it a try yesterday and it was exactly what I needed. So, many thanks!

  • #6 / Mar 22, 2011 1:58pm

    Lisa Wess

    20502 posts

    Wonderful!  If you need any more help, please let us know in a new thread.  Thank you!

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases