Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC:

Auto Unpublish, Auto Publish Down if expired 13 May 2013 04:47 #7176

  • Maujb
  • Maujb's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 27
  • Thank you received: 2
Hi all,
I am creating a component that has 'start date' and 'end date'.
I would like to automatically unpublish the item id the date is older than the current date.

Does anyone have any clue how to do it?

Thanks

Please Log in or Create an account to join the conversation.

Re: Auto Unpublish, Auto Publish Down if expired 13 May 2013 14:06 #7182

Hi Maujb

One way this can be accomplished is by using a standalone script as a cron. On the server, the script should be setup as a scheduled task to run at given intervals. It would then check for current and expired records and publish or un-publish them based on the server-time.

Read this link to understand how to connect to your component from an external script: Connecting to J-Cook from external Scripts / Crons

Your hosting provider should have the info you will need to schedule a task on their server.

Let me know if this helps.

Regards
v

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Time to create page: 0.073 seconds

First let me congratulate you on an excellent/outstanding product. Just tried for one hour but was very impressed.
Marret (Forum)

Get Started