An entry I wrote was alright. Then I edited it, i added an alt-tag to the image. After the edit, the entry is still visible on the frontpage, but "can't be found" when trying to view the entry directly.
Frontpage, entry.
I have no idea how to debug this as i never saw anything like that happen with s9y before. An id-mixup in the database caused by the edit? Wrong permalinks caused by the edit, a new one created but the old one still linked?
Entry disappeared after editing
Re: Entry disappeared after editing
Ich schätze mal das liegt daran, dass dein Titel mit einer Zahl anfängt...., denn
http://www.onli-blogging.de/index.php?/ ... l#comments
funktioniert. Wer da allerdings dazwischenfunkt, kann wohl am ehesten Garvin herausfinden
Ian
oops sorry für deutsch----
http://www.onli-blogging.de/index.php?/ ... l#comments
funktioniert. Wer da allerdings dazwischenfunkt, kann wohl am ehesten Garvin herausfinden
Ian
oops sorry für deutsch----
Re: Entry disappeared after editing
Danke. Darauf wär ich nie gekommen.
It seems like not the edit is responsible but the number in the title is.
It seems like not the edit is responsible but the number in the title is.
-
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: Entry disappeared after editing
Hi!
You are missing a distinct entry URL "archives path" prefix like "entries". Since you don't have it, the URL pattern matches your URL as a ID of another entry...
Regards,
Garvin
You are missing a distinct entry URL "archives path" prefix like "entries". Since you don't have it, the URL pattern matches your URL as a ID of another entry...
Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Re: Entry disappeared after editing
Hi Garvin
I dont properly understand why. The id of the entry has its own place in the url, shouldn't that be discoverable (as the URL-Pattern is known)?
"Pfad zu den Einträgen" is set to archives. I added archives to the front of the url, so it looked like http://www.onli-blogging.de/index.php?/ ... esden.html. But that didn't solve the issue and also breaks all old link (http://www.onli-blogging.de/index.php?/ ... laert.html != http://www.onli-blogging.de/index.php?/ ... laert.html) - so that's no solution.
The archives-keyword needs another place in the url and the forwarding via .htaccess needs to be done manually?
Edit: Taking my permalink-structure into my testblog. In the index.php is the following pattern:
which is compared to the url via:
Taking for example:
matches [0] becomes:
and matches[1]:
Why 100? The regexp isn't selecting the numbers before the -, it is selecting the numbers before the /. Or it is selecting the whole link, depends on what counts as first bracket. I think something is wrong here.
Edit2: Got it. It's the wrong pattern. PAT_COMMENTSUB is the one which gets true before.
Hm, maybe i can change that...
Edit 3:
If i simply change the order of the if, execute the match against PAT_PERMALINK first, everything seems to work (line 254/255 in index.php). Is there maybe a way to make that less errorprone generally? Probably adding archives/ like it used to be didn't work because even than, preg_match with PAT_COMMENTSUB returned true.
So that's really a bug - is changing the order a proper patch?
I dont properly understand why. The id of the entry has its own place in the url, shouldn't that be discoverable (as the URL-Pattern is known)?
"Pfad zu den Einträgen" is set to archives. I added archives to the front of the url, so it looked like http://www.onli-blogging.de/index.php?/ ... esden.html. But that didn't solve the issue and also breaks all old link (http://www.onli-blogging.de/index.php?/ ... laert.html != http://www.onli-blogging.de/index.php?/ ... laert.html) - so that's no solution.
The archives-keyword needs another place in the url and the forwarding via .htaccess needs to be done manually?
Edit: Taking my permalink-structure into my testblog. In the index.php is the following pattern:
Code: Select all
@(([0-9]+)/[0-9a-z\.\_!;,\+\-\%]+\.html)/?@i
Code: Select all
preg_match(PAT_PERMALINK, $uri, $matches)
Code: Select all
/index.php?/4/100-testeintrag.html
Code: Select all
/100-testeintrag.html
Code: Select all
100
Edit2: Got it. It's the wrong pattern. PAT_COMMENTSUB is the one which gets true before.
Code: Select all
@/([0-9]+)[_\-][0-9a-z\.\_!;,\+\-\%]*\.html@i
Edit 3:
If i simply change the order of the if, execute the match against PAT_PERMALINK first, everything seems to work (line 254/255 in index.php). Is there maybe a way to make that less errorprone generally? Probably adding archives/ like it used to be didn't work because even than, preg_match with PAT_COMMENTSUB returned true.
So that's really a bug - is changing the order a proper patch?
-
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: Entry disappeared after editing
Hi!
Hm, I thought we already had means in place that would catch the permalink archives pattern before commentsub takes place. Sadly I'm currently lacking the time to investigate this thoroughly - maybe you can remind me of it next week?
Regards,
Garvin
Hm, I thought we already had means in place that would catch the permalink archives pattern before commentsub takes place. Sadly I'm currently lacking the time to investigate this thoroughly - maybe you can remind me of it next week?
Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Re: Entry disappeared after editing
*remind* ;)
Re: Entry disappeared after editing
Hi
I just stumbled over this bug again, http://www.onli-blogging.de/index.php?/ ... ssung.html vanished. Totally forgot my patch after the last s9y-update. Can we fix this in core?
I just stumbled over this bug again, http://www.onli-blogging.de/index.php?/ ... ssung.html vanished. Totally forgot my patch after the last s9y-update. Can we fix this in core?
Re: Entry disappeared after editing
Hi Malte
You have GIT access haven't you?
If not, tell me what to change.
You have GIT access haven't you?
If not, tell me what to change.
Regards,
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Re: Entry disappeared after editing
Code: Select all
diff -Nur Downloads/index-1.6.php Downloads/index.php
--- Downloads/index-1.6.php 2011-12-10 15:16:39.425894289 +0100
+++ Downloads/index.php 2011-12-10 13:25:57.505896370 +0100
@@ -251,8 +251,8 @@
}
echo $data;
-} else if ( (preg_match(PAT_COMMENTSUB, $uri, $matches) ||
- preg_match(PAT_PERMALINK, $uri, $matches) ||
+} else if ( (preg_match(PAT_PERMALINK, $uri, $matches) ||
+ preg_match(PAT_COMMENTSUB, $uri, $matches) ||
isset($serendipity['GET']['id']) ||
isset($_GET['p']))
&& !preg_match('/autosave/', $serendipity['uriArguments'][1]) ) {
-
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: Entry disappeared after editing
Hi!
Please go ahead and commit, I think this should work
Regards,
Garvin
Please go ahead and commit, I think this should work
Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/