Index: trunk/phase3/languages/Language.php |
— | — | @@ -759,9 +759,12 @@ |
760 | 760 | $data = explode( '|', $tz, 3 ); |
761 | 761 | |
762 | 762 | if ( $data[0] == 'ZoneInfo' ) { |
763 | | - if ( function_exists( 'timezone_open' ) && @timezone_open( $data[2] ) !== false ) { |
| 763 | + wfSuppressWarnings(); |
| 764 | + $userTZ = timezone_open( $data[2] ); |
| 765 | + wfRestoreWarnings(); |
| 766 | + if ( $userTZ !== false ) { |
764 | 767 | $date = date_create( $ts, timezone_open( 'UTC' ) ); |
765 | | - date_timezone_set( $date, timezone_open( $data[2] ) ); |
| 768 | + date_timezone_set( $date, $userTZ ); |
766 | 769 | $date = date_format( $date, 'YmdHis' ); |
767 | 770 | return $date; |
768 | 771 | } |