Ultimos 5 Temas en Index.
Publicado: 01 Oct 2004, 10:11
He instalado este mod:
Todo perfecto y sale bien, lo podeis ver en www.madelmanhouse.com/foroplus/index.php , como veis los titulos de los ultimos temas salen uno detras de otro y me gustaria que saliesen uno debajo de otro. Lo he intendado yo, pero no logro nada.
Código: Seleccionar todo
##############################################################
##
## MOD Title: Topics On Index
##
## MOD Author: aUsTiN => austin_inc@hotmail.com
##
## MOD Description: Adds the last 5 topics posted in, to your forum rows on index.php
##
## MOD Version: 1.0.0
##
## MOD Help: http://phpbb-amod.com/
##
## Installation Level: Easy
##
## Installation Time: 5 Minutes
##
## Files To Edit: 2
##
## Included Files: 0
##
##############################################################
##############################################################
##
## Author Notes:
##
## Copyright í?Â?í?Â?í?Â?í?Â?í?Â?í?Â?í?Â?í?© aUsTiN-Inc, 2003/4
##
## If you add anything or want anything added, please visit
## http://phpbb-amod.com/
##
## ALL FILES WERE DOWNLOADED DIRECTLY FROM MY SITE TO BUILD THIS INSTALL.
##
## Feel free to see it in action at http://phpbb-amod.com/
##
##
## If you cant use phpMyAdmin for the SQL, there is a DB Generator available at
## http://phpbb-amod.com/db_generator.php for you to use. Enjoy.
##
##############################################################
##
## MOD History:
##
## Sep 25th 2004 - Version 1.0.0
## - Released
##
##############################################################
##
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##
##############################################################
##
## Definitions:
##
## Root: Folder your config.php is located
## templates/*/: Your template folder (All template folders are suggested)
## lang_*/: Your current language folder (All lang folders are suggested)
##
##############################################################
-----------------------------------
----[ OPEN ]-----------------------
-----------------------------------
Root/index.php
-----------------------------------
----[ FIND ]-----------------------
-----------------------------------
//
// Okay, let's build the index
//
for($i = 0; $i sql_query($q);
$topic_rows = $db -> sql_fetchrowset($r);
$topic_tot = count($topic_rows);
$c = 0;
#
#= End Topics In Forum Row By aUsTiN ============
#================================================
-----------------------------------
----[ FIND ]-----------------------
-----------------------------------
'U_VIEWFORUM' => append_sid("viewforum.$phpEx?" . POST_FORUM_URL . "=$forum_id"))
);
-----------------------------------
----[ ADD, AFTER ]-----------------
-----------------------------------
#================================================
#= Start Topics In Forum Row By aUsTiN ==========
#
for($t = 0; $t $Max)
{
$new_t_name = substr($topic_rows[$t]['topic_title'], 0 , ($Max - 3)). "...";
}
else
{
$new_t_name = $topic_rows[$t]['topic_title'];
}
$template->assign_block_vars('catrow.forumrow.newest_topics', array(
'NEWEST_5_TOPICS' => " ". $new_t_name ."")
);
$c++;
}
}
#
#= End Topics In Forum Row By aUsTiN ============
#================================================
-----------------------------------
----[ FIND ]-----------------------
-----------------------------------
}
}
}
} // for ... categories
}// if ... total_categories
else
-----------------------------------
----[ ADD, BEFORE ]----------------
-----------------------------------
#================================================
#= Start Topics In Forum Row By aUsTiN ==========
#
$c = 0;
#
#= End Topics In Forum Row By aUsTiN ============
#================================================
-----------------------------------
----[ CLOSE & SAVE ]---------------
-----------------------------------
-----------------------------------
----[ OPEN ]-----------------------
-----------------------------------
Root/templates/*/index_body.tpl
-----------------------------------
----[ FIND ]-----------------------
-----------------------------------
{catrow.forumrow.FORUM_DESC}
-----------------------------------
----[ ADD, AFTER ]-----------------
-----------------------------------
{catrow.forumrow.newest_topics.NEWEST_5_TOPICS}
-----------------------------------
----[ CLOSE & SAVE ]---------------
-----------------------------------
EoM