Recent Topics

1 Jul 01, 2006 02:17    

Popular requests are post trimming, or at a specific date do certain actions.

Like, one month from now delete this post, etc.

Now ways to do this would be, when the evo core is loaded it will have something like;
if ( ! $DayActions->Done ) $DayActions->Do();

Now say for the delete a post in a month example, to add this event, the user would;
In the 'write a post' page the user would have a 'actions' panel to the right, with:
This post's actions:
[ Listing of current actions ]
25th of July, 2006 (Or whatever date format the user has specified) - Delete this post.
New Action:
[ Date ] - [ Action ]
[ Add ]

So when the add button is clicked, the entry is then added into the actions table in the b2evo database, so something like;
Thing, ID, Date, Action
Post, 32, 25-07-2006, Delete

Now when $DayActions->Do is called it will run through the actions table, and for all actions with dates of the current day or earlier, perform the action.

Thoughts?

2 Jul 01, 2006 13:37

There will be a "scheduler" in 1.8 and it should handle those things, too.

However, the scheduler is just the framework, so you don't need

if ( ! $DayActions->Done ) $DayActions->Do(); 

because it gets called/checked regularly.


Form is loading...