Page 1 of 1
Categories don't work anymore
Posted: Thu May 17, 2007 1:19 pm
by steffl
Somehow my categories don't work anymore. If I click on the category link it refers still to the correct URL, but still the startpage is shown.
If I check the Admin Interface, all the categories are still listed and the rewrite rules are still the same than at the time it worked. It's not a matter of one single category either. It doesn't work for the others as well. Serendipity somehow doesn't accept the URLs to the categories anymore and still shows the startpage with all entries.
I don't know which information is needed to solve this problem, but here are some for a start:
Versions: Serendipity 1.1.2, PHP 5.2.2
Blog: blog.stefan-horning.de
At the moment you just can find one category link on the startpage. But here are some more you can try:
categories/Computer
categories/Sound
for example.
Please let me know, if you still need more information.
There is only one hint I have, the weblog was moved in another folder a few weeks ago, but anything seems to work though.
Re: Categories don't work anymore
Posted: Thu May 17, 2007 3:01 pm
by garvinhicking
Hi!
Hm, quite hard to tell without the cateogry associations being shown underneath your articles.
Does the URL
http://blog.stefan-horning.de/index.php ... ish-please!
yield proper urls?
It might work if you add %id% to your categories permalink pattern?
There is only one hint I have, the weblog was moved in another folder a few weeks ago, but anything seems to work though.
You did follow the FAQ on
www.s9y.org and changed all occurences of Paths in the SQL dump you uploadde to the new host?
There are several occurences of full paths in the SQL tables, you need to correct all of them when moving the blog.
Regards,
Garvin
Posted: Sun May 20, 2007 9:55 pm
by steffl
I don't know what you mean by "yield proper URLs". Actually it worked all the time before. So it should be possible now.
When the Blog was moved, my admin did the work in make necessary the changes for me. But as I checked the DB there was already the new path in place. So I don't really think that is the problems source.
I also don't have any idea where to start searching for the reason of this behavior.
Posted: Mon May 21, 2007 10:15 am
by garvinhicking
Hi!
Sorry, I wrote "urls" instead of "entries". So I meant, if you call the URL above, do the entries that get displayed there fit into the category? Or are entries missing, or also entries from a different category?
Can you please ask your admin what exactly he did? I think the problem lies in what he did (or didn't do).
ALso check the s9y configuration in the section 'paths' and 'permalinks', maybe post a screenshot of those values here (make sure the values are displayed on the screenshot)
Regards,
Garvin
Posted: Mon May 21, 2007 10:11 pm
by judebert
The exclamation point is invalid in URLs. I don't know if we escape it for categories; I know we don't do anything with it for titles. (I'm bumping into that myself at the moment.)
Posted: Sat May 26, 2007 10:41 pm
by steffl
judebert wrote:The exclamation point is invalid in URLs. I don't know if we escape it for categories; I know we don't do anything with it for titles.
That can't really be the problem in my case. Because a) it worked before and b) other category names don't seem to work either.
Posted: Tue May 29, 2007 9:34 am
by garvinhicking
Hi steffl!
Then please check out my suggestions.
Regards,
Garvin
Posted: Sun Jun 17, 2007 9:33 pm
by microbender
i have the same problem:
http://www.microbender.com/categories/QuickMacros
this article belongs to QuickMacros
http://www.microbender.com/archives/Qui ... ovable.htm
when i try to edit a category all fields are filled with a "<".
i made something with custom urls ...
i use serendipity-1.2-beta2.
Posted: Mon Jun 18, 2007 2:18 pm
by garvinhicking
Hi!
Seems you changed your categories now to use %id% again?
Anyways, it seems that something is wrong with the lookup of the categories. You'll need to do some investigation for me.
Please edit your index.php file. Search for this piece of code:
Code: Select all
} else if ($is_multicat || preg_match(PAT_PERMALINK_CATEGORIES, $uri, $matches)) {
replace it with:
Code: Select all
} else if ($is_multicat || preg_match(PAT_PERMALINK_CATEGORIES, $uri, $matches)) {
die('CATEGORY LOOKUP: ' . PAT_PERMALINK_CATEGORIES . ' // ' . $uri . ' // ' . print_r($matches, true));
Then call the URL of your categories page (like
http://www.microbender.com/categories/3_Tools). There you should get a debug output, please tell me what that looks like.
Also please checkout your DB table 'Serendipity_permalinks' and see what permalinks are contained there for your 'categories'. Maybe this custom lookup is failing:
Code: Select all
if (!$is_multicat) {
$matches[1] = serendipity_searchPermalink($serendipity['permalinkCategoryStructure'], implode('/', $_args), $matches[1],
$serendipity['GET']['category'] = $matches[1];
}
you could also modify that portion with:
Code: Select all
if (!$is_multicat) {
$matches[1] = serendipity_searchPermalink($serendipity['permalinkCategoryStructure'], implode('/', $_args), $matches[1],
die('Searching permalink for ' . $serendipity['permalinkCategoryStructure'] . ' // ' . print_r(implode('/', $_args), true) . ' // ' . print_r($matches, true));
$serendipity['GET']['category'] = $matches[1];
}
Then you'd get also some debug output (remember to remove the first debug string, or you won't ever reach that second point).
when i try to edit a category all fields are filled with a "<".
What exactly? Where? Make a screenshot please?
Regards,
Garvin
Posted: Tue Jun 19, 2007 1:56 pm
by microbender
1.
CATEGORY LOOKUP: @categories/([0-9;]+)_[0-9a-z\.\_!;,\+\-\%]+@i // /categories/3_Tools // Array ( [0] => categories/3_Tools [1] => 3 )
2.
the db entries are correct.
categories/3_Tools
3.
no debug output ?
4.

Posted: Tue Jun 19, 2007 2:08 pm
by garvinhicking
Hi!
Ah! I think we've had this before. When you upgraded your serendipity, did you properly perform the DB updates?
The 'hide_sub' colum should be present in the serendipity_categories table. If it's missing, please re-execute the update properly (see FAQ).
HTH,
Garvin
Posted: Tue Jun 19, 2007 3:07 pm
by microbender
yikes

i set back $serendipity['versionInstalled'] to 1.1 and upgraded again.
now it works.
thanks!