Changeset 71038c3


Ignore:
Timestamp:
Jul 13, 2013 7:58:11 PM (7 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
c1210b1
Parents:
70a8ab1
Message:
  • Translations:
    • New varargs method in Translate
    • New TranslateReader? to translate static files on-the-fly using _("") tagging
    • Tag proxy error pages for TranslateReader?
    • Drop static translated proxy error pages
    • Add new i2ptunnel bundle for the proxy alone, shipped in the jar
    • Use TranslateReader? in HTTP proxy for error pages
    • Move HTTP proxy strings from the web *war) to proxy (jar) bundle so they will be loaded
    • Initial translations created by msgmerge from i2ptunnel and routerconsole po files, un-fuzzied
Files:
19 added
54 deleted
22 edited

Legend:

Unmodified
Added
Removed
  • .tx/config

    r70a8ab1 r71038c3  
    1919trans.vi = apps/i2ptunnel/locale/messages_vi.po
    2020trans.zh_CN = apps/i2ptunnel/locale/messages_zh.po
     21
     22[I2P.proxy]
     23source_file = apps/i2ptunnel/locale-proxy/messages_en.po
     24source_lang = en
     25trans.ar = apps/i2ptunnel/locale-proxy/messages_ar.po
     26trans.cs = apps/i2ptunnel/locale-proxy/messages_cs.po
     27trans.de = apps/i2ptunnel/locale-proxy/messages_de.po
     28trans.es = apps/i2ptunnel/locale-proxy/messages_es.po
     29trans.fr = apps/i2ptunnel/locale-proxy/messages_fr.po
     30trans.hu = apps/i2ptunnel/locale-proxy/messages_hu.po
     31trans.it = apps/i2ptunnel/locale-proxy/messages_it.po
     32trans.nb = apps/i2ptunnel/locale-proxy/messages_nb.po
     33trans.nl = apps/i2ptunnel/locale-proxy/messages_nl.po
     34trans.pl = apps/i2ptunnel/locale-proxy/messages_pl.po
     35trans.pt = apps/i2ptunnel/locale-proxy/messages_pt.po
     36trans.ru_RU = apps/i2ptunnel/locale-proxy/messages_ru.po
     37trans.sv_SE = apps/i2ptunnel/locale-proxy/messages_sv.po
     38trans.uk_UA = apps/i2ptunnel/locale-proxy/messages_uk.po
     39trans.vi = apps/i2ptunnel/locale-proxy/messages_vi.po
     40trans.zh_CN = apps/i2ptunnel/locale-proxy/messages_zh.po
    2141
    2242[I2P.routerconsole]
  • apps/i2ptunnel/java/build.xml

    r70a8ab1 r71038c3  
    5757
    5858    <!-- The web classes are now in the war not the jar - they are not part of the API -->
    59     <target name="jar" depends="builddep, compile, jarUpToDate, listChangedFiles" unless="jar.uptodate" >
     59    <target name="jar" depends="builddep, compile, bundle-proxy, jarUpToDate, listChangedFiles" unless="jar.uptodate" >
    6060        <!-- set if unset -->
    6161        <property name="workspace.changes.j.tr" value="" />
     
    8888    </target>
    8989
     90    <!-- servlet translations go in the war, not the jar -->
    9091    <target name="bundle" depends="compile, precompilejsp" unless="no.bundle">
    9192        <!-- Update the messages_*.po files.
     
    115116        <exec executable="sh" osfamily="windows" failifexecutionfails="true" failonerror="true" >
    116117            <arg value="./bundle-messages.sh" />
     118            <arg value="-p" />
     119        </exec>
     120    </target>
     121
     122    <!-- proxy error page translations go in the jar, not the war -->
     123    <target name="bundle-proxy" unless="no.bundle">
     124        <!-- Update the messages_*.po files.
     125             We need to supply the bat file for windows, and then change the fail property to true -->
     126        <exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" >
     127            <arg value="./bundle-messages-proxy.sh" />
     128        </exec>
     129        <exec executable="sh" osfamily="mac" failifexecutionfails="true" failonerror="${require.gettext}" >
     130            <arg value="./bundle-messages-proxy.sh" />
     131        </exec>
     132                <!-- multi-lang is optional -->
     133        <exec executable="sh" osfamily="windows" failifexecutionfails="false" >
     134            <arg value="./bundle-messages-proxy.sh" />
     135        </exec>
     136    </target>
     137
     138    <target name="extractProxyTags">
     139        <java classname="net.i2p.util.TranslateReader" fork="true" failonerror="true">
     140            <classpath>
     141                <pathelement location="../../../build/i2p.jar" />
     142            </classpath>
     143            <arg value="tag" />
     144            <arg value="../../../installer/resources/proxy/" />
     145            <arg value="build/Proxy.java" />
     146        </java>
     147    </target>
     148
     149    <target name="poupdate-proxy" depends="extractProxyTags">
     150        <!-- Update the messages_*.po files. -->
     151        <exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="true" >
     152            <arg value="./bundle-messages-proxy.sh" />
     153            <arg value="-p" />
     154        </exec>
     155        <exec executable="sh" osfamily="mac" failifexecutionfails="true" failonerror="true" >
     156            <arg value="./bundle-messages-proxy.sh" />
     157            <arg value="-p" />
     158        </exec>
     159        <exec executable="sh" osfamily="windows" failifexecutionfails="true" failonerror="true" >
     160            <arg value="./bundle-messages-proxy.sh" />
    117161            <arg value="-p" />
    118162        </exec>
  • apps/i2ptunnel/java/bundle-messages.sh

    r70a8ab1 r71038c3  
    3030
    3131# add ../java/ so the refs will work in the po file
    32 JPATHS="../java/src ../jsp/WEB-INF"
     32JPATHS="../java/src/net/i2p/i2ptunnel/web ../jsp/WEB-INF"
    3333for i in ../locale/messages_*.po
    3434do
  • apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelHTTPClient.java

    r70a8ab1 r71038c3  
    14101410    }
    14111411     ****/
    1412     /** */
    1413     private static final String BUNDLE_NAME = "net.i2p.i2ptunnel.web.messages";
     1412
     1413    /** these strings go in the jar, not the war */
     1414    private static final String BUNDLE_NAME = "net.i2p.i2ptunnel.proxy.messages";
    14141415
    14151416    /** lang in routerconsole.lang property, else current locale */
  • apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelHTTPClientBase.java

    r70a8ab1 r71038c3  
    44package net.i2p.i2ptunnel;
    55
    6 import java.io.ByteArrayOutputStream;
    76import java.io.FileInputStream;
    87import java.io.IOException;
     8import java.io.Reader;
    99import java.io.UnsupportedEncodingException;
    1010import java.net.Socket;
     
    2828import net.i2p.util.Log;
    2929import net.i2p.util.PasswordManager;
     30import net.i2p.util.TranslateReader;
    3031
    3132/**
     
    497498    protected static byte[] getErrorPage(I2PAppContext ctx, String base, byte[] backup) {
    498499        File errorDir = new File(ctx.getBaseDir(), "docs");
    499         String lang = ctx.getProperty("routerconsole.lang", Locale.getDefault().getLanguage());
    500         if(lang != null && lang.length() > 0 && !lang.equals("en")) {
    501             File file = new File(errorDir, base + "-header_" + lang + ".ht");
    502             try {
    503                 return readFile(file);
    504             } catch(IOException ioe) {
    505                 // try the english version now
    506             }
    507         }
    508500        File file = new File(errorDir, base + "-header.ht");
    509501        try {
    510             return readFile(file);
     502            return readFile(ctx, file);
    511503        } catch(IOException ioe) {
    512504            return backup;
     
    514506    }
    515507
     508    private static final String BUNDLE_NAME = "net.i2p.i2ptunnel.proxy.messages";
     509
    516510    /**
    517511     *  @since 0.9.4 moved from I2PTunnelHTTPClient
    518512     */
    519     private static byte[] readFile(File file) throws IOException {
    520         FileInputStream fis = null;
    521         byte[] buf = new byte[2048];
    522         ByteArrayOutputStream baos = new ByteArrayOutputStream(2048);
     513    private static byte[] readFile(I2PAppContext ctx, File file) throws IOException {
     514        Reader reader = null;
     515        char[] buf = new char[512];
     516        StringBuilder out = new StringBuilder(2048);
    523517        try {
    524             int len = 0;
    525             fis = new FileInputStream(file);
    526             while((len = fis.read(buf)) > 0) {
    527                 baos.write(buf, 0, len);
     518            int len;
     519            reader = new TranslateReader(ctx, BUNDLE_NAME, new FileInputStream(file));
     520            while((len = reader.read(buf)) > 0) {
     521                out.append(buf, 0, len);
    528522            }
    529             return baos.toByteArray();
     523            return out.toString().getBytes("UTF-8");
    530524        } finally {
    531525            try {
    532                 if(fis != null) {
    533                     fis.close();
    534                 }
    535             } catch(IOException foo) {
    536             }
     526                if(reader != null)
     527                    reader.close();
     528            } catch(IOException foo) {}
    537529        }
    538530        // we won't ever get here
  • apps/i2ptunnel/java/src/net/i2p/i2ptunnel/localServer/LocalHTTPServer.java

    r70a8ab1 r71038c3  
    234234    }
    235235
    236     private static final String BUNDLE_NAME = "net.i2p.i2ptunnel.web.messages";
     236    /** these strings go in the jar, not the war */
     237    private static final String BUNDLE_NAME = "net.i2p.i2ptunnel.proxy.messages";
    237238
    238239    /** lang in routerconsole.lang property, else current locale */
  • build.xml

    r70a8ab1 r71038c3  
    435435        <ant dir="apps/routerconsole/java/" target="poupdate" />
    436436        <ant dir="apps/i2psnark/java/" target="poupdate" />
    437         <ant dir="apps/i2ptunnel/java/" target="poupdate" />
     437        <ant dir="apps/i2ptunnel/java/" >
     438            <target name="poupdate" />
     439            <target name="poupdate-proxy" />
     440        </ant>
    438441        <ant dir="apps/susidns/src/" target="poupdate" />
    439442        <ant dir="apps/susimail/" target="poupdate" />
  • core/java/src/net/i2p/util/Translate.java

    r70a8ab1 r71038c3  
    22
    33import java.text.MessageFormat;
     4import java.util.Arrays;
    45import java.util.Locale;
    56import java.util.Map;
     
    6566     */
    6667    public static String getString(String s, Object o, I2PAppContext ctx, String bun) {
     68        return getString(s, ctx, bun, o);
     69    }
     70
     71    /** for {0} and {1} */
     72    public static String getString(String s, Object o, Object o2, I2PAppContext ctx, String bun) {
     73        return getString(s, ctx, bun, o, o2);
     74    }
     75
     76    /**
     77     *  Varargs
     78     *  @param oArray parameters
     79     *  @since 0.9.8
     80     */
     81    public static String getString(String s, I2PAppContext ctx, String bun, Object... oArray) {
    6782        String lang = getLanguage(ctx);
    6883        if (lang.equals(TEST_LANG))
    69             return TEST_STRING + '(' + o + ')' + TEST_STRING;
     84            return TEST_STRING + Arrays.toString(oArray) + TEST_STRING;
    7085        String x = getString(s, ctx, bun);
    71         Object[] oArray = new Object[1];
    72         oArray[0] = o;
    7386        try {
    7487            MessageFormat fmt = new MessageFormat(x, new Locale(lang));
     
    7790            System.err.println("Bad format: orig: \"" + s +
    7891                               "\" trans: \"" + x +
    79                                "\" param: \"" + o +
    80                                "\" lang: " + lang);
    81             return "FIXME: " + x + ' ' + o;
    82         }
    83     }
    84 
    85     /** for {0} and {1} */
    86     public static String getString(String s, Object o, Object o2, I2PAppContext ctx, String bun) {
    87         String lang = getLanguage(ctx);
    88         if (lang.equals(TEST_LANG))
    89             return TEST_STRING + '(' + o + ',' + o2 + ')' + TEST_STRING;
    90         String x = getString(s, ctx, bun);
    91         Object[] oArray = new Object[2];
    92         oArray[0] = o;
    93         oArray[1] = o2;
    94         try {
    95             MessageFormat fmt = new MessageFormat(x, new Locale(lang));
    96             return fmt.format(oArray, new StringBuffer(), null).toString();
    97         } catch (IllegalArgumentException iae) {
    98             System.err.println("Bad format: orig: \"" + s +
    99                                "\" trans: \"" + x +
    100                                "\" param1: \"" + o +
    101                                "\" param2: \"" + o2 +
    102                                "\" lang: " + lang);
    103             return "FIXME: " + x + ' ' + o + ',' + o2;
     92                               "\" params: " + Arrays.toString(oArray) +
     93                               " lang: " + lang);
     94            return "FIXME: " + x + ' ' + Arrays.toString(oArray);
    10495        }
    10596    }
  • installer/resources/proxy/ahelper-conflict-header.ht

    r70a8ab1 r71038c3  
    77<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    88<html><head>
    9 <title>I2P Warning: Destination key conflict</title>
     9<title>_("Warning: Destination Key Conflict")</title>
    1010<link rel="shortcut icon" href="http://proxy.i2p/themes/console/images/favicon.ico">
    1111<link href="http://proxy.i2p/themes/console/default/console.css" rel="stylesheet" type="text/css">
     
    1313<body>
    1414<div class="logo">
    15  <a href="http://127.0.0.1:7657/" title="Router Console"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="I2P Router Console" border="0"></a><hr>
    16  <a href="http://127.0.0.1:7657/config.jsp">Configuration</a> <a href="http://127.0.0.1:7657/help.jsp">Help</a> <a href="http://127.0.0.1:7657/susidns/">Addressbook</a>
    1715</div>
    1816<div class="warning" id="warning">
    19 <h3>Warning: Destination Key Conflict</h3>
     17<h3>_("Warning: Destination Key Conflict")</h3>
    2018<p>
    21 The addresshelper link you followed specifies a different destination key
    22 than a host entry in your host database.
    23 Someone could be trying to impersonate another eepsite,
    24 or people have given two eepsites identical names.
     19_("The addresshelper link you followed specifies a different destination key than a host entry in your host database.")
     20_("Someone could be trying to impersonate another eepsite, or people have given two eepsites identical names.")
    2521</p>
    2622<p>
    27 You can resolve the conflict by considering which key you trust,
    28 and either discarding the addresshelper link,
    29 discarding the host entry from your host database,
    30 or naming one of them differently.
     23_("You can resolve the conflict by considering which key you trust, and either discarding the addresshelper link, discarding the host entry from your host database, or naming one of them differently.")
    3124</p>
  • installer/resources/proxy/ahelper-new-header.ht

    r70a8ab1 r71038c3  
    77<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    88<html><head>
    9 <title>I2P Information: New Host Name</title>
     9<title>_("Information: New Host Name")</title>
    1010<link rel="shortcut icon" href="http://proxy.i2p/themes/console/images/favicon.ico">
    1111<link href="http://proxy.i2p/themes/console/default/console.css" rel="stylesheet" type="text/css">
     
    1313<body>
    1414<div class="logo">
    15  <a href="http://127.0.0.1:7657/" title="Router Console"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="I2P Router Console" border="0"></a><hr>
    16  <a href="http://127.0.0.1:7657/config.jsp">Configuration</a> <a href="http://127.0.0.1:7657/help.jsp">Help</a> <a href="http://127.0.0.1:7657/susidns/">Addressbook</a>
     15 <a href="http://127.0.0.1:7657/" title="_("Router Console")"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="_("I2P Router Console")" border="0"></a><hr>
     16 <a href="http://127.0.0.1:7657/config.jsp">_("Configuration")</a> <a href="http://127.0.0.1:7657/help.jsp">_("Help")</a> <a href="http://127.0.0.1:7657/susidns/index">_("Addressbook")</a>
    1717</div>
    1818<div class="warning" id="warning">
    19 <h3>Information: New Host Name with Address Helper</h3>
     19<h3>_("Information: New Host Name with Address Helper")</h3>
    2020<p>
    21 The address helper link you followed is for a new host name that is not in your address book.
    22 You may save this host name to your local address book.
    23 If you save it to your address book, you will not see this message again.
    24 If you do not save it, the host name will be forgotten after the next router restart.
    25 If you do not wish to visit this host, click the "back" button on your browser.
     21_("The address helper link you followed is for a new host name that is not in your address book.")
     22_("You may save this host name to your local address book.")
     23_("If you save it to your address book, you will not see this message again.")
     24_("If you do not save it, the host name will be forgotten after the next router restart.")
     25_("If you do not wish to visit this host, click the \"back\" button on your browser.")
    2626</p>
  • installer/resources/proxy/ahelper-notfound-header.ht

    r70a8ab1 r71038c3  
    77<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    88<html><head>
    9 <title>I2P Warning: Bad Address Helper</title>
     9<title>_("Warning: Bad Address Helper")</title>
    1010<link rel="shortcut icon" href="http://proxy.i2p/themes/console/images/favicon.ico">
    1111<link href="http://proxy.i2p/themes/console/default/console.css" rel="stylesheet" type="text/css">
     
    1313<body>
    1414<div class="logo">
    15  <a href="http://127.0.0.1:7657/index.jsp" title="Router Console"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="I2P Router Console" border="0"></a><hr>
    16  <a href="http://127.0.0.1:7657/config.jsp">Configuration</a> <a href="http://127.0.0.1:7657/help.jsp">Help</a> <a href="http://127.0.0.1:7657/susidns/">Addressbook</a>
     15 <a href="http://127.0.0.1:7657/" title="_("Router Console")"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="_("I2P Router Console")" border="0"></a><hr>
     16 <a href="http://127.0.0.1:7657/config.jsp">_("Configuration")</a> <a href="http://127.0.0.1:7657/help.jsp">_("Help")</a> <a href="http://127.0.0.1:7657/susidns/index">_("Addressbook")</a>
    1717</div>
    1818<div class="warning" id="warning">
    19 <h3>Warning: Bad Address Helper</h3>
     19<h3>_("Warning: Bad Address Helper")</h3>
    2020<p>
    21 The helper key you put for i2paddresshelper= is not resolvable.
    22 It seems to be garbage data, or a mistyped b32. Check your URL
    23 to try and fix the helper key to be a valid Base 32 hostname or Base 64 key.
     21_("The helper key in the URL ({0}i2paddresshelper={1}) is not resolvable.", "<code>", "</code>")
     22_("It seems to be garbage data, or a mistyped Base 32 address.")
     23_("Check your URL to try and fix the helper key to be a valid Base 32 hostname or Base 64 key.")
    2424</p>
  • installer/resources/proxy/auth-header.ht

    r70a8ab1 r71038c3  
    99<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    1010<html><head>
    11 <title>Proxy Authorization Required</title>
     11<title>_("Proxy Authorization Required")</title>
    1212<!-- we cannot have links to CSS or images here, but we could put in some simple inline style -->
    1313</head>
    1414<body>
    1515<div class="warning" id="warning">
    16 <h3>I2P HTTP Proxy Authorization Required</h3>
     16<h3>_("I2P HTTP Proxy Authorization Required")</h3>
    1717<p>
    18 This proxy is configured to require a username and password for access.
    19 Please enter your username and password, or check your
    20 <a href="http://127.0.0.1:7657/advancedconfig.jsp">router configuration</a>
    21 or
    22 <a href="http://127.0.0.1:7657/i2ptunnel/index.jsp">I2PTunnel configuration</a>.
    23 To disable authorization, remove the configuration
    24 <code>i2ptunnel.proxy.auth=basic</code>, then stop and restart the HTTP Proxy tunnel.
     18_("This proxy is configured to require a username and password for access.")
     19_("Please enter your username and password, or check your {0}router configuration{1} or {2}I2PTunnel configuration{3}.", "<a href=\"http://127.0.0.1:7657/advancedconfig.jsp\">", "/a>", "<a href=\"http://127.0.0.1:7657/i2ptunnel/index.jsp\">", "</a>")
     20_("To disable authorization, remove the configuration {0}i2ptunnel.proxy.auth=basic{1}, then stop and restart the HTTP Proxy tunnel.", "<code>", "</code>"))
    2521</p>
    2622</div>
  • installer/resources/proxy/baduri-header.ht

    r70a8ab1 r71038c3  
    77<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    88<html><head>
    9 <title>I2P Warning: Invalid Request URI</title>
     9<title>_("Warning: Invalid Request URI")</title>
    1010<link rel="shortcut icon" href="http://proxy.i2p/themes/console/images/favicon.ico">
    1111<link href="http://proxy.i2p/themes/console/default/console.css" rel="stylesheet" type="text/css">
     
    1313<body>
    1414<div class="logo">
    15  <a href="http://127.0.0.1:7657/" title="Router Console"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="I2P Router Console" border="0"></a><hr>
    16  <a href="http://127.0.0.1:7657/config.jsp">Configuration</a> <a href="http://127.0.0.1:7657/help.jsp">Help</a> <a href="http://127.0.0.1:7657/susidns/">Addressbook</a>
     15 <a href="http://127.0.0.1:7657/" title="_("Router Console")"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="_("I2P Router Console")" border="0"></a><hr>
     16 <a href="http://127.0.0.1:7657/config.jsp">_("Configuration")</a> <a href="http://127.0.0.1:7657/help.jsp">_("Help")</a> <a href="http://127.0.0.1:7657/susidns/index">_("Addressbook")</a>
    1717</div>
    1818<div class="warning" id="warning">
    19 <h3>Warning: Invalid Request URI</h3>
     19<h3>_("Warning: Invalid Request URI")</h3>
    2020<p>
    21 The request URI is invalid, and probably contains illegal characters.
    22 If you clicked e.g. a forum link, check the end of the URI for any characters the browser has mistakenly added on.
     21_("The request URI is invalid, and probably contains illegal characters.")
     22_("If you clicked a link, check the end of the URI for any characters the browser has mistakenly added on.")
    2323</p>
    2424</div>
  • installer/resources/proxy/denied-header.ht

    r70a8ab1 r71038c3  
    77<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    88<html><head>
    9 <title>I2P Warning: Request Denied</title>
     9<title>_("Warning: Request Denied")</title>
    1010<link rel="shortcut icon" href="http://proxy.i2p/themes/console/images/favicon.ico">
    1111<link href="http://proxy.i2p/themes/console/default/console.css" rel="stylesheet" type="text/css">
     
    1313<body>
    1414<div class="logo">
    15  <a href="http://127.0.0.1:7657/" title="Router Console"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="I2P Router Console" border="0"></a><hr>
    16  <a href="http://127.0.0.1:7657/config.jsp">Configuration</a> <a href="http://127.0.0.1:7657/help.jsp">Help</a> <a href="http://127.0.0.1:7657/susidns/">Addressbook</a>
     15 <a href="http://127.0.0.1:7657/" title="_("Router Console")"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="_("I2P Router Console")" border="0"></a><hr>
     16 <a href="http://127.0.0.1:7657/config.jsp">_("Configuration")</a> <a href="http://127.0.0.1:7657/help.jsp">_("Help")</a> <a href="http://127.0.0.1:7657/susidns/index">_("Addressbook")</a>
    1717</div>
    1818<div class="warning" id="warning">
    19 <h3>Warning: Request Denied</h3>
     19<h3>_("Warning: Request Denied")</h3>
    2020<p>
    21 You attempted to connect to a non-I2P website or location.
     21_("You attempted to connect to a non-I2P website or location.")
    2222</p>
    2323</div>
  • installer/resources/proxy/dnf-header.ht

    r70a8ab1 r71038c3  
    77<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    88<html><head>
    9 <title>I2P Warning: Eepsite not reachable</title>
     9<title>_("Warning: Eepsite Unreachable")</title>
    1010<link rel="shortcut icon" href="http://proxy.i2p/themes/console/images/favicon.ico">
    1111<link href="http://proxy.i2p/themes/console/default/console.css" rel="stylesheet" type="text/css">
     
    1313<body>
    1414<div class="logo">
    15  <a href="http://127.0.0.1:7657/" title="Router Console"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="I2P Router Console" border="0"></a><hr>
    16  <a href="http://127.0.0.1:7657/config.jsp">Configuration</a> <a href="http://127.0.0.1:7657/help.jsp">Help</a> <a href="http://127.0.0.1:7657/susidns/index">Addressbook</a>
     15 <a href="http://127.0.0.1:7657/" title="_("Router Console")"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="_("I2P Router Console")" border="0"></a><hr>
     16 <a href="http://127.0.0.1:7657/config.jsp">_("Configuration")</a> <a href="http://127.0.0.1:7657/help.jsp">_("Help")</a> <a href="http://127.0.0.1:7657/susidns/index">_("Addressbook")</a>
    1717</div>
    1818<div class="warning" id="warning">
    19 <h3>Warning: Eepsite Unreachable</h3>
     19<h3>_("Warning: Eepsite Unreachable")</h3>
    2020<p>
    21 The eepsite was not reachable.
    22 The eepsite is offline, there is network congestion,
    23 or your router is not yet well-integrated with peers.
    24 You may want to
    25 <a href="javascript:window.location.reload()">retry</a>.</p>
     21_("The eepsite was not reachable.")
     22_("The eepsite is offline, there is network congestion, or your router is not yet well-integrated with peers.")
     23_("You may want to {0}retry{1}.", "<a href=\"javascript:window.location.reload()\">", "</a>")</p>
    2624<hr>
    27 <p><b>Could not find the following destination:</b>
     25<p><b>_("Could not find the following destination:")</b>
    2826</p>
  • installer/resources/proxy/dnfb-header.ht

    r70a8ab1 r71038c3  
    77<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    88<html><head>
    9 <title>I2P Warning: Invalid eepsite destination</title>
     9<title>_("Warning: Invalid Destination")</title>
    1010<link rel="shortcut icon" href="http://proxy.i2p/themes/console/images/favicon.ico">
    1111<link href="http://proxy.i2p/themes/console/default/console.css" rel="stylesheet" type="text/css">
     
    1313<body>
    1414<div class="logo">
    15  <a href="http://127.0.0.1:7657/" title="Router Console"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="I2P Router Console" border="0"></a><hr>
    16  <a href="http://127.0.0.1:7657/config.jsp">Configuration</a> <a href="http://127.0.0.1:7657/help.jsp">Help</a> <a href="http://127.0.0.1:7657/susidns/">Addressbook</a>
     15 <a href="http://127.0.0.1:7657/" title="_("Router Console")"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="_("I2P Router Console")" border="0"></a><hr>
     16 <a href="http://127.0.0.1:7657/config.jsp">_("Configuration")</a> <a href="http://127.0.0.1:7657/help.jsp">_("Help")</a> <a href="http://127.0.0.1:7657/susidns/index">_("Addressbook")</a>
    1717</div>
    1818<div class="warning" id="warning">
    19 <h3>Warning: Invalid Destination</h3>
     19<h3>_("Warning: Invalid Destination")</h3>
    2020<p>
    21 The eepsite destination specified was not valid, or was
    22 otherwise unreachable.  Perhaps you pasted in the
    23 wrong BASE64 string or the link you are following is
    24 bad. The I2P host could also be offline.  You may want to
    25 <a href="javascript:window.location.reload()">retry</a>.
    26 <hr><b>Could not find the following destination:</b>
     21_("The eepsite destination specified was not valid, or was otherwise unreachable.")
     22_("Perhaps you pasted in the wrong Base 64 string or the link you are following is bad.")
     23_("The I2P host could also be offline.")
     24_("You may want to {0}retry{1}.", "<a href=\"javascript:window.location.reload()\">", "</a>")
     25<hr><b>_("Could not find the following destination:")</b>
    2726</p>
  • installer/resources/proxy/dnfh-header.ht

    r70a8ab1 r71038c3  
    77<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    88<html><head>
    9 <title>I2P Warning: Eepsite unknown</title>
     9<title>_("Warning: Eepsite Unknown")</title>
    1010<link rel="shortcut icon" href="http://proxy.i2p/themes/console/images/favicon.ico">
    1111<link href="http://proxy.i2p/themes/console/default/console.css" rel="stylesheet" type="text/css">
     
    1313<body>
    1414<div class="logo">
    15  <a href="http://127.0.0.1:7657/" title="Router Console"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="I2P Router Console" border="0"></a><hr>
    16  <a href="http://127.0.0.1:7657/config.jsp">Configuration</a> <a href="http://127.0.0.1:7657/help.jsp">Help</a> <a href="http://127.0.0.1:7657/susidns/index">Addressbook</a>
     15 <a href="http://127.0.0.1:7657/" title="_("Router Console")"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="_("I2P Router Console")" border="0"></a><hr>
     16 <a href="http://127.0.0.1:7657/config.jsp">_("Configuration")</a> <a href="http://127.0.0.1:7657/help.jsp">_("Help")</a> <a href="http://127.0.0.1:7657/susidns/index">_("Addressbook")</a>
    1717</div>
    1818<div class="warning" id="warning">
    19 <h3>Warning: Eepsite Not Found in Addressbook</h3>
     19<h3>_("Warning: Eepsite Not Found in Addressbook")</h3>
    2020<p>
    21 The eepsite was not found in your router's addressbook.
    22 Check the link or find a Base 32 or Base 64 address.
    23 If you have the Base 64 address,
    24 <a href="http://127.0.0.1:7657/susidns/addressbook.jsp?book=router">add it to your addressbook</a>.
    25 Otherwise, find a Base 32 or address helper link, or use a jump service link below.
     21_("The eepsite was not found in your router's addressbook.")
     22_("Check the link or find a Base 32 or Base 64 address.")
     23_("If you have the Base 64 address, {0}add it to your addressbook{1}.", "<a href=\"http://127.0.0.1:7657/susidns/addressbook.jsp?book=router\">", "</a>")
     24_("Otherwise, find a Base 32 or address helper link, or use a jump service link below.")
    2625</p>
    2726<p>
    28 Seeing this page often? See <a href="http://www.i2p2.i2p/faq.html#subscriptions">the FAQ</a>
    29 for help in <a href="http://127.0.0.1:7657/susidns/config.jsp">adding some subscriptions</a>
    30 to your addressbook.</p><hr>
     27_("Seeing this page often? See {0}the FAQ{1} for help in {2}adding some subscriptions{3} to your addressbook.", "<a href=\"http://www.i2p2.i2p/faq.html#subscriptions\">", "</a>", "<a href=\"http://127.0.0.1:7657/susidns/config.jsp\">", "</a>")
     28</p><hr>
    3129<p>
    32 <b>Could not find the following destination:</b>
     30<b>_("Could not find the following destination:")</b>
    3331</p>
  • installer/resources/proxy/dnfp-header.ht

    r70a8ab1 r71038c3  
    77<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    88<html><head>
    9 <title>I2P Warning: Outproxy Not Found</title>
     9<title>_("Warning: Outproxy Not Found")</title>
    1010<link rel="shortcut icon" href="http://proxy.i2p/themes/console/images/favicon.ico">
    1111<link href="http://proxy.i2p/themes/console/default/console.css" rel="stylesheet" type="text/css">
     
    1313<body>
    1414<div class="logo">
    15  <a href="http://127.0.0.1:7657/" title="Router Console"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="I2P Router Console" border="0"></a><hr>
    16  <a href="http://127.0.0.1:7657/config.jsp">Configuration</a> <a href="http://127.0.0.1:7657/help.jsp">Help</a> <a href="http://127.0.0.1:7657/susidns/">Addressbook</a>
     15 <a href="http://127.0.0.1:7657/" title="_("Router Console")"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="_("I2P Router Console")" border="0"></a><hr>
     16 <a href="http://127.0.0.1:7657/config.jsp">_("Configuration")</a> <a href="http://127.0.0.1:7657/help.jsp">_("Help")</a> <a href="http://127.0.0.1:7657/susidns/index">_("Addressbook")</a>
    1717</div>
    1818<div class="warning" id="warning">
    19 <h3>Warning: Outproxy Not Found</h3>
     19<h3>_("Warning: Outproxy Not Found")</h3>
    2020<p>
    21 The HTTP Outproxy was not found.
    22 It is offline, there is network congestion,
    23 or your router is not yet well-integrated with peers.
    24 You may want to
    25 <a href="javascript:parent.window.location.reload()">retry</a>
    26 as this will randomly reselect an outproxy from the pool you have defined
    27 <a href="http://127.0.0.1:7657/i2ptunnel/index.jsp">here</a>
    28 (if you have more than one configured).
    29 If you continue to have trouble you may want to edit your outproxy list
    30 <a href="http://127.0.0.1:7657/i2ptunnel/edit.jsp?tunnel=0">here</a>.
     21_("The HTTP Outproxy was not found.")
     22_("It is offline, there is network congestion, or your router is not yet well-integrated with peers.")
     23_("You may want to {0}retry{1} as this will randomly reselect an outproxy from the pool you have defined {2}here{3} (if you have more than one configured).", "<a href=\"javascript:parent.window.location.reload()\">", "</a>", "<a href=\"http://127.0.0.1:7657/i2ptunnel/index.jsp\">", "</a>")
     24_("If you continue to have trouble you may want to edit your outproxy list {0}here{1}.", "<a href=\"http://127.0.0.1:7657/i2ptunnel/edit.jsp?tunnel=0\">", "</a>")
    3125</p>
    32 <hr><p><b>Could not find the following destination:</b></p>
     26<hr><p><b>_("Could not find the following destination:")</b></p>
  • installer/resources/proxy/localhost-header.ht

    r70a8ab1 r71038c3  
    77<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    88<html><head>
    9 <title>I2P Error: Request Denied</title>
     9<title>_("Error: Request Denied")</title>
    1010<link rel="shortcut icon" href="http://proxy.i2p/themes/console/images/favicon.ico">
    1111<link href="http://proxy.i2p/themes/console/default/console.css" rel="stylesheet" type="text/css">
     
    1515  Let's not infinite loop here....
    1616<div class="logo">
    17  <a href="http://127.0.0.1:7657/" title="Router Console"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="I2P Router Console" border="0"></a><hr>
    18  <a href="http://127.0.0.1:7657/config.jsp">Configuration</a> <a href="http://127.0.0.1:7657/help.jsp">Help</a> <a href="http://127.0.0.1:7657/susidns/">Addressbook</a>
     17 <a href="http://127.0.0.1:7657/" title="_("Router Console")"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="_("I2P Router Console")" border="0"></a><hr>
     18 <a href="http://127.0.0.1:7657/config.jsp">_("Configuration")</a> <a href="http://127.0.0.1:7657/help.jsp">_("Help")</a> <a href="http://127.0.0.1:7657/susidns/index">_("Addressbook")</a>
    1919</div>
    2020------------------------------>
    2121<div class="warning" id="warning">
    22 <h3>Error: Local Access</h3>
     22<h3>_("Error: Local Access")</h3>
    2323<p>
    24 Your browser is misconfigured. Do not use the proxy to access the router console,
    25 localhost, or local LAN destinations.
     24_("Your browser is misconfigured.")
     25_("Do not use the proxy to access the router console, localhost, or local LAN destinations.")
    2626</p>
    2727</div>
  • installer/resources/proxy/noproxy-header.ht

    r70a8ab1 r71038c3  
    77<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    88<html><head>
    9 <title>I2P Warning: No outproxy configured</title>
     9<title>_("Warning: No Outproxy Configured")</title>
    1010<link rel="shortcut icon" href="http://proxy.i2p/themes/console/images/favicon.ico">
    1111<link href="http://proxy.i2p/themes/console/default/console.css" rel="stylesheet" type="text/css">
     
    1313<body>
    1414<div class="logo">
    15  <a href="http://127.0.0.1:7657/" title="Router Console"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="I2P Router Console" border="0"></a><hr>
    16  <a href="http://127.0.0.1:7657/config.jsp">Configuration</a> <a href="http://127.0.0.1:7657/help.jsp">Help</a> <a href="http://127.0.0.1:7657/susidns/">Addressbook</a>
     15 <a href="http://127.0.0.1:7657/" title="_("Router Console")"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="_("I2P Router Console")" border="0"></a><hr>
     16 <a href="http://127.0.0.1:7657/config.jsp">_("Configuration")</a> <a href="http://127.0.0.1:7657/help.jsp">_("Help")</a> <a href="http://127.0.0.1:7657/susidns/index">_("Addressbook")</a>
    1717</div>
    1818<div class="warning" id="warning">
    19 <h3>Warning: No Outproxy Configured</h3>
     19<h3>_("Warning: No Outproxy Configured")</h3>
    2020<p>
    21 Your request was for a site outside of I2P, but you have no
    22 HTTP outproxy configured.  Please configure an outproxy in I2PTunnel.
     21_("Your request was for a site outside of I2P, but you have no HTTP outproxy configured.")
     22_("Please configure an outproxy in I2PTunnel.")
    2323</p>
    2424</div>
  • installer/resources/proxy/protocol-header.ht

    r70a8ab1 r71038c3  
    77<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    88<html><head>
    9 <title>I2P Warning: Non-HTTP Protocol</title>
     9<title>_("Warning: Non-HTTP Protocol")</title>
    1010<link rel="shortcut icon" href="http://proxy.i2p/themes/console/images/favicon.ico">
    1111<link href="http://proxy.i2p/themes/console/default/console.css" rel="stylesheet" type="text/css">
     
    1313<body>
    1414<div class="logo">
    15  <a href="http://127.0.0.1:7657/" title="Router Console"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="I2P Router Console" border="0"></a><hr>
    16  <a href="http://127.0.0.1:7657/config.jsp">Configuration</a> <a href="http://127.0.0.1:7657/help.jsp">Help</a> <a href="http://127.0.0.1:7657/susidns/">Addressbook</a>
     15 <a href="http://127.0.0.1:7657/" title="_("Router Console")"><img src="http://proxy.i2p/themes/console/images/i2plogo.png" alt="_("I2P Router Console")" border="0"></a><hr>
     16 <a href="http://127.0.0.1:7657/config.jsp">_("Configuration")</a> <a href="http://127.0.0.1:7657/help.jsp">_("Help")</a> <a href="http://127.0.0.1:7657/susidns/index">_("Addressbook")</a>
    1717</div>
    1818<div class="warning" id="warning">
    19 <h3>Warning: Non-HTTP Protocol</h3>
     19<h3>_("Warning: Non-HTTP Protocol")</h3>
    2020<p>
    21 The request uses a bad protocol.
    22 The I2P HTTP Proxy supports <code>http://</code> requests ONLY. Other protocols such as <code>https://</code> and <code>ftp://</code> are not allowed.
     21_("The request uses a bad protocol.")
     22_("The I2P HTTP Proxy supports {0}http://{1} requests ONLY.", "<code>", "</code>")
     23_("Other protocols such as {0}https://{1} and {0}ftp://{1} are not allowed.", "<code>", "</code>")
    2324</p>
    2425</div>
  • tests/scripts/checkpo.sh

    r70a8ab1 r71038c3  
    1212  apps/routerconsole/locale \
    1313  apps/i2ptunnel/locale \
     14  apps/i2ptunnel/locale-proxy \
    1415  apps/i2psnark/locale \
    1516  apps/susidns/locale \
Note: See TracChangeset for help on using the changeset viewer.