Jump to content


Photo

Display Expiration Date


Best Answer Alejandro , 09 February 2018 - 02:07 PM

Try this:

<?php echo $Time->nice($listing['Listing']['publish_down']);?>
Go to the full post


  • Please log in to reply
6 replies to this topic

#1 PeterD

PeterD

    Advanced Member

  • Members
  • PipPipPip
  • 588 posts

Posted 09 February 2018 - 07:51 AM

How I can display the "Expiration Date" in the detail / listing view? Didn´t find a code for the templates



#2 Alejandro

Alejandro

    Advanced Member

  • Administrators
  • 32291 posts

Posted 09 February 2018 - 02:07 PM   Best Answer

Try this:

<?php echo $Time->nice($listing['Listing']['publish_down']);?>


#3 PeterD

PeterD

    Advanced Member

  • Members
  • PipPipPip
  • 588 posts

Posted 11 February 2018 - 06:50 AM

Thanks, is it possible to set that field for a specific listing type as required



#4 Alejandro

Alejandro

    Advanced Member

  • Administrators
  • 32291 posts

Posted 11 February 2018 - 07:19 AM

You can get the listing type id from $listing['Criteria']['criteria_id'] and use that to build your conditionals.



#5 PeterD

PeterD

    Advanced Member

  • Members
  • PipPipPip
  • 588 posts

Posted 11 February 2018 - 07:38 AM

Last question: In the "Ordering Options" I want to integrate a Expiration Date order. Can I use the field "jr_publish_down" then? And how I order to show the next coming date on the top.



#6 Alejandro

Alejandro

    Advanced Member

  • Administrators
  • 32291 posts

Posted 11 February 2018 - 07:58 AM

The expiration date is not a custom field so you can't do that. There isn't a quick way to incorporate the expiration into the sorting functionality because there's nothing in the code to support this feature.



#7 PeterD

PeterD

    Advanced Member

  • Members
  • PipPipPip
  • 588 posts

Posted 12 February 2018 - 04:25 AM

Ok use a date field then, thanks






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users