cvs: pearweb /public_html weeklynews.php
| From: | Alan Knowles | Date: | Fri, 12 Jul 2002 09:37:29 +0000 |
| Subject: | cvs: pearweb /public_html weeklynews.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-5074@lists.php.net to get a copy of this message | ||
alan_k Fri Jul 12 05:37:29 2002 EDT
Modified files:
/pearweb/public_html weeklynews.php
Log:
added french to the list of languages
Index: pearweb/public_html/weeklynews.php
diff -u pearweb/public_html/weeklynews.php:1.8 pearweb/public_html/weeklynews.php:1.9
--- pearweb/public_html/weeklynews.php:1.8 Wed Jul 10 03:38:21 2002
+++ pearweb/public_html/weeklynews.php Fri Jul 12 05:37:29 2002
@@ -15,7 +15,7 @@
+----------------------------------------------------------------------+
| Authors: Alan Knowles <alan@akbkhome.com>
|
+----------------------------------------------------------------------+
- $Id: weeklynews.php,v 1.8 2002/07/10 07:38:21 alan_k Exp $
+ $Id: weeklynews.php,v 1.9 2002/07/12 09:37:29 alan_k Exp $
*/
@@ -47,7 +47,7 @@
function show_languages($visitlang = "") {
$available_langs = array(
'en' => 'English',
- // 'fr' => 'French',
+ 'fr' => 'French',
'de' => 'German'
);
echo getText("View In"). ' :: ';
@@ -95,7 +95,7 @@
//echo "LOOL FOR $lang" . date("Ymd",$week);
if (@file_exists(dirname(__FILE__) .
"/../weeklynews/".date("Ymd",$week). ".{$lang}.html")) {
show_news($lang,date("Ymd",$week));
- return;
+ return TRUE;
}
}
@@ -188,7 +188,8 @@
// #TODO - can somebody fix this it just doesnt work on my test machine!
$lang_maps = array(
"en" => "en_US",
- "de" => "de"
+ "de" => "de",
+ "fr" => "fr"
);
$show_lang = $args[1];
$locale = $lang_maps[$args[1]];
@@ -221,7 +222,9 @@
if ($show_archives) {
show_news_menu();
} elseif ($show_latest) {
- show_latest($show_lang);
+ if (!show_latest($show_lang)) {
+ show_news_menu();
+ }
} else {
show_news($args[1],$args[2]);
}