Index: trunk/phase3/includes/GlobalFunctions.php |
— | — | @@ -1230,18 +1230,18 @@ |
1231 | 1231 | if ( '' != $cgi ) { |
1232 | 1232 | $cgi .= '&'; |
1233 | 1233 | } |
1234 | | - if(is_array($value)) |
1235 | | - { |
| 1234 | + if ( is_array( $value ) ) { |
1236 | 1235 | $firstTime = true; |
1237 | | - foreach($value as $v) |
1238 | | - { |
1239 | | - $cgi .= ($firstTime ? '' : '&') . |
| 1236 | + foreach ( $value as $v ) { |
| 1237 | + $cgi .= ( $firstTime ? '' : '&') . |
1240 | 1238 | urlencode( $key . '[]' ) . '=' . |
1241 | 1239 | urlencode( $v ); |
1242 | 1240 | $firstTime = false; |
1243 | 1241 | } |
1244 | | - } |
1245 | | - else |
| 1242 | + } else { |
| 1243 | + if ( is_object( $value ) ) { |
| 1244 | + $value = $value->__toString(); |
| 1245 | + } |
1246 | 1246 | $cgi .= urlencode( $key ) . '=' . |
1247 | 1247 | urlencode( $value ); |
1248 | 1248 | } |