TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,973
  • Latest: NonStop
Stats
  • Total Posts: 196,224
  • Total Topics: 21,352
  • Online today: 633
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 1
  • Guests: 170
  • Total: 171
  • @rjen

Can't find texts

Started by magnastik, October 17, 2006, 11:18:18 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

magnastik

Hi!
I've TP in 2 languages, English and Portuguese, but when i change from EN to PT this happens:



I can't find the missing vars or texts to translate them.. can anyone helpme on this?

I believe the code is this in "index.template.php"
// stats/personal/news
       echo '<table width="100%" cellpadding="0" cellspacing="0" style="background-color: #50535B" >
                    <tr>
                          <td class="pm_box" width="100%" valign="top">';

       if ($context['user']['is_logged']){
                // Only tell them about their messages if they can read their messages!
                if ($context['allow_pm'])
                        echo '<a href="', $scripturl, '?action=pm">'.$txt['bl22-pm'].': ', $context['user']['messages'], ' (', $context['user']['unread_messages']>0 ? '<span style="color: #ffa0a0;font-weight: bold;">'.$context['user']['unread_messages'].'</span>' : $context['user']['unread_messages'] ,')</a>';

                // Is the forum in maintenance mode?
                if ($context['user']['is_admin'])
                        echo '&nbsp;&nbsp;&nbsp;&nbsp;
                                                       '.$txt['bl22-maintenance'].':', $context['in_maintenance'] ? ' <span style="color: #ffa0a0;font-weight: bold;">ON</span>' : ' OFF';

                // Are there any members waiting for approval?
                if (!empty($context['unapproved_members']))
                        echo '&nbsp;&nbsp;&nbsp;&nbsp;
                                                        <a href="', $scripturl, '?action=viewmembers;sa=browse;type=approve">'.$txt['bl22-unapproved'].':', $context['unapproved_members'] , '</a>';

                // Show the total time logged in?
                if (!empty($context['user']['total_time_logged_in']))
                {
                        echo '&nbsp;&nbsp;&nbsp;&nbsp; '.$txt['bl22-loggedin'].': ';

                        // If days is just zero, don't bother to show it.
                        if ($context['user']['total_time_logged_in']['days'] > 0)
                                echo $context['user']['total_time_logged_in']['days'] . 'd ';

                        // Same with hours - only show it if it's above zero.
                        if ($context['user']['total_time_logged_in']['hours'] > 0)
                                echo $context['user']['total_time_logged_in']['hours'] . 'h ';

                        // But, let's always show minutes - Time wasted here: 0 minutes ;).
                        echo $context['user']['total_time_logged_in']['minutes'], 'm';
                }

                echo '&nbsp;&nbsp;&nbsp;&nbsp;<a href="', $scripturl, '?action=unread">'.$txt['bl22-unread'].'</a>
                   |  <a href="', $scripturl, '?action=unreadreplies">'.$txt['bl22-replies'].'</a>';

        }
        // Otherwise they're a guest - so politely ask them to register or login.
        else
        {
                echo '

<script language="JavaScript" type="text/javascript" src="', $settings['default_theme_url'], '/sha1.js"></script>

<form action="', $scripturl, '?action=login2" method="post" accept-charset="', $context['character_set'], '" class="middletext" style="margin: 3px 1ex 1px 0;"', empty($context['disable_login_hashing']) ? ' onsubmit="hashLoginPassword(this, \'' . $context['session_id'] . '\');"' : '', '>
<div style="text-align: right;">
<input type="text" name="user" size="10" /> <input type="password" name="passwrd" size="10" />
<select name="cookielength">
<option value="60">', $txt['smf53'], '</option>
<option value="1440">', $txt['smf47'], '</option>
<option value="10080">', $txt['smf48'], '</option>
<option value="43200">', $txt['smf49'], '</option>
<option value="-1" selected="selected">', $txt['smf50'], '</option>
</select>
<input type="submit" value="', $txt[34], '" /><br />
<span class="middletext">', $txt['smf52'], '</span>
<input type="hidden" name="hash_passwrd" value="" />
</div>
</form>';

        }


        if (!empty($context['user']['avatar']))
                echo '</td><td valign="top" rowspan="2">', $context['user']['avatar']['image'];
        // Show a random news item? (or you could pick one from news_lines...)


Cya,
MagNAstiK

feline

Inside your Themedir, you find a dir named "languages" and in this 2 files called "index.english.php" and  "Settings.english.php". These files must be translate, and give a name for your language, eg. index.YOURLANG.php

Fel

This website is proudly hosted on Crocweb Cloud Website Hosting.