Gossamer Forum
Home : Products : DBMan : Customization :

Auto deletion question

Quote Reply
Auto deletion question
There is so much talk about an autodeletion mod here, that deletes the records after so and so number of days. Is there a mod that deletes the records on a fixed date, say 23-Jan-2056? I want the visitors to be able to input this date and not the number of days to that date. Any help would be much appreciated!!!

Stian

Ps. Thanks Eliot, if you read this, for the help on the Links script (Event Calendar), but I think DBMan is more suited to my needs.
Quote Reply
Re: Auto deletion question In reply to
No...The mod allows users to choose a number of days. Then the script checks the days against the date_to_unix value of today, then deletes it if that value is today. It is much easier than having people type in the EXACT date format to delete days.

Trust me it works.

Go to the Resource Center and download, install the Mod!

BTW: Have you even tried using the Expirator Codes that Widgetz wrote in one of the Threads in the Links Modification Forum? It does the same thing, but with LINKS!

Regards,

------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
* Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
* Search Forums!
* Say NO to Duplicate Threads. Smile
----------------------









[This message has been edited by Eliot (edited January 24, 2000).]

[This message has been edited by Eliot (edited January 24, 2000).]
Quote Reply
Re: Auto deletion question In reply to
I trust you, and have no doubt that this will work, but...

I have set up DBMan as a calendar, so the user will have to input a date for the event anyway. It's kind of stupid to then ask them how many days before this date. Most will probably say a zillion, so that their listing is displayed forever, for extra publisity.

Any ideas on how this can be done?

Best, Stian.
Quote Reply
Re: Auto deletion question In reply to
Elliot,

I have a question about this mod too. The instructions state that it is not for use with the file upload mod. Is the reason that it will not delete the uploaded file or is it more involved?

------------------
Will
Webmaster
FishHoo! Search index for Fishermen
www.fishhoo.com
Quote Reply
Re: Auto deletion question In reply to
Yea...Because I kept it simple and did not include attached images via the File Upload Mod.

There are codes in this forum and in the Discussion Forum that DO delete attached files via the File Upload Mod.

Regards,

------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
* Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
* Search Forums!
* Say NO to Duplicate Threads. :)
----------------------







Quote Reply
Re: Auto deletion question In reply to
But what about my question? It's hard to say NO to duplicate threads, Eliot, when my original thread threads off, so to speak!
So, how about it? Is it possible to auto delete records at a given date, not amount of days.

Stian


[This message has been edited by stiantot (edited January 25, 2000).]
Quote Reply
Re: Auto deletion question In reply to
It can be done like this using Eliot's mod. Change these lines:

Code:

print "Comparing: '$today' vs '$values[$removeby_field]' ... \n";
if ($today > (&date_to_unix($values[$dateadded_field]) + (86400 * $values[$removeby_field]))) {

To this:

Code:


print "Comparing: ";
print &get_date();
print " vs $values[$removeby_field] ... \n";
if ($today >= (&date_to_unix($values[$removeby_field]))) {

That should work.

------------------
Chris
Quote Reply
Re: Auto deletion question In reply to
Make sure that the delete_by field is formatted the same as your normal date field.

------------------
Chris