Fix regexp in functions_routing.incx.php
See #655. I don't understand the code either (I don't even see where this code path belongs to - do we have a facitlity to show comments "from ... to"?), but the current regexp is obviously wrong, and the one suggested by @hannob is obviously (syntactically) correct, so it should be no problem to change that. Fixes #655. Signed-off-by: Thomas Hochstein <thh@inter.net>
This commit is contained in:
@ -1,6 +1,8 @@
|
||||
Version 2.3.5-beta1 ()
|
||||
------------------------------------------------------------------------
|
||||
|
||||
* Fix: Regular expression in functions_routing.incx.php
|
||||
|
||||
* Fix: Truncate extension of media items to 5 chars (which ist the
|
||||
max length of the corresponding database field).
|
||||
Thanks to @mmitch!
|
||||
|
@ -78,7 +78,7 @@ function serveComments() {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (preg_match('@^(last|f|t|from|to)[\s_-]*([\d-/ ]+)$@', strtolower(urldecode($v)), $m)) {
|
||||
if (preg_match('@^(last|f|t|from|to)[\s_-]*([\d/ -]+)$@', strtolower(urldecode($v)), $m)) {
|
||||
if ($m[1] == 'last') {
|
||||
$usetime = time() - ($m[2]*86400);
|
||||
$serendipity['GET']['commentStartTime'] = $usetime;
|
||||
|
Reference in New Issue
Block a user