Author: surye80
Description:
When I put a URL like [http://example.com link] in a template, I get PHP error messages:
Warning: in_array() [function.in-array]: Wrong datatype for second argument in /var/www/html/w/includes/GlobalFunctions.php on line 1964
Warning: in_array() [function.in-array]: Wrong datatype for second argument in /var/www/html/w/includes/GlobalFunctions.php on line 1966
The lines are as follows:
1964 if ( in_array( $bits['scheme'] . '://' , $wgUrlProtocols ) ) {
1965 $delimiter = '://';
1966 } elseif ( in_array( $bits['scheme'] .':' , $wgUrlProtocols ) ) {
I believe the issue is that $wgUrlProtocols is a string, containing a regex, and not an array, which in_array() requires. I checked svn, though I had a hard time navagating trunk, and assumed phase3 is the correct folder to check? If so, this is still the case in svn.
Version: unspecified
Severity: enhancement