1 | <?php |
---|
2 | $seiten_id = 'no-translation'; // befindet sich nicht in navi |
---|
3 | $lang = 'en'; // force language |
---|
4 | $version = '$Id: no-translation.php 814 2015-07-04 18:51:19Z heribert $'; |
---|
5 | $titel = 'No English translation available'; |
---|
6 | $dynamischer_inhalt = true; |
---|
7 | |
---|
8 | // see usage below |
---|
9 | $how = isset($_GET['how']) ? $_GET['how'] : 'no'; |
---|
10 | $backurl = isset($_GET['backurl']) ? $_GET['backurl'] : null; |
---|
11 | $backtitle = isset($_GET['backtitle']) ? $_GET['backtitle'] : null; |
---|
12 | |
---|
13 | $template_callback = function($template) use($backurl,$backtitle) { |
---|
14 | if($backurl) { |
---|
15 | $template->set_page_relation("prev", $backurl, $backtitle ? $backtitle : "German version of page"); |
---|
16 | $template->current_link_classes = array('show-rel-prev'); |
---|
17 | } |
---|
18 | |
---|
19 | $template->interlang_links = array( |
---|
20 | 'de' => $backurl ? t29Menu::dom_new_link($backurl, $backtitle) : t29Menu::dom_new_link('#', 'unknown'), |
---|
21 | 'en' => t29Menu::dom_new_link('#', 'This "no translation available" page'), |
---|
22 | ); |
---|
23 | }; |
---|
24 | |
---|
25 | require "../lib/technikum29.php"; |
---|
26 | ?> |
---|
27 | <!-- |
---|
28 | "Not yet translated"-Page Usage |
---|
29 | Get-Param optional values |
---|
30 | how yes (yet|no) => yet = Not yet translated | no = no translation |
---|
31 | backurl yes == url_de |
---|
32 | backtitle required title of german page |
---|
33 | |
---|
34 | GET-Parameters can be seperated by using , (commas) or normal sperators (&), for example: |
---|
35 | ?how=yet&backurl=index.shtm&backtitle=Main%20Page |
---|
36 | ?how=no,backtitle=Blabla |
---|
37 | --> |
---|
38 | |
---|
39 | <?php |
---|
40 | |
---|
41 | |
---|
42 | if($how == 'yet') |
---|
43 | $h2 = "The page »$backtitle« has not been translated yet"; |
---|
44 | else |
---|
45 | $h2 = "There is no translation for ".($backtitle ? " »$backtitle«" : "the page you requested"); |
---|
46 | |
---|
47 | print "<h2>$h2</h2>"; |
---|
48 | |
---|
49 | //$url_de = "/de/"... |
---|
50 | //$backurl = "/de/".$url_de; |
---|
51 | |
---|
52 | if($backurl) { |
---|
53 | ?><p class="panel-hide">Please <a href="<?=$backurl; ?>">go back to the german page</a>.</p> |
---|
54 | <p>You can also use automatically generated translations from <a href="http://www.google.com">Google</a> or <a href="http://babelfish.altavista.com">Altavista Babelfish</a> |
---|
55 | (but don't expect too much):</p> |
---|
56 | <ul> |
---|
57 | <li><a href="http://translate.google.com/translate?hl=en&sl=de&u=http://www.technikum29.de/<?=$backurl; ?>&prev=/search%3Fq%3Dtechnikum29%26hl%3Den%26lr%3D%26sa%3DN">Read the google translation</a></li> |
---|
58 | <!--<li><a href="http://babelfish.altavista.com/babelfish/tr?doit=done&url=http://www.technikum29.de/<?=$backurl; ?>&lp=de_en">Read the Altavista bablefish translation</a>--> |
---|
59 | <li><a href="http://www.microsofttranslator.com/bv.aspx?from=de&to=en&a=http://www.technikum29.de/<?=$backurl; ?>">Read the Microsoft translator (Babelfish/Bing)</a></li> |
---|
60 | </ul><?php |
---|
61 | } else { |
---|
62 | ?> |
---|
63 | <p>There is no english translation for the requested page.</p> |
---|
64 | <p><a class="go" href="javascript:history.go();">Back to the german page</a></p> |
---|
65 | <?php |
---|
66 | } |
---|