Como posso ver as minhas ultimas mensagens

Started by Astra2000, June 08, 2006, 05:58:36 PM

Previous topic - Next topic

Astra2000

boas no forum anterior que eu tive tinha la um link que dizia:

Show unread posts since last visit.

e eu clicava la e mostrava as mensagens todas que eram colocadas desde a minha ultima visita.

mas neste meu forum não tenho isso...


www.tuga4u.com/forum

não tem la nada

ivogomes

Estás a usar o tema Classic que não tem essa funcionalidade. Podes mudar de tema ou copiar o código do tema Default que faz isso e incluir no Classic.
SMF Portuguese Translator
SMF 2.0 (100% translated)

http://www.ivogomes.com
http://www.portaldascuriosidades.com

Astra2000

Quote from: ivogomes on June 09, 2006, 04:01:25 AM
Estás a usar o tema Classic que não tem essa funcionalidade. Podes mudar de tema ou copiar o código do tema Default que faz isso e incluir no Classic.

Sabes qual é a parte do codigo que faz isso?

é que não precebo muito disso :-[

ivogomes

Aqui:

// If the user is logged in, display stuff like their name, new messages, etc.
if ($context['user']['is_logged'])
{
echo '
<a href="', $scripturl, '?action=unread">', $txt['unread_since_visit'], '</a> <br />
<a href="', $scripturl, '?action=unreadreplies">', $txt['show_unread_replies'], '</a><br />';

}
SMF Portuguese Translator
SMF 2.0 (100% translated)

http://www.ivogomes.com
http://www.portaldascuriosidades.com

Astra2000

#4
Quote from: ivogomes on June 09, 2006, 03:49:33 PM
Aqui:

// If the user is logged in, display stuff like their name, new messages, etc.
if ($context['user']['is_logged'])
{
echo '
<a href="', $scripturl, '?action=unread">', $txt['unread_since_visit'], '</a> <br />
<a href="', $scripturl, '?action=unreadreplies">', $txt['show_unread_replies'], '</a><br />';

}



boas ivo, esse codigo meto em que ficheiro?

Astra2000




Existe alguma maneira que meter isso naqueles pontinho vermelhos???

ivogomes

É tudo no index.template.php

Podes meter um <br /> a seguir ao echo.
SMF Portuguese Translator
SMF 2.0 (100% translated)

http://www.ivogomes.com
http://www.portaldascuriosidades.com

Astra2000

Quote from: ivogomes on June 18, 2006, 04:17:41 PM
É tudo no index.template.php

Podes meter um <br /> a seguir ao echo.


FDX Tu precebes desta merda a potes :o :o :o :o :D

Brgd Funcionou ;)

xxxx

olhem ja agora tambem cria saber como posso meter esses dois links direitos

xxxx


ivogomes

SMF Portuguese Translator
SMF 2.0 (100% translated)

http://www.ivogomes.com
http://www.portaldascuriosidades.com

xxxx


ivogomes

Por defeito eles já aparecem um debaixo do outro, mas se não estiver assim no teu fórum basta meter uma quebra de linha entre os dois: <br />
SMF Portuguese Translator
SMF 2.0 (100% translated)

http://www.ivogomes.com
http://www.portaldascuriosidades.com

Astra2000

#13
Boas IVO, estou com o mesmo problema... instalei o forum de novo na versão 1.11.1 e aconteceu-me o mesmo.. ja acrescentei o codigo, mas continua a não dar... repara bem:

Quote// The main sub template above the content.
function template_main_above()
{
   global $context, $settings, $options, $scripturl, $txt, $modSettings;

   // Show right to left and the character set for ease of translating.
   echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"';, $context['right_to_left'] ? ' dir="rtl"' : '', '><head>
   <meta http-equiv="Content-Type" content="text/html; charset=', $context['character_set'], '" />
   <meta name="description" content="', $context['page_title'], '" />', empty($context['robot_no_index']) ? '' : '
   <meta name="robots" content="noindex" />', '
   <meta name="keywords" content="PHP, MySQL, bulletin, board, free, open, source, smf, simple, machines, forum" />
   <script language="JavaScript" type="text/javascript" src="', $settings['default_theme_url'], '/script.js?fin11"></script>
   <script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
      var smf_theme_url = "', $settings['theme_url'], '";
      var smf_images_url = "', $settings['images_url'], '";
      var smf_scripturl = "', $scripturl, '";
      var smf_iso_case_folding = ', $context['server']['iso_case_folding'] ? 'true' : 'false', ';
      var smf_charset = "', $context['character_set'], '";
   // ]]></script>
   <title>', $context['page_title'], '</title>
   <link rel="stylesheet" type="text/css" href="', $settings['theme_url'], '/style.css?fin11" />
   <link rel="stylesheet" type="text/css" href="', $settings['default_theme_url'], '/print.css?fin11" media="print" />';

   /* Internet Explorer 4/5 and Opera 6 just don't do font sizes properly. (they are big...)
      Thus, in Internet Explorer 4, 5, and Opera 6 this will show fonts one size smaller than usual.
      Note that this is affected by whether IE 6 is in standards compliance mode.. if not, it will also be big.
      Standards compliance mode happens when you use xhtml... */
   if ($context['browser']['needs_size_fix'])
      echo '
   <link rel="stylesheet" type="text/css" href="', $settings['default_theme_url'], '/fonts-compat.css" />';

   // Show all the relative links, such as help, search, contents, and the like.
   echo '
   <link rel="help" href="', $scripturl, '?action=help" target="_blank" />
   <link rel="search" href="' . $scripturl . '?action=search" />
   <link rel="contents" href="', $scripturl, '" />';

   // If RSS feeds are enabled, advertise the presence of one.
   if (!empty($modSettings['xmlnews_enable']))
      echo '
   <link rel="alternate" type="application/rss+xml" title="', $context['forum_name'], ' - RSS" href="', $scripturl, '?type=rss;action=.xml" />';

   // If we're viewing a topic, these should be the previous and next topics, respectively.
   if (!empty($context['current_topic']))
      echo '
   <link rel="prev" href="', $scripturl, '?topic=', $context['current_topic'], '.0;prev_next=prev" />
   <link rel="next" href="', $scripturl, '?topic=', $context['current_topic'], '.0;prev_next=next" />';

   // If we're in a board, or a topic for that matter, the index will be the board's index.
   if (!empty($context['current_board']))
      echo '
   <link rel="index" href="' . $scripturl . '?board=' . $context['current_board'] . '.0" />';

   // Output any remaining HTML headers. (from mods, maybe?)
   echo $context['html_headers'], '
</head>
<body>';

   // The logo, user information, news, and menu.
   echo '
   <table cellspacing="0" cellpadding="0" border="0" align="center" width="95%" class="tborder">
      <tr style="background-color: #ffffff;">
         <td valign="middle" align="left"><img src="', !empty($settings['header_logo_url']) ? $settings['header_logo_url'] : $settings['images_url'] . '/smflogo.gif', '" alt="" /></td>
         <td valign="middle">';


// If the user is logged in, display stuff like their name, new messages, etc.
   if ($context['user']['is_logged'])
   {
      echo '
            ', $txt['hello_member'], ' <b>', $context['user']['name'], '</b>', $context['allow_pm'] ? ', ' . $txt[152] . ' <a href="' . $scripturl . '?action=pm">' . $context['user']['messages'] . ' ' . ($context['user']['messages'] != 1 ? $txt[153] : $txt[471]) . '</a>' . $txt['newmessages4'] . ' ' . $context['user']['unread_messages'] . ' ' . ($context['user']['unread_messages'] == 1 ? $txt['newmessages0'] : $txt['newmessages1']) : '', '.';


      // Are there any members waiting for approval?
      if (!empty($context['unapproved_members']))
         echo '<br />
            ', $context['unapproved_members'] == 1 ? $txt['approve_thereis'] : $txt['approve_thereare'], ' <a href="', $scripturl, '?action=viewmembers;sa=browse;type=approve">', $context['unapproved_members'] == 1 ? $txt['approve_member'] : $context['unapproved_members'] . ' ' . $txt['approve_members'], '</a> ', $txt['approve_members_waiting'];

      // Is the forum in maintenance mode?
      if ($context['in_maintenance'] && $context['user']['is_admin'])
         echo '<br />
            <b>', $txt[616], '</b>';
   }
   // Otherwise they're a guest - so politely ask them to register or login.
   else
      echo '
            ', $txt['welcome_guest'];

   echo '
            <br />', $context['current_time'], '
         </td>
      </tr>
      <tr class="windowbg2">
         <td colspan="2" valign="middle" align="center" class="tborder" style="border-width: 1px 0 0 0; font-size: smaller;">';

   // Show the menu here, according to the menu sub template.
   template_menu();

   echo '
         </td>
      </tr>';

   // Show a random news item? (or you could pick one from news_lines...)
   if (!empty($settings['enable_news']))
      echo '
      <tr class="windowbg2">
         <td colspan="2" height="24" class="tborder" style="border-width: 1px 0 0 0; padding-left: 1ex;">
            <b>', $txt[102], ':</b> ', $context['random_news_line'], '
         </td>
      </tr>';

   echo '
   </table>

   <br />
   <table cellspacing="0" cellpadding="10" border="0" align="center" width="95%" class="tborder">
      <tr><td valign="top" style="background-color: #ffffff;">';
}
// If the user is logged in, display stuff like their name, new messages, etc.
   if ($context['user']['is_logged'])
   {
      echo '
                        <a href="', $scripturl, '?action=unread">', $txt['unread_since_visit'], '</a> <br />
                        <a href="', $scripturl, '?action=unreadreplies">', $txt['show_unread_replies'], '</a><br />';

margarett

Tiras isto do fim:
// If the user is logged in, display stuff like their name, new messages, etc.
   if ($context['user']['is_logged'])
   {
      echo '
                        <a href="', $scripturl, '?action=unread">', $txt['unread_since_visit'], '</a> <br />
                        <a href="', $scripturl, '?action=unreadreplies">', $txt['show_unread_replies'], '</a><br />';


E colocas mais acima isto:
// If the user is logged in, display stuff like their name, new messages, etc.
   if ($context['user']['is_logged'])
   {
      echo '
            ', $txt['hello_member'], ' <b>', $context['user']['name'], '</b>', $context['allow_pm'] ? ', ' . $txt[152] . ' <a href="' . $scripturl . '?action=pm">' . $context['user']['messages'] . ' ' . ($context['user']['messages'] != 1 ? $txt[153] : $txt[471]) . '</a>' . $txt['newmessages4'] . ' ' . $context['user']['unread_messages'] . ' ' . ($context['user']['unread_messages'] == 1 ? $txt['newmessages0'] : $txt['newmessages1']) : '', '.';


Assim:
// If the user is logged in, display stuff like their name, new messages, etc.
   if ($context['user']['is_logged'])
   {
      echo '
            ', $txt['hello_member'], ' <b>', $context['user']['name'], '</b>', $context['allow_pm'] ? ', ' . $txt[152] . ' <a href="' . $scripturl . '?action=pm">' . $context['user']['messages'] . ' ' . ($context['user']['messages'] != 1 ? $txt[153] : $txt[471]) . '</a> <br> />
<a href="', $scripturl, '?action=unread">', $txt['unread_since_visit'], '</a> <br />
<a href="', $scripturl, '?action=unreadreplies">', $txt['show_unread_replies'], '</a>';


Não testei, mas deve ser qualquer coisa à volta disto...
Se forem conduzir, não bebam. Se forem beber... CHAMEM-ME!!!! :D

QuoteOver 90% of all computer problems can be traced back to the interface between the keyboard and the chair

Astra2000

esqueci-me de agradecer, Brgd pessoal, voltei aqui agora pq estava com este mesmo problema.. ja resolvi ;)

BRGD :)

Advertisement: