note 61134 deleted from function.http-build-query by nlopess

From: Date: Sat, 12 Aug 2006 18:21:52 +0000
Subject: note 61134 deleted from function.http-build-query by nlopess
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-115841@lists.php.net to get a copy of this message
Note Submitter: xangelusx at hotmail dot com ---- @ arjini: It is actually illegal to set arg_separator.output to &amp; ("and amp ;") as every character is considered a seperator according to the documentation. Hosts should only be using the single "&" (andpersand) character. @ vlad: Good call checking the servers arg_separator.output setting, but note that it can contain several characters (see the default setting in php.ini). Instead, try this: <?php //Discover the servers preferred parameter delimiters. If empty, assume "&" $Delims = ((ini_get("arg_separator.input") == "") ? "&" : ini_get("arg_separator.input")); if (strlen($Delims) > 1) { $Delims = preg_split('//', $Delims, -1, PREG_SPLIT_NO_EMPTY); } else { $Delims = array($Delims); } $separator = $Delims[0]; ?>

« previous php.notes (#115841) next »