Voici les modifs pour le mod phpBB3 portal v1.2.2 de ce site : http://www.phpbb3portal.com/download/
Il doit fonctionner avec le mod Ultimate SEO URL (tous les modes).
Ouvrir :
- Code: Tout sélectionner
portal/block/recent.php
Trouver:
- Code: Tout sélectionner
//
// Recent announcements
//
$sql = 'SELECT topic_title, forum_id, topic_id
Remplacer par :
- Code: Tout sélectionner
//
// Recent announcements
//
$sql = 'SELECT *
Trouver :
- Code: Tout sélectionner
// auto auth
if ( ($auth->acl_get('f_read', $row['forum_id'])) || ($row['forum_id'] == '0') )
{
Ajouter après :
- Code: Tout sélectionner
// www.phpBB-SEO.com SEO TOOLKIT BEGIN
$row['topic_title'] = censor_text($row['topic_title']);
$phpbb_seo->prepare_iurl($row, 'topic', $phpbb_seo->seo_static['global_announce']);
// www.phpBB-SEO.com SEO TOOLKIT END
Trouver :
- Code: Tout sélectionner
//
// Recent hot topics
//
$sql = 'SELECT topic_title, forum_id, topic_id
Remplacer par :
- Code: Tout sélectionner
//
// Recent hot topics
//
$sql = 'SELECT *
Trouver :
- Code: Tout sélectionner
// auto auth
if ( ($auth->acl_get('f_read', $row['forum_id'])) || ($row['forum_id'] == '0') )
{
Ajouter après :
- Code: Tout sélectionner
// www.phpBB-SEO.com SEO TOOLKIT BEGIN
$row['topic_title'] = censor_text($row['topic_title']);
// Since we don't have the forum_name available here, we need to make sure that we can rewrite
if (!empty($row['topic_url']) || $row['topic_type'] == POST_GLOBAL || !empty($phpbb_seo->seo_url['forum'][$row['forum_id']])) {
$phpbb_seo->prepare_iurl($row, 'topic', $row['topic_type'] == POST_GLOBAL ? $phpbb_seo->seo_static['global_announce'] : $phpbb_seo->seo_url['forum'][$row['forum_id']]);
}
// www.phpBB-SEO.com SEO TOOLKIT END
Trouver :
- Code: Tout sélectionner
//
// Recent topic (only show normal topic)
//
$sql = 'SELECT topic_title, forum_id, topic_id
Remplacer par :
- Code: Tout sélectionner
//
// Recent topic (only show normal topic)
//
$sql = 'SELECT *
Trouver :
- Code: Tout sélectionner
// auto auth
if ( ($auth->acl_get('f_read', $row['forum_id'])) || ($row['forum_id'] == '0') )
{
Ajouter après :
- Code: Tout sélectionner
// www.phpBB-SEO.com SEO TOOLKIT BEGIN
$row['topic_title'] = censor_text($row['topic_title']);
// Since we don't have the forum_name available here, we need to make sure that we can rewrite
if (!empty($row['topic_url']) || !empty($phpbb_seo->seo_url['forum'][$row['forum_id']])) {
$phpbb_seo->prepare_iurl($row, 'topic', $phpbb_seo->seo_url['forum'][$row['forum_id']]);
}
// www.phpBB-SEO.com SEO TOOLKIT END
Nota bene :
- Vous pouvez en plus remplacer tous les :
- Code: Tout sélectionner
'FULL_TITLE' => censor_text($row['topic_title']),
- Par :
- Code: Tout sélectionner
'FULL_TITLE' => $row['topic_title'],
svu que l'on passe déjà le titre du sujet par la censure, et que de plus, le mod ne le fait pas au départ pour les titres raccourcis.
Ouvrir :
- Code: Tout sélectionner
portal/includes/functions.php
Trouver :
- Code: Tout sélectionner
function phpbb_fetch_posts($forum_sql, $number_of_posts, $text_length, $time, $type)
{
global $db, $phpbb_root_path, $auth, $bbcode_bitfield, $user, $forum_id;
Ajouter après :
- Code: Tout sélectionner
// www.phpBB-SEO.com SEO TOOLKIT BEGIN
global $phpbb_seo;
// www.phpBB-SEO.com SEO TOOLKIT END
Trouver :
- Code: Tout sélectionner
$sql = 'SELECT
t.forum_id,
t.topic_id,
t.topic_last_post_id,
t.topic_time,
t.topic_title,
t.topic_attachment,
t.topic_views,
t.poll_title,
t.topic_replies,
t.forum_id,
t.topic_poster,
Remplacer par :
- Code: Tout sélectionner
$sql = 'SELECT
t.*,
Trouver :
- Code: Tout sélectionner
if ( ($auth->acl_get('f_read', $row['forum_id'])) || ($row['forum_id'] == '0') )
{
Ajouter après :
- Code: Tout sélectionner
// www.phpBB-SEO.com SEO TOOLKIT BEGIN
$row['topic_title'] = censor_text($row['topic_title']);
if (!empty($row['topic_url']) || $row['topic_type'] == POST_GLOBAL || !empty($phpbb_seo->seo_url['forum'][$row['forum_id']])) {
$phpbb_seo->prepare_iurl($row, 'topic', $row['topic_type'] == POST_GLOBAL ? $phpbb_seo->seo_static['global_announce'] : $phpbb_seo->seo_url['forum'][$row['forum_id']]);
}
// www.phpBB-SEO.com SEO TOOLKIT END

Français |
Anglais
