Index: trunk/tools/web-scripts/missing.php |
— | — | @@ -61,7 +61,7 @@ |
62 | 62 | $base = 'secure.wikimedia.org/wikipedia/incubator/wiki/'; |
63 | 63 | if( isset( $_SERVER['PATH_INFO'] ) ) { |
64 | 64 | $page = implode( array_slice( $tmp, 3 ) ); # /wiki/Page (possibly /wiki/Page?foo=bar) |
65 | | - elseif( $_GET['title'] ) { |
| 65 | + } elseif( isset( $_GET['title'] ) && $_GET['title'] ) { |
66 | 66 | $page = $_GET['title']; # index.php?title=Page |
67 | 67 | } else { |
68 | 68 | $page = ''; # no known title, fallback to main page |
— | — | @@ -76,7 +76,7 @@ |
77 | 77 | $base = 'incubator.wikimedia.org/wiki/'; |
78 | 78 | if( isset( $_SERVER['PATH_INFO'] ) ) { |
79 | 79 | $page = preg_replace( '/^\/wiki\//', '', $url['path'] ); # /wiki/Page (possibly /wiki/Page?foo=bar) |
80 | | - elseif( $_GET['title'] ) { |
| 80 | + } elseif( isset( $_GET['title'] ) && $_GET['title'] ) { |
81 | 81 | $page = $_GET['title']; # index.php?title=Page |
82 | 82 | } else { |
83 | 83 | $page = ''; # no known title, fallback to main page |
— | — | @@ -92,7 +92,7 @@ |
93 | 93 | # Go to the page if specified (look out for slashes), otherwise go to |
94 | 94 | # the main page Wx/xyz?goto=mainpage (WikimediaIncubator extension takes care of that) |
95 | 95 | $location .= $page && $page !== '/' ? '/' . $page : |
96 | | - '?goto=mainpage' . ( $_GET['uselang'] ? '&uselang=' . urlencode( $_GET['uselang'] ) : '' ); |
| 96 | + '?goto=mainpage' . ( isset( $_GET['uselang'] ) ? '&uselang=' . urlencode( $_GET['uselang'] ) : '' ); |
97 | 97 | |
98 | 98 | $redir = false; |
99 | 99 | |
— | — | @@ -135,9 +135,9 @@ |
136 | 136 | ?><!DOCTYPE html> |
137 | 137 | <html lang="en" dir="ltr"> |
138 | 138 | <head> |
139 | | - <title>$escLanguage $escProject does not exist</title> |
| 139 | + <title><?php echo "$escLanguage $escProject"; ?> does not exist</title> |
140 | 140 | <meta charset="UTF-8" /> |
141 | | - <link rel="shortcut icon" href="$home/favicon.ico" /> |
| 141 | + <link rel="shortcut icon" href="<?php echo $home; ?>/favicon.ico" /> |
142 | 142 | <style type="text/css"> |
143 | 143 | /* <![CDATA[ */ |
144 | 144 | * { |
— | — | @@ -154,7 +154,7 @@ |
155 | 155 | } |
156 | 156 | |
157 | 157 | #page { |
158 | | - background: url('$logo') center left no-repeat; |
| 158 | + background: url('<?php echo $logo; ?>') center left no-repeat; |
159 | 159 | height: 300px; |
160 | 160 | left: 50%; |
161 | 161 | margin: -150px 0 0 -360px; |
— | — | @@ -191,11 +191,11 @@ |
192 | 192 | |
193 | 193 | <h1>This wiki does not exist</h1> |
194 | 194 | |
195 | | - <h2>Welcome to $escProject</h2> |
| 195 | + <h2>Welcome to <?php echo $escProject; ?></h2> |
196 | 196 | |
197 | | - <p>Unfortunately, $escProject in "$escLanguage" does not exist on its own domain yet, or it has been closed.</p> |
| 197 | + <p>Unfortunately, <?php echo $escProject; ?> in "<?php echo $escLanguage; ?>" does not exist on its own domain yet, or it has been closed.</p> |
198 | 198 | |
199 | | - <p>You may like to visit <a href="$home">$name</a> to start or improve <em>$escLanguage $escProject</em> there.</p> |
| 199 | + <p>You may like to visit <a href="<?php echo $home; ?>"><?php echo $name; ?></a> to start or improve <em><?php echo "$escLanguage $escProject"; ?></em> there.</p> |
200 | 200 | |
201 | 201 | <p>If you would like to request that this wiki be created, see the <a href="https://www.mediawiki.org//meta.wikimedia.org/wiki/Requests_for_new_languages">requests for new languages</a> page on Meta-Wiki.</p> |
202 | 202 | |