Gossamer Forum
Home : Products : Links 2.0 : Customization :

3 level new and updated mod

Quote Reply
3 level new and updated mod
I have added the 3 level new and updated mod and also the yahoo categories mod.

My links.db only had 5 links in it so I manually added the date to end of each record and I've gone in a few times to fake some dates and then done a build each time.

The 'new' graphics work fine for the links. But, I can't get the updated graphic to appear at all and no graphics appear with the categories.

I did the mod for both templates and non and I have tried doing a build both ways and I get same results.

Anyone have any ideas what I am missing?
Quote Reply
Re: 3 level new and updated mod In reply to
The updated graphic only displays when the 'Date' field is later than the 'DateAdded' field but less than the number of days specified by $db_new_cutoff in links.cfg.

For example, if the DateAdded is 1-Jun-1999 and the (modified) Date is 1-Jul-1999, then the updated graphic would display if today was 5-Jul-1999 (assuming $db_new_cutoff = 14). If both Date and DateAdded are the same (1-Jul-1999) then only the New graphic displays for that Link. The Updated graphic will not display.

If neither graphic is displaying for the categories (only categories can display both graphics at the same time), then you might want to double check the modification you made to nph-build.cgi (step 6 of the instructions) and sub site_html_print_cat (step 8 of the instructions).

I hope this helps.

[This message has been edited by Bobsie (edited July 18, 1999).]
Quote Reply
Re: 3 level new and updated mod In reply to
Just to let you know, I found the problem.

My fake links.db had the modified dates correct in relation to the added dates (and they were less than the cutoff), but the records were not in order by date added.

When I edited the file manually, I made the DateAdded of the first record more recent than the 3rd record (same category). It was never checking to see whether or not the modified date of the 3rd record was more recent than its added date because a more recent modified date had already been stored by the first record.

I guess that is what I get for working in the wee hours of the morning when I'm tired, but just don't want to quit until I find it. Smile

I decided to work on it tonight before anything else with a fresh mind and it worked.

I had been going over my script for 2 days and it was a corrupt links.db Smile

Thanks for you help.
Quote Reply
Re: 3 level new and updated mod In reply to
That never entered my mind when I wrote the mod, since links are normally added by date sequentially. Perhaps I should look at that again and see if it can be fixed to display the correct graphic regardless of date sequence.