summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorMax Kremmel <xing@synapse.plus.com>2007-03-17 11:45:36 +0000
committerMax Kremmel <xing@synapse.plus.com>2007-03-17 11:45:36 +0000
commit59cc7aad4a5e4b45e56c399bdc10c728fdea34bd (patch)
tree9caa4c5ec37212c4bd7593bad9a4312f85139a8b /templates
parent4382eb944f31237387b8ec1719188475e1e00653 (diff)
downloadlanguages-59cc7aad4a5e4b45e56c399bdc10c728fdea34bd.tar.gz
languages-59cc7aad4a5e4b45e56c399bdc10c728fdea34bd.tar.bz2
languages-59cc7aad4a5e4b45e56c399bdc10c728fdea34bd.zip
some work on content translations - basics are working now. need to clean up included translation template in edit page.
Diffstat (limited to 'templates')
-rw-r--r--templates/i18n_service_icons.tpl5
-rw-r--r--templates/select_translations.tpl34
2 files changed, 23 insertions, 16 deletions
diff --git a/templates/i18n_service_icons.tpl b/templates/i18n_service_icons.tpl
new file mode 100644
index 0000000..c3b241a
--- /dev/null
+++ b/templates/i18n_service_icons.tpl
@@ -0,0 +1,5 @@
+{strip}
+ {foreach from=$i18nTranslations item=trans}
+ <a href="{$smarty.const.BIT_ROOT_URL}index.php?content_id={$trans.content_id}">{biticon ipackage=languages iname="languages/`$trans.lang_code`" iexplain=$trans.full_name}</a>
+ {/foreach}
+{/strip}
diff --git a/templates/select_translations.tpl b/templates/select_translations.tpl
index 6c83006..869929d 100644
--- a/templates/select_translations.tpl
+++ b/templates/select_translations.tpl
@@ -1,17 +1,19 @@
{* don't show if this is the page creation *}
-<div class="row">
- {formlabel label="Translations" for="to_id"}
- {forminput}
- <input type="hidden" name="i18n[translation_id]" value="{$translationId}" />
- <input type="hidden" name="i18n[from_id]" value="{$smarty.request.i18n.from_id|default:$gContent->mContentId}" />
- <select name="i18n[to_id]" id="to_id">
- {foreach from=$translationsList key=langCode item=lang}
- <option value="{$lang.content_id|default:$langCode}">{$lang.native_name}: &nbsp; {$lang.title|escape|default:"&bull; {tr}Create New{/tr} &bull;"}</option>
- {/foreach}
- </select>
- &nbsp; <label><input type="checkbox" name="i18n[google]" /> {tr}Attempt Google translation{/tr}</label>
- <br />
- <input type="submit" name="i18n[translate]" value="{tr}Translate{/tr}" />
- {formhelp note="If you feel like translating this page into a different language, please select the correct language above and hit <strong>Translate</strong>."}
- {/forminput}
-</div>
+{if $gContent->mContentId}
+ <div class="row">
+ {formlabel label="Translations" for="to_id"}
+ {forminput}
+ <input type="hidden" name="i18n[translation_id]" value="{$translationId}" />
+ <input type="hidden" name="i18n[from_id]" value="{$smarty.request.i18n.from_id|default:$gContent->mContentId}" />
+ <select name="i18n[to_id]" id="to_id">
+ {foreach from=$translationsList key=langCode item=lang}
+ <option value="{$lang.content_id|default:$langCode}">{$lang.native_name}: &nbsp; {$lang.title|escape|default:"&bull; {tr}Create New{/tr} &bull;"}</option>
+ {/foreach}
+ </select>
+ &nbsp; <label><input type="checkbox" name="i18n[google]" /> {tr}Attempt Google translation{/tr}</label>
+ <br />
+ <input type="submit" name="i18n[translate]" value="{tr}Translate{/tr}" />
+ {formhelp note="If you feel like translating this page into a different language, please select the correct language above and hit <strong>Translate</strong>."}
+ {/forminput}
+ </div>
+{/if}