Re: [Phplib-users] Patch to page.inc
Brought to you by:
nhruby,
richardarcher
|
From: Marko K. <M.K...@os...> - 2002-10-31 09:33:52
|
Hi, the following removes even doubled ampersands following the parameter
test and wipes it and its value away, leaving the rest of the string
untouched:
---snip---
***script start***
<?php
$a='url?test=testen&&test2=test2en&';
echo "Rewrote:".ereg_replace("([?&])test=[^&]*&*", "\\1",$a)."\n";
?>
***script end***
***script output start***
X-Powered-By: PHP/4.1.1
Content-type: text/html
Rewrote:url?test2=test2en&
***script output end***
---snip---
Marko
|