summaryrefslogtreecommitdiffstats
path: root/custom/views/default
diff options
context:
space:
mode:
authorPascal Chevrel <pascal@chevrel.org>2012-03-12 15:40:15 +0100
committerPascal Chevrel <pascal@chevrel.org>2012-03-12 15:40:15 +0100
commit5378cf37d8d3dde29a2e7a67e94f3966696288e6 (patch)
treed2beff7282a5e5e2ddcd870113117944587084a7 /custom/views/default
parente6ab308bbdb024fe8f65f6e6419482d94dc54eab (diff)
downloadplanet-5378cf37d8d3dde29a2e7a67e94f3966696288e6.tar
planet-5378cf37d8d3dde29a2e7a67e94f3966696288e6.tar.gz
planet-5378cf37d8d3dde29a2e7a67e94f3966696288e6.tar.bz2
planet-5378cf37d8d3dde29a2e7a67e94f3966696288e6.tar.xz
planet-5378cf37d8d3dde29a2e7a67e94f3966696288e6.zip
l10n support for moonmoon
Diffstat (limited to 'custom/views/default')
-rwxr-xr-x[-rw-r--r--]custom/views/default/footer.tpl.php4
-rwxr-xr-x[-rw-r--r--]custom/views/default/index.tpl.php20
-rwxr-xr-x[-rw-r--r--]custom/views/default/sidebar.tpl.php20
3 files changed, 22 insertions, 22 deletions
diff --git a/custom/views/default/footer.tpl.php b/custom/views/default/footer.tpl.php
index 5b27882..bfc0210 100644..100755
--- a/custom/views/default/footer.tpl.php
+++ b/custom/views/default/footer.tpl.php
@@ -1,3 +1,3 @@
<div id="footer">
- <p>Powered by <a href="http://moonmoon.org/">moonmoon</a> | <a href="./admin/">Administration</a></p>
- </div> \ No newline at end of file
+ <p><? echo str_replace('%s', 'href="http://moonmoon.org"', _g('Powered by <a %s>moonmoon</a>'))?> | <a href="./admin/"><?=_g('Administration')?></a></p>
+ </div>
diff --git a/custom/views/default/index.tpl.php b/custom/views/default/index.tpl.php
index 9efc5f7..8153f2f 100644..100755
--- a/custom/views/default/index.tpl.php
+++ b/custom/views/default/index.tpl.php
@@ -5,7 +5,7 @@ $count = 0;
header('Content-type: text/html; charset=UTF-8');
?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?=$conf['locale']?>" lang="<?=$conf['locale']?>">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta http-equiv="Content-Script-Type" content="text/javascript" />
@@ -21,7 +21,7 @@ header('Content-type: text/html; charset=UTF-8');
</script>
<div id="page">
<?php include(dirname(__FILE__).'/top.tpl.php'); ?>
-
+
<div id="content">
<?php if (0 == count($items)) : ?>
<div class="article">
@@ -32,7 +32,7 @@ header('Content-type: text/html; charset=UTF-8');
</div>
<?php else : ?>
<?php foreach ($items as $item): ?>
- <?php
+ <?php
$arParsedUrl = parse_url($item->get_feed()->getWebsite());
$host = 'from-' . preg_replace('/[^a-zA-Z0-9]/i', '-', $arParsedUrl['host']);
?>
@@ -41,17 +41,17 @@ header('Content-type: text/html; charset=UTF-8');
<a href="<?php echo $item->get_permalink(); ?>" title="Go to original place"><?php echo $item->get_title(); ?></a>
</h2>
<p class="article-info">
-
+
<?php echo ($item->get_author()? $item->get_author()->get_name() : 'Anonymous'); ?>,
- <?php
+ <?php
$ago = time() - $item->get_date('U');
//echo '<span title="'.Duration::toString($ago).' ago" class="date">'.date('d/m/Y', $item->get_date('U')).'</span>';
echo '<span id="post'.$item->get_date('U').'" class="date">'.$item->get_date('d/m/Y').'</span>';
?>
-
+
|
-
- Source: <?php
+
+ <?=_g('Source:')?> <?php
$feed = $item->get_feed();
echo '<a href="'.$feed->getWebsite().'" class="source">'.$feed->getName().'</a>';
?>
@@ -64,9 +64,9 @@ header('Content-type: text/html; charset=UTF-8');
<?php endforeach; ?>
<?php endif; ?>
</div>
-
+
<?php include_once(dirname(__FILE__).'/sidebar.tpl.php'); ?>
-
+
<?php include(dirname(__FILE__).'/footer.tpl.php'); ?>
</div>
</body>
diff --git a/custom/views/default/sidebar.tpl.php b/custom/views/default/sidebar.tpl.php
index 9e7631c..2a3a360 100644..100755
--- a/custom/views/default/sidebar.tpl.php
+++ b/custom/views/default/sidebar.tpl.php
@@ -4,31 +4,31 @@ usort($all_people, array('PlanetFeed', 'compare'));
?>
<div id="sidebar" class="aside">
<div id="sidebar-people" class="section">
- <h2>People (<?php echo count($all_people); ?>)</h2>
+ <h2><?php echo _g('People') . ' (' . count($all_people) . ')'?></h2>
<ul>
<?php foreach ($all_people as $person) : ?>
<li>
- <a href="<?php echo htmlspecialchars($person->getFeed(), ENT_QUOTES, 'UTF-8'); ?>" title="Feed"><img src="postload.php?url=<?php echo urlencode(htmlspecialchars($person->getFeed(), ENT_QUOTES, 'UTF-8')); ?>" alt="" height="12" width="12" /></a>
- <a href="<?php echo $person->getWebsite(); ?>" title="Website"><?php echo htmlspecialchars($person->getName(), ENT_QUOTES, 'UTF-8'); ?></a>
+ <a href="<?php echo htmlspecialchars($person->getFeed(), ENT_QUOTES, 'UTF-8'); ?>" title="<?=_g('Feed')?>"><img src="postload.php?url=<?php echo urlencode(htmlspecialchars($person->getFeed(), ENT_QUOTES, 'UTF-8')); ?>" alt="" height="12" width="12" /></a>
+ <a href="<?php echo $person->getWebsite(); ?>" title="<?=_g('Website')?>"><?php echo htmlspecialchars($person->getName(), ENT_QUOTES, 'UTF-8'); ?></a>
</li>
<?php endforeach; ?>
</ul>
<p>
- <img src="custom/img/opml.png" alt="feed" height="12" width="12" /> <a href="custom/people.opml">All feeds in OPML format</a>
+ <img src="custom/img/opml.png" alt="<?=_g('Feed')?>" height="12" width="12" /> <a href="custom/people.opml"><?=_g('All feeds in OPML format')?></a>
</p>
</div>
-
+
<div class="section">
- <h2>Syndicate</h2>
+ <h2><?=_g('Syndicate')?></h2>
<ul>
- <li><img src="custom/img/feed.png" alt="feed" height="12" width="12" />&nbsp;<a href="?type=atom10">Feed (ATOM)</a></li>
+ <li><img src="custom/img/feed.png" alt="<?=_g('Feed')?>" height="12" width="12" />&nbsp;<a href="?type=atom10"><?=_g('Feed (ATOM)')?></a></li>
</ul>
</div>
<div class="section">
- <h2>Archives</h2>
+ <h2><?=_g('Archives')?></h2>
<ul>
- <li><a href="?type=archive">See all headlines</a></li>
+ <li><a href="?type=archive"><?=_g('See all headlines')?></a></li>
</ul>
</div>
-</div> \ No newline at end of file
+</div>