Index: trunk/extensions/GoogleMaps/GoogleMaps.php |
— | — | @@ -27,10 +27,20 @@ |
28 | 28 | require( "$IP/extensions/GoogleMaps/GoogleMaps.body.php" ); |
29 | 29 | |
30 | 30 | function wfGoogleMaps_CommentJS(&$pParser, &$pText) { |
31 | | - global $wgGoogleMaps; |
32 | | - return $wgGoogleMaps->commentJS($pParser, $pText); |
| 31 | + global $wgGoogleMaps; |
| 32 | + return $wgGoogleMaps->commentJS($pParser, $pText); |
33 | 33 | } |
34 | 34 | |
| 35 | +$wgGoogleMapsKey = null; |
| 36 | +$wgGoogleMapsKeys = array( ); |
| 37 | +$wgGoogleMapsDisableEditorsMap = false; |
| 38 | +$wgGoogleMapsEnablePaths = false; |
| 39 | +$wgGoogleMapsDefaults = null; |
| 40 | +$wgGoogleMapsCustomMessages = null; |
| 41 | +$wgGoogleMapsUrlPath = "{$wgScriptPath}/extensions/GoogleMaps"; |
| 42 | +$wgXhtmlNamespaces = null; |
| 43 | +$wgGoogleMapsTemplateVariables = false; |
| 44 | + |
35 | 45 | /** |
36 | 46 | * This function registers all of the MW hook functions necessary for the |
37 | 47 | * map extension to function. These hooks are added using the array_unshift |
— | — | @@ -46,33 +56,6 @@ |
47 | 57 | $wgTitle; |
48 | 58 | // set up some default values for the various extension configuration parameters |
49 | 59 | // to keep from getting PHP notices if running in strict mode |
50 | | - if( !isset( $wgGoogleMapsKey ) ) { |
51 | | - $wgGoogleMapsKey = null; |
52 | | - } |
53 | | - if( !isset( $wgGoogleMapsKeys ) ) { |
54 | | - $wgGoogleMapsKeys = array( ); |
55 | | - } |
56 | | - if( !isset( $wgGoogleMapsDisableEditorsMap ) ) { |
57 | | - $wgGoogleMapsDisableEditorsMap = false; |
58 | | - } |
59 | | - if( !isset( $wgGoogleMapsEnablePaths ) ) { |
60 | | - $wgGoogleMapsEnablePaths = false; |
61 | | - } |
62 | | - if( !isset( $wgGoogleMapsDefaults ) ) { |
63 | | - $wgGoogleMapsDefaults = null; |
64 | | - } |
65 | | - if( !isset( $wgGoogleMapsCustomMessages ) ) { |
66 | | - $wgGoogleMapsCustomMessages = null; |
67 | | - } |
68 | | - if( !isset( $wgGoogleMapsUrlPath ) ) { |
69 | | - $wgGoogleMapsUrlPath = "{$wgScriptPath}/extensions/GoogleMaps"; |
70 | | - } |
71 | | - if( !isset( $wgXhtmlNamespaces ) ) { |
72 | | - $wgXhtmlNamespaces = null; |
73 | | - } |
74 | | - if( !isset( $wgGoogleMapsTemplateVariables ) ) { |
75 | | - $wgGoogleMapsTemplateVariables = false; |
76 | | - } |
77 | 60 | |
78 | 61 | // make poly-lines work with IE in MW 1.9+. See MW bug #7667 |
79 | 62 | if( is_array( $wgXhtmlNamespaces ) ) { |