diff options
author | CiaranG <ciaran@ciarang.com> | 2009-03-21 14:24:19 +0000 |
---|---|---|
committer | Evan Prodromou <evan@controlyourself.ca> | 2009-03-25 12:24:22 -0400 |
commit | d92926f892d72b631ba7ec3447eb73caf9ff03bd (patch) | |
tree | b1f8ad2f0636ac79768d00f0cd8645279b4b3ed9 /extlib | |
parent | a148569705b252c334925160a7972c3da140e374 (diff) |
Fix to Net_URL_Mapper to make search pagination work. See Ticket #1333
Diffstat (limited to 'extlib')
-rw-r--r-- | extlib/Net/URL/Mapper/Path.php | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/extlib/Net/URL/Mapper/Path.php b/extlib/Net/URL/Mapper/Path.php index b541002c7..eb1c34a3f 100644 --- a/extlib/Net/URL/Mapper/Path.php +++ b/extlib/Net/URL/Mapper/Path.php @@ -241,7 +241,12 @@ class Net_URL_Mapper_Path } $path = '/'.trim(Net_URL::resolvePath($path), '/'); if (!empty($qstring)) { - $path .= '?'.http_build_query($qstring); + if (!strpos($path, '?')) { + $path .= '?'; + } else { + $path .= '&'; + } + $path .= http_build_query($qstring); } if (!empty($anchor)) { $path .= '#'.ltrim($anchor, '#'); @@ -427,4 +432,4 @@ class Net_URL_Mapper_Path } -?>
\ No newline at end of file +?> |