[geeklog-devel] Links categories (was: Upgrading from 1.4.1 to 1.5)
dirk at haun-online.de
Mon Dec 31 05:56:03 EST 2007
Dirk Haun wrote:
>Looks like the update for the Links plugin isn't working properly - all
>my links lost their category
While attempting to fix that, I ran across a few oddities and issues
with backward compatibility. I fixed those but would like to hear some
comments to see what others think, please.
Before 1.5, the link categories served as both an ID and a (descriptive)
label. The new Links plugin separates that, so now we have a link ID
(cid), a category name and even a category description.
When upgrading from earlier versions, the code in CVS tried to assign
new IDs to the categories. Also, the URLs for the categories on the
public list of links were changed to use that new cid. That, however,
broke existing links pointing to categories.
For example, on geeklog.net we have a category "Tech. Sites". The link
to that category is .../links/index.php?category=Tech.+Sites
After the upgrade, that would have become .../index.php?
cid=20071231114832121 and the old URL would have stopped working.
So I decided to rewrite that part and keep the old URLs intact - and
therefore allow a cid to include spaces (and other special characters),
just like before. So the cid is not really an ID in the sense we use
that elsewhere (e.g. in stories).
Anyone see a problem with that?
Also, the Links plugin now has a [category:] autotag (new in 1.5).
However, that won't work with these sorts of IDs, e.g.
The way autotags work, the blank would be seen as the end of the ID, so
it wouldn't work. Instead of trying to come up with fancy workarounds
(e.g. use Tech.+Sites as the ID, i.e. urlencoded) I'd suggest we simply
drop that autotag.
More information about the geeklog-devel