Search
Other Conditional Content questions
Forum

hide/show article within period/after expiration custom error

nimdas's Avatar nimdas
Hello Team,

I want to hide or show an article accessible on a specific url within a particular date/time frame. If that period is out of the defined period to show a custom article/pop-up: "the requested page is either moved/expired etc. Please contact the administrator for more information".

So based on the docs4.regularlabs.com/conditionalcontent...how-to-use-it-syntax do I have to perform those steps:

1. authenticated joomla super admin > components > Regular Labs Conditional Content >
2. Under new condition > set rules to "ALL" and add the desired article + the conditions as Matching Method (include or exclude)?

If the described steps are incorrect, can you please provide an example of what {show} or {hide} I should set up within the article, and what will the config inside the component look like?

Thank you for the examples & support.
Peter van Westen's Avatar Peter van Westen ADMIN
With Conditional Content create a {show} tag where you select the time frame you want to show the article.
Then in the Alternative Content ({else}) you can place the code to show the popup text.

You could do this with the use of Articles Anywhere and Modals too, like this:
{show date="2023-05-01 to 2023-06-01"}

   {article title="The title of the article you want to show"}{/article}

{show-else}

   {modal html="The requested page is either moved/expired etc. Please contact the administrator for more information." open="true"}{/modal}

{/show}
Please post a rating at the Joomla! Extensions Directory
You can only post on the extension support forum if you have an active subscription and you log in

Buy a Pro subscription