(bug 36537) Rename wfArrayToCGI to wfArrayToCgi
authorTimo Tijhof <ttijhof@wikimedia.org>
Sat, 5 May 2012 17:02:58 +0000 (19:02 +0200)
committerTimo Tijhof <ttijhof@wikimedia.org>
Sat, 5 May 2012 17:02:58 +0000 (19:02 +0200)
- For consistency with wfCgiToArray()
  This way instead of the other way around to keep lowerCamelCase natural.

Change-Id: If4528f6572afeab42ef0602a427ac44da9830a3f

RELEASE-NOTES-1.20
includes/GlobalFunctions.php

index c796df3..125d607 100644 (file)
@@ -98,6 +98,7 @@ upgrade PHP if you have not done so prior to upgrading MediaWiki.
 * (bug 31757) Add a word-separator between help-messages in HTMLForm
 * (bug 30410) Removed deprecated $wgFilterCallback and the 'filtered' API error.
 * (bug 32604) Some messages needs escaping of wikitext inside username
+* (bug 36537) Rename wfArrayToCGI to wfArrayToCgi for consistency with wfCgiToArray.
 
 === API changes in 1.20 ===
 * (bug 34316) Add ability to retrieve maximum upload size from MediaWiki API.
index 70865cb..cea7e48 100644 (file)
@@ -368,7 +368,7 @@ function wfUrlencode( $s ) {
  * @param $prefix String
  * @return String
  */
-function wfArrayToCGI( $array1, $array2 = null, $prefix = '' ) {
+function wfArrayToCgi( $array1, $array2 = null, $prefix = '' ) {
        if ( !is_null( $array2 ) ) {
                $array1 = $array1 + $array2;
        }
@@ -387,7 +387,7 @@ function wfArrayToCGI( $array1, $array2 = null, $prefix = '' ) {
                                foreach ( $value as $k => $v ) {
                                        $cgi .= $firstTime ? '' : '&';
                                        if ( is_array( $v ) ) {
-                                               $cgi .= wfArrayToCGI( $v, null, $key . "[$k]" );
+                                               $cgi .= wfArrayToCgi( $v, null, $key . "[$k]" );
                                        } else {
                                                $cgi .= urlencode( $key . "[$k]" ) . '=' . urlencode( $v );
                                        }
@@ -405,7 +405,7 @@ function wfArrayToCGI( $array1, $array2 = null, $prefix = '' ) {
 }
 
 /**
- * This is the logical opposite of wfArrayToCGI(): it accepts a query string as
+ * This is the logical opposite of wfArrayToCgi(): it accepts a query string as
  * its argument and returns the same string in array form.  This allows compa-
  * tibility with legacy functions that accept raw query strings instead of nice
  * arrays.  Of course, keys and values are urldecode()d.
@@ -462,7 +462,7 @@ function wfCgiToArray( $query ) {
  */
 function wfAppendQuery( $url, $query ) {
        if ( is_array( $query ) ) {
-               $query = wfArrayToCGI( $query );
+               $query = wfArrayToCgi( $query );
        }
        if( $query != '' ) {
                if( false === strpos( $url, '?' ) ) {