Permalink
Browse files

upd localization

add translations for german
  • Loading branch information...
1 parent 2d32b3e commit ac76f411b30d1884e00682164d389491040f8f0f @acetous committed Apr 5, 2012
View
3 apps/backend/config/filters.yml
@@ -2,6 +2,9 @@
# http://www.symfony-project.org/reference/1_4/en/12-Filters
rendering: ~
+locale:
+ class: BlogLocaleFilter
+
security: ~
language:
View
96 apps/backend/i18n/de/messages.xml
@@ -60,6 +60,102 @@
<source>Make it public?</source>
<target>Veröffentlichen?</target>
</trans-unit>
+ <trans-unit id="15">
+ <source>Dashboard</source>
+ <target>Übersicht</target>
+ </trans-unit>
+ <trans-unit id="16">
+ <source>Last Posts</source>
+ <target>Letzte Beiträge</target>
+ </trans-unit>
+ <trans-unit id="17">
+ <source>Date</source>
+ <target>Datum</target>
+ </trans-unit>
+ <trans-unit id="18">
+ <source>Title</source>
+ <target>Titel</target>
+ </trans-unit>
+ <trans-unit id="19">
+ <source>Actions</source>
+ <target>Aktionen</target>
+ </trans-unit>
+ <trans-unit id="20">
+ <source>New Comments</source>
+ <target>Neue Kommentare</target>
+ </trans-unit>
+ <trans-unit id="21">
+ <source>New Spam</source>
+ <target>Neuer Spam</target>
+ </trans-unit>
+ <trans-unit id="22">
+ <source>No new spam.</source>
+ <target>Kein neuer Spam.</target>
+ </trans-unit>
+ <trans-unit id="23">
+ <source>You're lucky!</source>
+ <target>Du Glückspilz!</target>
+ </trans-unit>
+ <trans-unit id="24">
+ <source>But there are %s comments marked as spam in total.</source>
+ <target>Es sind jedoch insgesamt %s Kommentare als Spam markiert.</target>
+ </trans-unit>
+ <trans-unit id="25">
+ <source>Write new</source>
+ <target>Erstellen</target>
+ </trans-unit>
+ <trans-unit id="26">
+ <source>Last Comments</source>
+ <target>Letzte Kommentare</target>
+ </trans-unit>
+ <trans-unit id="27">
+ <source>Source</source>
+ <target>Quelltext</target>
+ </trans-unit>
+ <trans-unit id="28">
+ <source>Files</source>
+ <target>Dateien</target>
+ </trans-unit>
+ <trans-unit id="29">
+ <source>Content</source>
+ <target>Inhalt</target>
+ </trans-unit>
+ <trans-unit id="30">
+ <source>Options</source>
+ <target>Optionen</target>
+ </trans-unit>
+ <trans-unit id="31">
+ <source>Display the post small.</source>
+ <target>Schmal anzeigen.</target>
+ </trans-unit>
+ <trans-unit id="32">
+ <source>Publish the post.</source>
+ <target>Veröffentlichen.</target>
+ </trans-unit>
+ <trans-unit id="33">
+ <source>Use markdown to render the post. Pure HTML otherwise.</source>
+ <target>Mit Markdown rendern. Ansonsten HTML.</target>
+ </trans-unit>
+ <trans-unit id="34">
+ <source>Abort</source>
+ <target>Abbrechen</target>
+ </trans-unit>
+ <trans-unit id="35">
+ <source>Current Spam</source>
+ <target>Aktueller Spam</target>
+ </trans-unit>
+ <trans-unit id="36">
+ <source>Hooray! No spam!</source>
+ <target>Hurra! Kein Spam!</target>
+ </trans-unit>
+ <trans-unit id="37">
+ <source>Delete all spam</source>
+ <target>Allen Spam löschen</target>
+ </trans-unit>
+ <trans-unit id="38">
+ <source>Search</source>
+ <target>Suche</target>
+ </trans-unit>
</body>
</file>
</xliff>
View
3 apps/frontend/config/filters.yml
@@ -2,6 +2,9 @@
# http://www.symfony-project.org/reference/1_4/en/12-Filters
rendering: ~
+locale:
+ class: BlogLocaleFilter
+
security: ~
language:
View
32 apps/frontend/i18n/de/messages.xml
@@ -116,6 +116,38 @@
<source>Cancel</source>
<target>Abbruch</target>
</trans-unit>
+ <trans-unit id="30">
+ <source>Archive</source>
+ <target>Archiv</target>
+ </trans-unit>
+ <trans-unit id="31">
+ <source>No comments yet.</source>
+ <target>Keine Kommentare</target>
+ </trans-unit>
+ <trans-unit id="32">
+ <source>It seemes no posts match your criteria. Reasons may be</source>
+ <target>Es scheint als würden keine Posts zu deiner Auswahl passen. Gründe dafür könnten sein:</target>
+ </trans-unit>
+ <trans-unit id="33">
+ <source>You have selected an archive with no posts. I promise to write more in the future!</source>
+ <target>Du hast ein Archiv ohne Inhalte ausgewählt. Ich verspreche, mehr zu schreiben!</target>
+ </trans-unit>
+ <trans-unit id="34">
+ <source>There are no posts matching your search criteria. Just ask me to write about the topic you are such curious about!</source>
+ <target>Keine Posts treffen auf deine Suchanfrage zu. Sag mir einfach, worüber ich schreiben soll!</target>
+ </trans-unit>
+ <trans-unit id="35">
+ <source>Return to index</source>
+ <target>Zurück zur Startseite</target>
+ </trans-unit>
+ <trans-unit id="36">
+ <source>Your Search for</source>
+ <target>Deine Suche nach</target>
+ </trans-unit>
+ <trans-unit id="37">
+ <source>results</source>
+ <target>Ergebnisse</target>
+ </trans-unit>
</body>
</file>
</xliff>
View
4 config/app.yml.example
@@ -9,7 +9,9 @@ all:
view:
theme: modern
language: en # available: en, de
- locale: de_DE.utf8 # a locale your system can deal with; delete if not sure
+ locale: en_US.utf8 # a locale your system can deal with; *delete this config value if not sure*
+ # examples: en_US.utf8, en_GB.utf8, de_DE.utf8
+ # more information: http://php.net/manual/de/function.setlocale.php
homepage:
post_count: 10
micropost_count: 10
View
1 lib/filter/BlogLanguageFilter.class.php
@@ -6,6 +6,7 @@ public function execute($filterChain)
{
if ($this->isFirstCall())
{
+ // set culture
$this->getContext()->getUser()->setCulture(
sfConfig::get('app_view_language')
);
View
15 lib/filter/BlogLocaleFilter.class.php
@@ -0,0 +1,15 @@
+<?php
+
+class BlogLocaleFilter extends sfFilter
+{
+ public function execute($filterChain)
+ {
+ if ($this->isFirstCall())
+ {
+ // set locale for PHP
+ setlocale(LC_ALL, sfConfig::get('app_view_locale', null));
+ }
+
+ $filterChain->execute();
+ }
+}
View
2 lib/form/doctrine/BlogPostForm.class.php
@@ -16,7 +16,7 @@ public function configure()
$this->widgetSchema->setLabel('title', 'Title');
$this->widgetSchema->setLabel('content', 'Content');
- $this->widgetSchema->setHelp('content', 'You can use HTML and <a href="http://daringfireball.net/projects/markdown/syntax" target="_blank">Markdown Syntax</a>.');
+ $this->widgetSchema->setHelp('content', 'HTML / <a href="http://daringfireball.net/projects/markdown/syntax" target="_blank">Markdown</a>.');
$this->widgetSchema->setLabel('micropost', 'Display the post small.');
$this->widgetSchema->setLabel('published', 'Publish the post.');
$this->widgetSchema->setLabel('markdown', 'Use markdown to render the post. Pure HTML otherwise.');
View
2 themes/modern/backend/post/dboardSuccess.php
@@ -35,7 +35,7 @@
<h2><?php echo __('New Spam'); ?></h2>
<?php if (sizeof($spam) == 0) : ?>
<div class="alert alert-info">
- <p><strong><?php echo __('No new spam.'); ?></strong> <?php echo __('You\'re lucky!'); ?></p>
+ <p><strong><?php echo __('No new spam.'); ?></strong> <?php echo __("You're lucky!"); ?></p>
<?php if ($totalSpam > 0) : ?>
<p><?php echo sprintf(__('But there are %s comments marked as spam in total.'), '<strong>'.$totalSpam.'</strong>'); ?></p>
<?php endif; ?>

0 comments on commit ac76f41

Please sign in to comment.