From: Leandro Lucarella Date: Sat, 7 May 2005 21:21:54 +0000 (+0000) Subject: Bugfix. X-Git-Tag: svn_import~44 X-Git-Url: https://git.llucax.com/z.facultad/75.43/tp1.git/commitdiff_plain/2addcbe28c9280d03a27aba88b7b81284ce8d32c?hp=f43126a41bd2f656a6c53f4a92dc00f231b7dacb Bugfix. --- diff --git a/src/lib/listador.php b/src/lib/listador.php index 06cf54f..50b41d6 100644 --- a/src/lib/listador.php +++ b/src/lib/listador.php @@ -54,7 +54,11 @@ function listar($item, $link = '', $caption = null, $summary = null, $cant = 15) if ($pags == 1) return; // Si tengo una sóla página, para qué el paginador? // Arrastro query string, si corresponde $query = $_SERVER['QUERY_STRING']; - if ($pos = strpos($query, 'lista_from=')) $query = substr($query, 0,--$pos); + if (($pos = strpos($query, 'lista_from=')) !== false) + { + if ($pos) $query = substr($query, 0, --$pos); + else $query = ''; + } for ($i = 0; $i < $pags; ++$i) { $from = $i * $cant;