Internationalization support

Partially implements #101.
This commit is contained in:
Trevor Slocum 2020-08-28 16:20:22 -07:00
parent 984058ea6a
commit 2978d41212
7 changed files with 587 additions and 98 deletions

View File

@ -53,6 +53,8 @@ Installing
- Install ImageMagick and ensure that the ``convert`` command is available.
- Set ``TINYIB_THUMBNAIL`` to ``imagemagick``.
- **Note:** GIF files will have animated thumbnails, which will often have large file sizes.
- To use TINYIB in another language:
- Set ``TINYIB_LOCALE`` to a language code found in `locale/`.
6. [CHMOD](https://en.wikipedia.org/wiki/Chmod) write permissions to these directories:
- ./ (the directory containing TinyIB)
- ./src/

View File

@ -60,12 +60,24 @@ if (!file_exists('settings.php')) {
}
require 'settings.php';
if (function_exists('_')) {
if (defined('TINYIB_LOCALE')) {
setlocale(LC_ALL, TINYIB_LOCALE);
}
bindtextdomain('tinyib', 'locale');
textdomain('tinyib');
} else {
function _($string) {
return $string;
}
}
if (TINYIB_TRIPSEED == '' || TINYIB_ADMINPASS == '') {
fancyDie('TINYIB_TRIPSEED and TINYIB_ADMINPASS must be configured.');
fancyDie(_('TINYIB_TRIPSEED and TINYIB_ADMINPASS must be configured.'));
}
if (TINYIB_CAPTCHA === 'recaptcha' && (TINYIB_RECAPTCHA_SITE == '' || TINYIB_RECAPTCHA_SECRET == '')) {
fancyDie('TINYIB_RECAPTCHA_SITE and TINYIB_RECAPTCHA_SECRET must be configured.');
fancyDie(_('TINYIB_RECAPTCHA_SITE and TINYIB_RECAPTCHA_SECRET must be configured.'));
}
// Check directories are writable by the script
@ -75,7 +87,7 @@ if (TINYIB_DBMODE == 'flatfile') {
}
foreach ($writedirs as $dir) {
if (!is_writable($dir)) {
fancyDie("Directory '" . $dir . "' can not be written to. Please modify its permissions.");
fancyDie(sprintf(_("Directory '%s' can not be written to. Please modify its permissions."), $dir));
}
}
@ -83,7 +95,7 @@ $includes = array("inc/defines.php", "inc/functions.php", "inc/html.php");
if (in_array(TINYIB_DBMODE, array('flatfile', 'mysql', 'mysqli', 'sqlite', 'sqlite3', 'pdo'))) {
$includes[] = 'inc/database_' . TINYIB_DBMODE . '.php';
} else {
fancyDie("Unknown database mode specified.");
fancyDie(_('Unknown database mode specified.'));
}
foreach ($includes as $include) {
@ -98,7 +110,7 @@ $redirect = true;
// Check if the request is to make a post
if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name']) || isset($_POST['email']) || isset($_POST['subject']) || isset($_POST['message']) || isset($_POST['file']) || isset($_POST['embed']) || isset($_POST['password']))) {
if (TINYIB_DBMIGRATE) {
fancyDie('Posting is currently disabled.<br>Please try again in a few moments.');
fancyDie(_('Posting is currently disabled.<br>Please try again in a few moments.'));
}
list($loggedin, $isadmin) = manageCheckLogIn();
@ -117,9 +129,9 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
if ($post['parent'] != TINYIB_NEWTHREAD && !$loggedin) {
$parent = postByID($post['parent']);
if (!isset($parent['locked'])) {
fancyDie("Invalid parent thread ID supplied, unable to create post.");
fancyDie(_('Invalid parent thread ID supplied, unable to create post.'));
} else if ($parent['locked'] == 1) {
fancyDie('Replies are not allowed to locked threads.');
fancyDie(_('Replies are not allowed to locked threads.'));
}
}
@ -156,12 +168,12 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
if (isset($_POST['embed']) && trim($_POST['embed']) != '' && ($rawpost || !in_array('embed', $hide_fields))) {
if (isset($_FILES['file']) && $_FILES['file']['name'] != "") {
fancyDie("Embedding a URL and uploading a file at the same time is not supported.");
fancyDie(_('Embedding a URL and uploading a file at the same time is not supported.'));
}
list($service, $embed) = getEmbed(trim($_POST['embed']));
if (empty($embed) || !isset($embed['html']) || !isset($embed['title']) || !isset($embed['thumbnail_url'])) {
fancyDie("Invalid embed URL. Only " . (implode("/", array_keys($tinyib_embeds))) . " URLs are supported.");
fancyDie(sprintf(_('Invalid embed URL. Only %s URLs are supported.'), implode('/', array_keys($tinyib_embeds))));
}
$post['file_hex'] = $service;
@ -181,14 +193,14 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
} else if ($file_mime == "image/png") {
$post['thumb'] = $temp_file . '.png';
} else {
fancyDie("Error while processing audio/video.");
fancyDie(_('Error while processing audio/video.'));
}
$thumb_location = "thumb/" . $post['thumb'];
list($thumb_maxwidth, $thumb_maxheight) = thumbnailDimensions($post);
if (!createThumbnail($file_location, $thumb_location, $thumb_maxwidth, $thumb_maxheight)) {
fancyDie("Could not create thumbnail.");
fancyDie(_('Could not create thumbnail.'));
}
addVideoOverlay($thumb_location);
@ -204,11 +216,11 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
validateFileUpload();
if (!is_file($_FILES['file']['tmp_name']) || !is_readable($_FILES['file']['tmp_name'])) {
fancyDie("File transfer failure. Please retry the submission.");
fancyDie(_('File transfer failure. Please retry the submission.'));
}
if ((TINYIB_MAXKB > 0) && (filesize($_FILES['file']['tmp_name']) > (TINYIB_MAXKB * 1024))) {
fancyDie("That file is larger than " . TINYIB_MAXKBDESC . ".");
fancyDie(sprintf(_('That file is larger than %s.'), TINYIB_MAXKBDESC));
}
$post['file_original'] = trim(htmlentities(substr($_FILES['file']['name'], 0, 50), ENT_QUOTES));
@ -223,7 +235,7 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
$file_mime = strtolower(array_pop($file_mime_split));
} else {
if (!@getimagesize($_FILES['file']['tmp_name'])) {
fancyDie("Failed to read the MIME type and size of the uploaded file. Please retry the submission.");
fancyDie(_('Failed to read the MIME type and size of the uploaded file. Please retry the submission.'));
}
$file_info = getimagesize($_FILES['file']['tmp_name']);
@ -239,12 +251,12 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
$file_location = "src/" . $post['file'];
if (!move_uploaded_file($_FILES['file']['tmp_name'], $file_location)) {
fancyDie("Could not copy uploaded file.");
fancyDie(_('Could not copy uploaded file.'));
}
if ($_FILES['file']['size'] != filesize($file_location)) {
@unlink($file_location);
fancyDie("File transfer failure. Please go back and try again.");
fancyDie(_('File transfer failure. Please go back and try again.'));
}
if ($file_mime == "audio/webm" || $file_mime == "video/webm" || $file_mime == "audio/mp4" || $file_mime == "video/mp4") {
@ -263,7 +275,7 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
if ($post['thumb_width'] <= 0 || $post['thumb_height'] <= 0) {
@unlink($file_location);
@unlink("thumb/" . $post['thumb']);
fancyDie("Sorry, your video appears to be corrupt.");
fancyDie(_('Sorry, your video appears to be corrupt.'));
}
addVideoOverlay("thumb/" . $post['thumb']);
@ -288,7 +300,7 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
$post['thumb'] = $file_name . "s." . array_pop($thumbfile_split);
if (!copy($tinyib_uploads[$file_mime][1], "thumb/" . $post['thumb'])) {
@unlink($file_location);
fancyDie("Could not create thumbnail.");
fancyDie(_('Could not create thumbnail.'));
}
if ($file_mime == "application/x-shockwave-flash") {
addVideoOverlay("thumb/" . $post['thumb']);
@ -299,7 +311,7 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
if (!createThumbnail($file_location, "thumb/" . $post['thumb'], $thumb_maxwidth, $thumb_maxheight)) {
@unlink($file_location);
fancyDie("Could not create thumbnail.");
fancyDie(_('Could not create thumbnail.'));
}
}
@ -323,7 +335,7 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
$allowed .= "embed URL";
}
if ($post['parent'] == TINYIB_NEWTHREAD && $allowed != "" && !TINYIB_NOFILEOK) {
fancyDie("A $allowed is required to start a thread.");
fancyDie(sprintf(_('A %s is required to start a thread.'), $allowed));
}
if (!$rawpost && str_replace('<br>', '', $post['message']) == "") {
$die_msg = "";
@ -336,12 +348,12 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
fancyDie("Please $die_msg.");
}
} else {
echo $post['file_original'] . ' uploaded.<br>';
echo sprintf(_('%s uploaded.'), $post['file_original']) . '<br>';
}
if (!$loggedin && (($post['file'] != '' && TINYIB_REQMOD == 'files') || TINYIB_REQMOD == 'all')) {
$post['moderated'] = '0';
echo 'Your ' . ($post['parent'] == TINYIB_NEWTHREAD ? 'thread' : 'post') . ' will be shown <b>once it has been approved</b>.<br>';
echo sprintf(_('Your %s will be shown <b>once it has been approved</b>.'), $post['parent'] == TINYIB_NEWTHREAD ? 'thread' : 'post') . '<br>';
$slow_redirect = true;
}
@ -354,7 +366,7 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
trimThreads();
echo 'Updating thread...<br>';
echo _('Updating thread...') . '<br>';
if ($post['parent'] != TINYIB_NEWTHREAD) {
rebuildThread($post['parent']);
@ -367,17 +379,17 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
rebuildThread($post['id']);
}
echo 'Updating index...<br>';
echo _('Updating index...') . '<br>';
rebuildIndexes();
}
// Check if the request is to delete a post and/or its associated image
} elseif (isset($_GET['delete']) && !isset($_GET['manage'])) {
if (!isset($_POST['delete'])) {
fancyDie('Tick the box next to a post and click "Delete" to delete it.');
fancyDie(_('Tick the box next to a post and click "Delete" to delete it.'));
}
if (TINYIB_DBMIGRATE) {
fancyDie('Post deletion is currently disabled.<br>Please try again in a few moments.');
fancyDie(_('Post deletion is currently disabled.<br>Please try again in a few moments.'));
}
$post = postByID($_POST['delete']);
@ -394,12 +406,12 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
} else {
threadUpdated($post['parent']);
}
fancyDie('Post deleted.');
fancyDie(_('Post deleted.'));
} else {
fancyDie('Invalid password.');
fancyDie(_('Invalid password.'));
}
} else {
fancyDie('Sorry, an invalid post identifier was sent. Please go back, refresh the page, and try again.');
fancyDie(_('Sorry, an invalid post identifier was sent. Please go back, refresh the page, and try again.'));
}
$redirect = false;
@ -423,7 +435,7 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
rebuildThread($thread['id']);
}
rebuildIndexes();
$text .= manageInfo('Rebuilt board.');
$text .= manageInfo(_('Rebuilt board.'));
} elseif (isset($_GET['bans'])) {
clearExpiredBans();
@ -431,7 +443,7 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
if ($_POST['ip'] != '') {
$banexists = banByIP($_POST['ip']);
if ($banexists) {
fancyDie('Sorry, there is already a ban on record for that IP address.');
fancyDie(_('Sorry, there is already a ban on record for that IP address.'));
}
$ban = array();
@ -440,13 +452,13 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
$ban['reason'] = $_POST['reason'];
insertBan($ban);
$text .= manageInfo('Ban record added for ' . $ban['ip']);
$text .= manageInfo(sprintf(_('Ban record added for %s'), $ban['ip']));
}
} elseif (isset($_GET['lift'])) {
$ban = banByID($_GET['lift']);
if ($ban) {
deleteBanByID($_GET['lift']);
$text .= manageInfo('Ban record lifted for ' . $ban['ip']);
$text .= manageInfo(sprintf(_('Ban record lifted for %s'), $ban['ip']));
}
}
@ -538,9 +550,9 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
if ($post['parent'] != TINYIB_NEWTHREAD) {
rebuildThread($post['parent']);
}
$text .= manageInfo('Post No.' . $post['id'] . ' deleted.');
$text .= manageInfo(sprintf(_('Post No.%d deleted.'), $post['id']));
} else {
fancyDie("Sorry, there doesn't appear to be a post with that ID.");
fancyDie(_("Sorry, there doesn't appear to be a post with that ID."));
}
} elseif (isset($_GET['approve'])) {
if ($_GET['approve'] > 0) {
@ -554,9 +566,9 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
}
threadUpdated($thread_id);
$text .= manageInfo('Post No.' . $post['id'] . ' approved.');
$text .= manageInfo(sprintf(_('Post No.%d approved.'), $post['id']));
} else {
fancyDie("Sorry, there doesn't appear to be a post with that ID.");
fancyDie(_("Sorry, there doesn't appear to be a post with that ID."));
}
}
} elseif (isset($_GET['moderate'])) {
@ -565,7 +577,7 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
if ($post) {
$text .= manageModeratePost($post);
} else {
fancyDie("Sorry, there doesn't appear to be a post with that ID.");
fancyDie(_("Sorry, there doesn't appear to be a post with that ID."));
}
} else {
$onload = manageOnLoad('moderate');
@ -580,10 +592,10 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
$text .= manageInfo('Thread No.' . $post['id'] . ' ' . (intval($_GET['setsticky']) == 1 ? 'stickied' : 'un-stickied') . '.');
} else {
fancyDie("Sorry, there doesn't appear to be a thread with that ID.");
fancyDie(_("Sorry, there doesn't appear to be a post with that ID."));
}
} else {
fancyDie("Form data was lost. Please go back and try again.");
fancyDie(_('Form data was lost. Please go back and try again.'));
}
} elseif (isset($_GET['lock']) && isset($_GET['setlock'])) {
if ($_GET['lock'] > 0) {
@ -594,10 +606,10 @@ if (!isset($_GET['delete']) && !isset($_GET['manage']) && (isset($_POST['name'])
$text .= manageInfo('Thread No.' . $post['id'] . ' ' . (intval($_GET['setlock']) == 1 ? 'locked' : 'unlocked') . '.');
} else {
fancyDie("Sorry, there doesn't appear to be a thread with that ID.");
fancyDie(_("Sorry, there doesn't appear to be a post with that ID."));
}
} else {
fancyDie("Form data was lost. Please go back and try again.");
fancyDie(_('Form data was lost. Please go back and try again.'));
}
} elseif (isset($_GET["rawpost"])) {
$onload = manageOnLoad("rawpost");

View File

@ -10,6 +10,9 @@ define('TINYIB_WORDBREAK_IDENTIFIER', '@!@TINYIB_WORDBREAK@!@');
// The following are provided for backward compatibility and should not be relied upon
// Copy new settings from settings.default.php to settings.php
if (!defined('TINYIB_LOCALE')) {
define('TINYIB_LOCALE', '');
}
if (!defined('TINYIB_INDEX')) {
define('TINYIB_INDEX', 'index.html');
}

View File

@ -211,7 +211,7 @@ function nameAndTripcode($name) {
function nameBlock($name, $tripcode, $email, $timestamp, $rawposttext) {
$output = '<span class="postername">';
$output .= ($name == '' && $tripcode == '') ? 'Anonymous' : $name;
$output .= ($name == '' && $tripcode == '') ? _('Anonymous') : $name;
if ($tripcode != '') {
$output .= '</span><span class="postertrip">!' . $tripcode;
@ -320,9 +320,9 @@ function checkCAPTCHA() {
$captcha_solution = isset($_SESSION['tinyibcaptcha']) ? strtolower(trim($_SESSION['tinyibcaptcha'])) : '';
if ($captcha == '') {
fancyDie('Please enter the CAPTCHA text.');
fancyDie(_('Please enter the CAPTCHA text.'));
} else if ($captcha != $captcha_solution) {
fancyDie('Incorrect CAPTCHA text entered. Please try again.<br>Click the image to retrieve a new CAPTCHA.');
fancyDie(_('Incorrect CAPTCHA text entered. Please try again.<br>Click the image to retrieve a new CAPTCHA.'));
}
}
}
@ -353,7 +353,7 @@ function checkFlood() {
function checkMessageSize() {
if (strlen($_POST["message"]) > 8000) {
fancyDie("Please shorten your message, or post it in multiple parts. Your message is " . strlen($_POST["message"]) . " characters long, and the maximum allowed is 8000.");
fancyDie(sprintf(_('Please shorten your message, or post it in multiple parts. Your message is %1$d characters long, and the maximum allowed is %2$d.'), strlen($_POST["message"]), 8000));
}
}
@ -384,7 +384,7 @@ function setParent() {
if (isset($_POST["parent"])) {
if ($_POST["parent"] != TINYIB_NEWTHREAD) {
if (!threadExistsByID($_POST['parent'])) {
fancyDie("Invalid parent thread ID supplied, unable to create post.");
fancyDie(_('Invalid parent thread ID supplied, unable to create post.'));
}
return $_POST["parent"];
@ -410,25 +410,25 @@ function validateFileUpload() {
case UPLOAD_ERR_OK:
break;
case UPLOAD_ERR_FORM_SIZE:
fancyDie("That file is larger than " . TINYIB_MAXKBDESC . ".");
fancyDie(sprintf(_('That file is larger than %s.'), TINYIB_MAXKBDESC));
break;
case UPLOAD_ERR_INI_SIZE:
fancyDie("The uploaded file exceeds the upload_max_filesize directive (" . ini_get('upload_max_filesize') . ") in php.ini.");
fancyDie(sprintf(_('The uploaded file exceeds the upload_max_filesize directive (%s) in php.ini.'), ini_get('upload_max_filesize')));
break;
case UPLOAD_ERR_PARTIAL:
fancyDie("The uploaded file was only partially uploaded.");
fancyDie(_('The uploaded file was only partially uploaded.'));
break;
case UPLOAD_ERR_NO_FILE:
fancyDie("No file was uploaded.");
fancyDie(_('No file was uploaded.'));
break;
case UPLOAD_ERR_NO_TMP_DIR:
fancyDie("Missing a temporary folder.");
fancyDie(_('Missing a temporary folder.'));
break;
case UPLOAD_ERR_CANT_WRITE:
fancyDie("Failed to write file to disk");
fancyDie(_('Failed to write file to disk'));
break;
default:
fancyDie("Unable to save the uploaded file.");
fancyDie(_('Unable to save the uploaded file.'));
}
}
@ -436,7 +436,7 @@ function checkDuplicateFile($hex) {
$hexmatches = postsByHex($hex);
if (count($hexmatches) > 0) {
foreach ($hexmatches as $hexmatch) {
fancyDie("Duplicate file uploaded. That file has already been posted <a href=\"res/" . (($hexmatch["parent"] == TINYIB_NEWTHREAD) ? $hexmatch["id"] : $hexmatch["parent"]) . ".html#" . $hexmatch["id"] . "\">here</a>.");
fancyDie(sprintf(_('Duplicate file uploaded. That file has already been posted <a href="%s">here</a>.'), 'res/' . (($hexmatch['parent'] == TINYIB_NEWTHREAD) ? $hexmatch['id'] : $hexmatch['parent'])) . '.html#' . $hexmatch['id']);
}
}
}
@ -467,7 +467,7 @@ function createThumbnail($file_location, $thumb_location, $new_w, $new_h) {
}
if (!$src_img) {
fancyDie("Unable to read uploaded file during thumbnailing. A common cause for this is an incorrect extension when the file is actually of a different type.");
fancyDie(_('Unable to read the uploaded file while creating its thumbnail. A common cause for this is an incorrect extension when the file is actually of a different type.'));
}
$old_x = imageSX($src_img);

View File

@ -58,7 +58,11 @@ function supportedFileTypes() {
? implode(', ', $types_allowed) . ' and ' . $types_last
: $types_last;
return "Supported file type" . (count($tinyib_uploads) != 1 ? "s are " : " is ") . $types_formatted . ".";
if (count($tinyib_uploads) == 1) {
return sprintf(_('Supported file type is %s'), $types_formatted);
} else {
return sprintf(_('Supported file types are %s.'), $types_formatted);
}
}
function makeLinksClickable($text) {
@ -93,22 +97,27 @@ function buildPostForm($parent, $raw_post = false) {
$input_extra = '';
$rules_extra = '';
if ($raw_post) {
$txt_reply_to = _('Reply to');
$txt_new_thread = _('0 to start a new thread');
$txt_info_1 = _('Text entered in the Message field will be posted as is with no formatting applied.');
$txt_info_2 = _('Line-breaks must be specified with "&lt;br&gt;".');
$form_action = '?';
$form_extra = '<input type="hidden" name="rawpost" value="1">';
$input_extra = <<<EOF
<tr>
<td class="postblock">
Reply to
$txt_reply_to
</td>
<td>
<input type="text" name="parent" size="28" maxlength="75" value="0" accesskey="t">&nbsp;0 to start a new thread
<input type="text" name="parent" size="28" maxlength="75" value="0" accesskey="t">&nbsp;$txt_new_thread
</td>
</tr>
EOF;
$rules_extra = <<<EOF
<ul>
<li>Text entered in the Message field will be posted as is with no formatting applied.</li>
<li>Line-breaks must be specified with "&lt;br&gt;".</li>
<li>$txt_info_1</li>
<li>$txt_info_2</li>
</ul><br>
EOF;
}
@ -142,14 +151,15 @@ EOF;
</div>';
} else { // Simple CAPTCHA
$captcha_inner_html = '
<input type="text" name="captcha" id="captcha" size="6" accesskey="c" autocomplete="off">&nbsp;&nbsp;(enter the text below)<br>
<input type="text" name="captcha" id="captcha" size="6" accesskey="c" autocomplete="off">&nbsp;&nbsp;' . _('(enter the text below)') . '<br>
<img id="captchaimage" src="inc/captcha.php" width="175" height="55" alt="CAPTCHA" onclick="javascript:reloadCAPTCHA()" style="margin-top: 5px;cursor: pointer;">';
}
$txt_captcha = _('CAPTCHA');
$captcha_html = <<<EOF
<tr>
<td class="postblock">
CAPTCHA
$txt_captcha
</td>
<td>
$captcha_inner_html
@ -161,15 +171,16 @@ EOF;
if (!empty($tinyib_uploads) && ($raw_post || !in_array('file', $hide_fields))) {
if (TINYIB_MAXKB > 0) {
$max_file_size_input_html = '<input type="hidden" name="MAX_FILE_SIZE" value="' . strval(TINYIB_MAXKB * 1024) . '">';
$max_file_size_rules_html = '<li>Maximum file size allowed is ' . TINYIB_MAXKBDESC . '.</li>';
$max_file_size_rules_html = '<li>' . sprintf(_('Maximum file size allowed is %s.'), TINYIB_MAXKBDESC) . '</li>';
}
$filetypes_html = '<li>' . supportedFileTypes() . '</li>';
$txt_file = _('File');
$file_input_html = <<<EOF
<tr>
<td class="postblock">
File
$txt_file
</td>
<td>
<input type="file" name="file" size="35" accesskey="f">
@ -179,13 +190,15 @@ EOF;
}
if (!empty($tinyib_embeds) && ($raw_post || !in_array('embed', $hide_fields))) {
$txt_embed = _('Embed');
$txt_embed_help = _('(paste a YouTube URL)');
$embed_input_html = <<<EOF
<tr>
<td class="postblock">
Embed
$txt_embed
</td>
<td>
<input type="text" name="embed" size="28" accesskey="x" autocomplete="off">&nbsp;&nbsp;(paste a YouTube URL)
<input type="text" name="embed" size="28" accesskey="x" autocomplete="off">&nbsp;&nbsp;$txt_embed_help
</td>
</tr>
EOF;
@ -202,12 +215,12 @@ EOF;
$maxdimensions .= ' (new thread) or ' . TINYIB_MAXW . 'x' . TINYIB_MAXH . ' (reply)';
}
$thumbnails_html = "<li>Images greater than $maxdimensions will be thumbnailed.</li>";
$thumbnails_html = '<li>' . sprintf(_('Images greater than %s will be thumbnailed.'), $maxdimensions) . '</li>';
}
$unique_posts = uniquePosts();
if ($unique_posts > 0) {
$unique_posts_html = "<li>Currently $unique_posts unique user posts.</li>\n";
$unique_posts_html = '<li>' . printf(_('Currently %s unique user posts.'), $unique_posts) . '</li>' . "\n";
}
$output = <<<EOF
@ -220,10 +233,11 @@ EOF;
$input_extra
EOF;
if ($raw_post || !in_array('name', $hide_fields)) {
$txt_name = _('Name');
$output .= <<<EOF
<tr>
<td class="postblock">
Name
$txt_name
</td>
<td>
<input type="text" name="name" size="28" maxlength="75" accesskey="n">
@ -233,10 +247,11 @@ EOF;
EOF;
}
if ($raw_post || !in_array('email', $hide_fields)) {
$txt_email = _('E-mail');
$output .= <<<EOF
<tr>
<td class="postblock">
E-mail
$txt_email
</td>
<td>
<input type="text" name="email" size="28" maxlength="75" accesskey="e">
@ -246,10 +261,11 @@ EOF;
EOF;
}
if ($raw_post || !in_array('subject', $hide_fields)) {
$txt_subject = _('Subject');
$output .= <<<EOF
<tr>
<td class="postblock">
Subject
$txt_subject
</td>
<td>
<input type="text" name="subject" size="40" maxlength="75" accesskey="s" autocomplete="off">
@ -259,10 +275,11 @@ EOF;
EOF;
}
if ($raw_post || !in_array('message', $hide_fields)) {
$txt_message = _('Message');
$output .= <<<EOF
<tr>
<td class="postblock">
Message
$txt_message
</td>
<td>
<textarea id="message" name="message" cols="48" rows="4" accesskey="m"></textarea>
@ -277,13 +294,15 @@ EOF;
$embed_input_html
EOF;
if ($raw_post || !in_array('password', $hide_fields)) {
$txt_password = _('Password');
$txt_password_help = _('(for post and file deletion)');
$output .= <<<EOF
<tr>
<td class="postblock">
Password
$txt_password
</td>
<td>
<input type="password" name="password" id="newpostpassword" size="8" accesskey="p">&nbsp;&nbsp;(for post and file deletion)
<input type="password" name="password" id="newpostpassword" size="8" accesskey="p">&nbsp;&nbsp;$txt_password_help
</td>
</tr>
EOF;
@ -350,7 +369,7 @@ function buildPost($post, $res) {
$direct_link = isEmbed($post["file_hex"]) ? "#" : (($res == TINYIB_RESPAGE ? "../" : "") . "src/" . $post["file"]);
if ($post['parent'] == TINYIB_NEWTHREAD && $post["file"] != '') {
$filesize .= isEmbed($post['file_hex']) ? 'Embed: ' : 'File: ';
$filesize .= (isEmbed($post['file_hex']) ? _('Embed:') : _('File:')) . ' ';
}
if (isEmbed($post["file_hex"])) {
@ -447,13 +466,13 @@ EOF;
}
if ($post['parent'] == TINYIB_NEWTHREAD && $res == TINYIB_INDEXPAGE) {
$return .= "&nbsp;[<a href=\"res/${post["id"]}.html\">Reply</a>]";
$return .= "&nbsp;[<a href=\"res/${post["id"]}.html\">" . _("Reply") . "</a>]";
}
if (TINYIB_TRUNCATE > 0 && !$res && substr_count($post['message'], '<br>') > TINYIB_TRUNCATE) { // Truncate messages on board index pages for readability
$br_offsets = strallpos($post['message'], '<br>');
$post['message'] = substr($post['message'], 0, $br_offsets[TINYIB_TRUNCATE - 1]);
$post['message'] .= '<br><span class="omittedposts">Post truncated. Click Reply to view.</span><br>';
$post['message'] .= '<br><span class="omittedposts">' . _('Post truncated. Click Reply to view.') . '</span><br>';
}
$return .= <<<EOF
<div class="message">
@ -463,7 +482,11 @@ EOF;
if ($post['parent'] == TINYIB_NEWTHREAD) {
if ($res == TINYIB_INDEXPAGE && $post['omitted'] > 0) {
$return .= '<span class="omittedposts">' . $post['omitted'] . ' ' . plural('post', $post['omitted']) . ' omitted. Click Reply to view.</span>';
if ($post['omitted'] == 1) {
$return .= '<span class="omittedposts">' . _('1 post omitted. Click Reply to view.') . '</span>';
} else {
$return .= '<span class="omittedposts">' . sprintf(_('%d posts omitted. Click Reply to view.'), $post['omitted']) . '</span>';
}
}
} else {
$return .= <<<EOF
@ -478,7 +501,7 @@ EOF;
}
function buildPage($htmlposts, $parent, $pages = 0, $thispage = 0) {
$cataloglink = TINYIB_CATALOG ? '[<a href="catalog.html" style="text-decoration: underline;">Catalog</a>]' : '';
$cataloglink = TINYIB_CATALOG ? ('[<a href="catalog.html" style="text-decoration: underline;">' . _('Catalog') . '</a>]') : '';
$managelink = basename($_SERVER['PHP_SELF']) . "?manage";
$postingmode = "";
@ -488,7 +511,7 @@ function buildPage($htmlposts, $parent, $pages = 0, $thispage = 0) {
$previous = ($thispage == 1) ? "index" : $thispage - 1;
$next = $thispage + 1;
$pagelinks = ($thispage == 0) ? "<td>Previous</td>" : '<td><form method="get" action="' . $previous . '.html"><input value="Previous" type="submit"></form></td>';
$pagelinks = ($thispage == 0) ? ('<td>' . _('Previous') . '</td>') : ('<td><form method="get" action="' . $previous . '.html"><input value="' . _('Previous') . '" type="submit"></form></td>');
$pagelinks .= "<td>";
for ($i = 0; $i <= $pages; $i++) {
@ -501,7 +524,7 @@ function buildPage($htmlposts, $parent, $pages = 0, $thispage = 0) {
}
$pagelinks .= "</td>";
$pagelinks .= ($pages <= $thispage) ? "<td>Next</td>" : '<td><form method="get" action="' . $next . '.html"><input value="Next" type="submit"></form></td>';
$pagelinks .= ($pages <= $thispage) ? ('<td>' . _('Next') . '</td>') : ('<td><form method="get" action="' . $next . '.html"><input value="' . _('Next') . '" type="submit"></form></td>');
$pagenavigator = <<<EOF
<table border="1" style="display: inline-block;">
@ -524,9 +547,9 @@ EOF;
EOF;
}
} else if ($parent == -1) {
$postingmode = '&#91;<a href="index.html">Return</a>&#93;<div class="replymode">Catalog</div> ';
$postingmode = '&#91;<a href="index.html">Return</a>&#93;<div class="replymode">' . _('Catalog') . '</div> ';
} else {
$postingmode = '&#91;<a href="../">Return</a>&#93;<div class="replymode">Posting mode: Reply</div> ';
$postingmode = '&#91;<a href="../">Return</a>&#93;<div class="replymode">' . _('Posting mode: Reply') . '</div> ';
}
$postform = '';
@ -534,12 +557,15 @@ EOF;
$postform = buildPostForm($parent);
}
$txt_manage = _('Manage');
$txt_style = _('Style');
$txt_delete = _('Delete Post');
$body = <<<EOF
<body>
<div class="adminbar">
$cataloglink
[<a href="$managelink" style="text-decoration: underline;">Manage</a>]
<select id="switchStylesheet"><option value="">Style</option><option value="futaba">Futaba</option><option value="burichan">Burichan</option></select>
[<a href="$managelink" style="text-decoration: underline;">$txt_manage</a>]
<select id="switchStylesheet"><option value="">$txt_style</option><option value="futaba">Futaba</option><option value="burichan">Burichan</option></select>
</div>
<div class="logo">
EOF;
@ -558,7 +584,7 @@ EOF;
<tbody>
<tr>
<td>
Delete Post <input type="password" name="password" id="deletepostpassword" size="8" placeholder="Password">&nbsp;<input name="deletepost" value="Delete" type="submit">
$txt_delete <input type="password" name="password" id="deletepostpassword" size="8" placeholder="Password">&nbsp;<input name="deletepost" value="Delete" type="submit">
</td>
</tr>
</tbody>
@ -671,6 +697,7 @@ function adminBar() {
function managePage($text, $onload = '') {
$adminbar = adminBar();
$txt_manage_mode = _('Manage mode');
$body = <<<EOF
<body$onload>
<div class="adminbar">
@ -681,7 +708,7 @@ EOF;
$body .= TINYIB_LOGO . TINYIB_BOARDDESC . <<<EOF
</div>
<hr width="90%">
<div class="replymode">Manage mode</div>
<div class="replymode">$txt_manage_mode</div>
$text
<hr>
EOF;
@ -702,13 +729,15 @@ function manageOnLoad($page) {
}
function manageLogInForm() {
$txt_login = _('Log In');
$txt_login_prompt = _('Enter an administrator or moderator password');
return <<<EOF
<form id="tinyib" name="tinyib" method="post" action="?manage">
<fieldset>
<legend align="center">Enter an administrator or moderator password</legend>
<legend align="center">$txt_login_prompt</legend>
<div class="login">
<input type="password" id="managepassword" name="managepassword"><br>
<input type="submit" value="Log In" class="managebutton">
<input type="submit" value="$txt_login" class="managebutton">
</div>
</fieldset>
</form>
@ -717,13 +746,19 @@ EOF;
}
function manageBanForm() {
$txt_ban = _('Ban an IP address');
$txt_ban_ip = _('IP Address:');
$txt_ban_expire = _('Expire(sec):');
$txt_ban_reason = _('Reason:');
$txt_ban_never = _('never');
$txt_ban_optional = _('optional');
return <<<EOF
<form id="tinyib" name="tinyib" method="post" action="?manage&bans">
<fieldset>
<legend>Ban an IP address</legend>
<label for="ip">IP Address:</label> <input type="text" name="ip" id="ip" value="${_GET['bans']}"> <input type="submit" value="Submit" class="managebutton"><br>
<label for="expire">Expire(sec):</label> <input type="text" name="expire" id="expire" value="0">&nbsp;&nbsp;<small><a href="#" onclick="document.tinyib.expire.value='3600';return false;">1hr</a>&nbsp;<a href="#" onclick="document.tinyib.expire.value='86400';return false;">1d</a>&nbsp;<a href="#" onclick="document.tinyib.expire.value='172800';return false;">2d</a>&nbsp;<a href="#" onclick="document.tinyib.expire.value='604800';return false;">1w</a>&nbsp;<a href="#" onclick="document.tinyib.expire.value='1209600';return false;">2w</a>&nbsp;<a href="#" onclick="document.tinyib.expire.value='2592000';return false;">30d</a>&nbsp;<a href="#" onclick="document.tinyib.expire.value='0';return false;">never</a></small><br>
<label for="reason">Reason:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</label> <input type="text" name="reason" id="reason">&nbsp;&nbsp;<small>optional</small>
<legend></legend>
<label for="ip">$txt_ban_ip</label> <input type="text" name="ip" id="ip" value="${_GET['bans']}"> <input type="submit" value="Submit" class="managebutton"><br>
<label for="expire">$txt_ban_expire</label> <input type="text" name="expire" id="expire" value="0">&nbsp;&nbsp;<small><a href="#" onclick="document.tinyib.expire.value='3600';return false;">1hr</a>&nbsp;<a href="#" onclick="document.tinyib.expire.value='86400';return false;">1d</a>&nbsp;<a href="#" onclick="document.tinyib.expire.value='172800';return false;">2d</a>&nbsp;<a href="#" onclick="document.tinyib.expire.value='604800';return false;">1w</a>&nbsp;<a href="#" onclick="document.tinyib.expire.value='1209600';return false;">2w</a>&nbsp;<a href="#" onclick="document.tinyib.expire.value='2592000';return false;">30d</a>&nbsp;<a href="#" onclick="document.tinyib.expire.value='0';return false;">$txt_ban_never</a></small><br>
<label for="reason">$txt_ban_reason&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</label> <input type="text" name="reason" id="reason">&nbsp;&nbsp;<small>$txt_ban_optional</small>
<legend>
</fieldset>
</form><br>
@ -734,11 +769,11 @@ function manageBansTable() {
$text = '';
$allbans = allBans();
if (count($allbans) > 0) {
$text .= '<table border="1"><tr><th>IP Address</th><th>Set At</th><th>Expires</th><th>Reason Provided</th><th>&nbsp;</th></tr>';
$text .= '<table border="1"><tr><th>' . _('IP Address') . '</th><th>' . _('Set At') . '</th><th>' . _('Expires') . '</th><th>' . _('Reason') . '</th><th>&nbsp;</th></tr>';
foreach ($allbans as $ban) {
$expire = ($ban['expire'] > 0) ? date('y/m/d(D)H:i:s', $ban['expire']) : 'Does not expire';
$expire = ($ban['expire'] > 0) ? date('y/m/d(D)H:i:s', $ban['expire']) : _('Does not expire');
$reason = ($ban['reason'] == '') ? '&nbsp;' : htmlentities($ban['reason']);
$text .= '<tr><td>' . $ban['ip'] . '</td><td>' . date('y/m/d(D)H:i:s', $ban['timestamp']) . '</td><td>' . $expire . '</td><td>' . $reason . '</td><td><a href="?manage&bans&lift=' . $ban['id'] . '">lift</a></td></tr>';
$text .= '<tr><td>' . $ban['ip'] . '</td><td>' . date('y/m/d(D)H:i:s', $ban['timestamp']) . '</td><td>' . $expire . '</td><td>' . $reason . '</td><td><a href="?manage&bans&lift=' . $ban['id'] . '">' . _('lift') . '</a></td></tr>';
}
$text .= '</table>';
}
@ -957,7 +992,7 @@ function encodeJSON($array) {
function buildSinglePostJSON($post) {
$name = $post['name'];
if ($name == '') {
$name = 'Anonymous';
$name = _('Anonymous');
}
$output = array('id' => $post['id'], 'parent' => $post['parent'], 'timestamp' => $post['timestamp'], 'bumped' => $post['bumped'], 'name' => $name, 'tripcode' => $post['tripcode'], 'subject' => $post['subject'], 'message' => $post['message'], 'file' => $post['file'], 'file_hex' => $post['file_hex'], 'file_original' => $post['file_original'], 'file_size' => $post['file_size'], 'file_size_formated' => $post['file_size_formatted'], 'image_width' => $post['image_width'], 'image_height' => $post['image_height'], 'thumb' => $post['thumb'], 'thumb_width' => $post['thumb_width'], 'thumb_height' => $post['thumb_height']);

434
locale/tinyib.pot Normal file
View File

@ -0,0 +1,434 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2020-08-28 16:18-0700\n"
"PO-Revision-Date: 2020-08-28 16:18-0700\n"
"Last-Translator: \n"
"Language-Team: \n"
"Language: en\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Generator: Poedit 2.3.1\n"
"X-Poedit-Basepath: ..\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Poedit-SearchPath-0: imgboard.php\n"
"X-Poedit-SearchPath-1: inc/html.php\n"
"X-Poedit-SearchPath-2: inc/functions.php\n"
#: imgboard.php:74
msgid "TINYIB_TRIPSEED and TINYIB_ADMINPASS must be configured."
msgstr ""
#: imgboard.php:78
msgid "TINYIB_RECAPTCHA_SITE and TINYIB_RECAPTCHA_SECRET must be configured."
msgstr ""
#: imgboard.php:88
#, php-format
msgid "Directory '%s' can not be written to. Please modify its permissions."
msgstr ""
#: imgboard.php:96
msgid "Unknown database mode specified."
msgstr ""
#: imgboard.php:111
msgid "Posting is currently disabled.<br>Please try again in a few moments."
msgstr ""
#: imgboard.php:130 inc/functions.php:387
msgid "Invalid parent thread ID supplied, unable to create post."
msgstr ""
#: imgboard.php:132
msgid "Replies are not allowed to locked threads."
msgstr ""
#: imgboard.php:169
msgid "Embedding a URL and uploading a file at the same time is not supported."
msgstr ""
#: imgboard.php:174
#, php-format
msgid "Invalid embed URL. Only %s URLs are supported."
msgstr ""
#: imgboard.php:194
msgid "Error while processing audio/video."
msgstr ""
#: imgboard.php:201 imgboard.php:301 imgboard.php:312
msgid "Could not create thumbnail."
msgstr ""
#: imgboard.php:217
msgid "File transfer failure. Please retry the submission."
msgstr ""
#: imgboard.php:221 inc/functions.php:413
#, php-format
msgid "That file is larger than %s."
msgstr ""
#: imgboard.php:236
msgid ""
"Failed to read the MIME type and size of the uploaded file. Please retry the "
"submission."
msgstr ""
#: imgboard.php:252
msgid "Could not copy uploaded file."
msgstr ""
#: imgboard.php:257
msgid "File transfer failure. Please go back and try again."
msgstr ""
#: imgboard.php:276
msgid "Sorry, your video appears to be corrupt."
msgstr ""
#: imgboard.php:336
#, php-format
msgid "A %s is required to start a thread."
msgstr ""
#: imgboard.php:349
#, php-format
msgid "%s uploaded."
msgstr ""
#: imgboard.php:354
#, php-format
msgid "Your %s will be shown <b>once it has been approved</b>."
msgstr ""
#: imgboard.php:367
msgid "Updating thread..."
msgstr ""
#: imgboard.php:380
msgid "Updating index..."
msgstr ""
#: imgboard.php:386
msgid "Tick the box next to a post and click \"Delete\" to delete it."
msgstr ""
#: imgboard.php:390
msgid ""
"Post deletion is currently disabled.<br>Please try again in a few moments."
msgstr ""
#: imgboard.php:407
msgid "Post deleted."
msgstr ""
#: imgboard.php:409
msgid "Invalid password."
msgstr ""
#: imgboard.php:412
msgid ""
"Sorry, an invalid post identifier was sent. Please go back, refresh the "
"page, and try again."
msgstr ""
#: imgboard.php:436
msgid "Rebuilt board."
msgstr ""
#: imgboard.php:444
msgid "Sorry, there is already a ban on record for that IP address."
msgstr ""
#: imgboard.php:453
#, php-format
msgid "Ban record added for %s"
msgstr ""
#: imgboard.php:459
#, php-format
msgid "Ban record lifted for %s"
msgstr ""
#: imgboard.php:551
#, php-format
msgid "Post No.%d deleted."
msgstr ""
#: imgboard.php:553 imgboard.php:569 imgboard.php:578 imgboard.php:593
#: imgboard.php:607
msgid "Sorry, there doesn't appear to be a post with that ID."
msgstr ""
#: imgboard.php:567
#, php-format
msgid "Post No.%d approved."
msgstr ""
#: imgboard.php:596 imgboard.php:610
msgid "Form data was lost. Please go back and try again."
msgstr ""
#: inc/functions.php:214 inc/html.php:995
msgid "Anonymous"
msgstr ""
#: inc/functions.php:323
msgid "Please enter the CAPTCHA text."
msgstr ""
#: inc/functions.php:325
msgid ""
"Incorrect CAPTCHA text entered. Please try again.<br>Click the image to "
"retrieve a new CAPTCHA."
msgstr ""
#: inc/functions.php:356
#, php-format
msgid ""
"Please shorten your message, or post it in multiple parts. Your message is "
"%1$d characters long, and the maximum allowed is %2$d."
msgstr ""
#: inc/functions.php:416
#, php-format
msgid ""
"The uploaded file exceeds the upload_max_filesize directive (%s) in php.ini."
msgstr ""
#: inc/functions.php:419
msgid "The uploaded file was only partially uploaded."
msgstr ""
#: inc/functions.php:422
msgid "No file was uploaded."
msgstr ""
#: inc/functions.php:425
msgid "Missing a temporary folder."
msgstr ""
#: inc/functions.php:428
msgid "Failed to write file to disk"
msgstr ""
#: inc/functions.php:431
msgid "Unable to save the uploaded file."
msgstr ""
#: inc/functions.php:439
#, php-format
msgid ""
"Duplicate file uploaded. That file has already been posted <a href=\"%s"
"\">here</a>."
msgstr ""
#: inc/functions.php:470
msgid ""
"Unable to read the uploaded file while creating its thumbnail. A common "
"cause for this is an incorrect extension when the file is actually of a "
"different type."
msgstr ""
#: inc/html.php:62
#, php-format
msgid "Supported file type is %s"
msgstr ""
#: inc/html.php:64
#, php-format
msgid "Supported file types are %s."
msgstr ""
#: inc/html.php:100
msgid "Reply to"
msgstr ""
#: inc/html.php:101
msgid "0 to start a new thread"
msgstr ""
#: inc/html.php:102
msgid ""
"Text entered in the Message field will be posted as is with no formatting "
"applied."
msgstr ""
#: inc/html.php:103
msgid "Line-breaks must be specified with \"&lt;br&gt;\"."
msgstr ""
#: inc/html.php:154
msgid "(enter the text below)"
msgstr ""
#: inc/html.php:158
msgid "CAPTCHA"
msgstr ""
#: inc/html.php:174
#, php-format
msgid "Maximum file size allowed is %s."
msgstr ""
#: inc/html.php:179
msgid "File"
msgstr ""
#: inc/html.php:193
msgid "Embed"
msgstr ""
#: inc/html.php:194
msgid "(paste a YouTube URL)"
msgstr ""
#: inc/html.php:218
#, php-format
msgid "Images greater than %s will be thumbnailed."
msgstr ""
#: inc/html.php:223
#, php-format
msgid "Currently %s unique user posts."
msgstr ""
#: inc/html.php:236
msgid "Name"
msgstr ""
#: inc/html.php:250
msgid "E-mail"
msgstr ""
#: inc/html.php:264
msgid "Subject"
msgstr ""
#: inc/html.php:278
msgid "Message"
msgstr ""
#: inc/html.php:297
msgid "Password"
msgstr ""
#: inc/html.php:298
msgid "(for post and file deletion)"
msgstr ""
#: inc/html.php:372
msgid "Embed:"
msgstr ""
#: inc/html.php:372
msgid "File:"
msgstr ""
#: inc/html.php:469
msgid "Reply"
msgstr ""
#: inc/html.php:475
msgid "Post truncated. Click Reply to view."
msgstr ""
#: inc/html.php:486
msgid "1 post omitted. Click Reply to view."
msgstr ""
#: inc/html.php:488
#, php-format
msgid "%d posts omitted. Click Reply to view."
msgstr ""
#: inc/html.php:504 inc/html.php:550
msgid "Catalog"
msgstr ""
#: inc/html.php:514
msgid "Previous"
msgstr ""
#: inc/html.php:527
msgid "Next"
msgstr ""
#: inc/html.php:552
msgid "Posting mode: Reply"
msgstr ""
#: inc/html.php:560
msgid "Manage"
msgstr ""
#: inc/html.php:561
msgid "Style"
msgstr ""
#: inc/html.php:562
msgid "Delete Post"
msgstr ""
#: inc/html.php:700
msgid "Manage mode"
msgstr ""
#: inc/html.php:732
msgid "Log In"
msgstr ""
#: inc/html.php:733
msgid "Enter an administrator or moderator password"
msgstr ""
#: inc/html.php:749
msgid "Ban an IP address"
msgstr ""
#: inc/html.php:750
msgid "IP Address:"
msgstr ""
#: inc/html.php:751
msgid "Expire(sec):"
msgstr ""
#: inc/html.php:752
msgid "Reason:"
msgstr ""
#: inc/html.php:753
msgid "never"
msgstr ""
#: inc/html.php:754
msgid "optional"
msgstr ""
#: inc/html.php:772
msgid "IP Address"
msgstr ""
#: inc/html.php:772
msgid "Set At"
msgstr ""
#: inc/html.php:772
msgid "Expires"
msgstr ""
#: inc/html.php:772
msgid "Reason"
msgstr ""
#: inc/html.php:774
msgid "Does not expire"
msgstr ""
#: inc/html.php:776
msgid "lift"
msgstr ""

View File

@ -11,6 +11,9 @@ See README for instructions on configuring, moderating and upgrading your board.
Set TINYIB_DBMODE to a MySQL-related mode if it's available. By default it's set to flatfile, which can be very slow.
*/
// Internationalization
define('TINYIB_LOCALE', ''); // Locale (see README for instructions)
// Administrator/moderator credentials
define('TINYIB_ADMINPASS', ''); // Administrators have full access to the board
define('TINYIB_MODPASS', ''); // Moderators only have access to delete (and moderate if TINYIB_REQMOD is set) posts ['' to disable]