quelqu'un sait où trouver ou comment adapter ce mod à phpBB3 ? j'ai cherché ce mod dans phpbb.com mais il semble qu'il est abondonné par son auteur ( dommage ... )
voila les instructions du mod pour phpBB2 :
dans viewforum.php
- Code: Tout sélectionner
#
#-----[ FIND ]------------------------------------------
#
if( $total_topics )
{
#
#-----[ AFTER, ADD ]------------------------------------
#
//words surronded by brackets []
$type = "<span style=\"background-color:white;color:green;border:green 1px solid\">";
$search_type = "#(\[.*?\])(.*)#";
$end_style = "</span>";
//Propositions, surronded by asteriscs *
$propositions = "<span style=\"background-color:white;color:red;border:red 1px solid\">";
$search_propositions = "#(\*.*?\*)(.*)#";
//Important Announces, starting by vertical bar |
$notifications = "<span style=\"background-color:white;color:blue;border:blue 1px solid\">";
$search_notifications = "#(\|.*?\|)#";
//News, starting by sharp #
$news = "<span style=\"background-color:darkblue;color:white;border:white 1px solid\">";
$search_news = "#(\#.*?\#)(.*)#";
$end_style = "</span>";
#
#-----[ FIND ]------------------------------------------
#
$topic_title = ( count($orig_word) ) ? preg_replace($orig_word, $replacement_word, $topic_rowset[$i]['topic_title']) : $topic_rowset[$i]['topic_title'];
#
#-----[ AFTER, ADD ]------------------------------------
#
$replace = $topic_title;
//words surronded by brackets []
if ( $replace == $topic_title )
{
$replace = preg_replace( $search_type, $type . "\${1}" . $end_style . "\${2}", $topic_title );
$replace = ereg_replace("$type\[","$type ",$replace);
$replace = ereg_replace("\]$end_style"," $end_style",$replace);
}
//Propositions, surronded by asteriscs *
if ( $replace == $topic_title )
{
$replace = preg_replace( $search_propositions, $propositions . "\${1}" . $end_style . "\${2}", $topic_title );
$replace = ereg_replace("$propositions\*","$propositions ",$replace);
$replace = ereg_replace("\*$end_style"," $end_style",$replace);
}
//Important Announces, starting by vertical bar |
if ( $replace == $topic_title )
{
$replace = preg_replace( $search_notifications, $notifications . "\${1}" . $end_style . "\${2}", $topic_title );
$replace = ereg_replace("$notifications\|","$notifications ",$replace);
$replace = ereg_replace("\|$end_style"," $end_style",$replace);
}
//News, starting by sharp #
if ( $replace == $topic_title )
{
$replace = preg_replace( $search_news, $news . "\${1}" . $end_style . "\${2}", $topic_title );
$replace = ereg_replace("$news#","$news ",$replace);
$replace = ereg_replace("#$end_style"," $end_style",$replace);
}
$topic_title = $replace;
merci d'avance pour votre aide








Mon blogue: 

