<div class="linkst"> <div class="inbox"> <ul class="crumbs"> <li><a href="accueil"><?php echo $lang_common['Index']; ?> </a></li> <li><span>» </span><a href="<?php echo fluxrewrite($cur_post['fid'], $cur_post['forum_name'], 'f', false, false, false); ?> "><?php echo pun_htmlspecialchars($cur_post['forum_name']); ?> </a></li> <li><span>» </span><a href="<?php echo fluxrewrite($cur_post['tid'], $cur_post['subject'], 't', false, false, false); ?> "><?php echo pun_htmlspecialchars($cur_post['subject']); ?> </a></li> <li><span>» </span><strong><?php echo $lang_delete['Delete post']; ?> </strong></li> </ul> </div> </div> <div class="blockform"> <h2><span><?php
?> </div> <ul class="crumbs"> <li><a href="accueil"><?php echo $lang_common['Index']; ?> </a></li> <li><span>» </span><a href="<?php echo fluxrewrite($cur_topic['forum_id'], $cur_topic['forum_name'], 'f', false, false, false); ?> "><?php echo pun_htmlspecialchars($cur_topic['forum_name']); ?> </a></li> <li><span>» </span><strong><a href="<?php echo fluxrewrite($id, $cur_topic['subject'], 't', false, false, false); ?> "><?php echo pun_htmlspecialchars($cur_topic['subject']); ?> </a></strong></li> </ul> <?php echo $subscraction; ?> <div class="clearer"></div> </div> </div> <?php // Display quick post if enabled
$forum_field = '<h3><span class="redirtext">' . $lang_index['Link to'] . '</span> <a href="' . pun_htmlspecialchars($cur_forum['redirect_url']) . '" title="' . $lang_index['Link to'] . ' ' . pun_htmlspecialchars($cur_forum['redirect_url']) . '">' . pun_htmlspecialchars($cur_forum['forum_name']) . '</a></h3>'; $num_topics = $num_posts = '-'; $item_status .= ' iredirect'; $icon_type = 'icon'; } else { $forum_field = '<h3><a href="' . fluxrewrite($cur_forum['fid'], $cur_forum['forum_name'], 'f', false, false, false) . '">' . pun_htmlspecialchars($cur_forum['forum_name']) . '</a>' . (!empty($forum_field_new) ? ' ' . $forum_field_new : '') . '</h3>'; $num_topics = $cur_forum['num_topics']; $num_posts = $cur_forum['num_posts']; } if ($cur_forum['forum_desc'] != '') { $forum_field .= "\n\t\t\t\t\t\t\t\t" . '<div class="forumdesc">' . $cur_forum['forum_desc'] . '</div>'; } // If there is a last_post/last_poster if ($cur_forum['last_post'] != '') { $num_pages_topic = ceil(($cur_forum['num_replies'] + 1) / $pun_user['disp_posts']); $last_post = '<a href="' . fluxrewrite($cur_forum['last_topic_id'], $cur_forum['last_topic'], 't', $num_pages_topic, false, $cur_forum['last_post_id']) . '">' . format_time($cur_forum['last_post']) . '</a> <span class="byuser">' . $lang_common['by'] . ' ' . pun_htmlspecialchars($cur_forum['last_poster']) . '</span>'; } else { if ($cur_forum['redirect_url'] != '') { $last_post = '- - -'; } else { $last_post = $lang_common['Never']; } } if ($cur_forum['moderators'] != '') { $mods_array = unserialize($cur_forum['moderators']); $moderators = array(); foreach ($mods_array as $mod_username => $mod_id) { if ($pun_user['g_view_users'] == '1') { $moderators[] = '<a href="membre-' . $mod_id . '">' . pun_htmlspecialchars($mod_username) . '</a>'; } else { $moderators[] = pun_htmlspecialchars($mod_username);
echo pun_htmlspecialchars($cur_posting['forum_name']); ?> </a></li> <?php if (isset($_POST['req_subject'])) { ?> <li><span>» </span><?php echo pun_htmlspecialchars($_POST['req_subject']); ?> </li> <?php } if (isset($cur_posting['subject'])) { ?> <li><span>» </span><a href="<?php echo fluxrewrite($tid, $cur_posting['subject'], 't', false, false, false); ?> "><?php echo pun_htmlspecialchars($cur_posting['subject']); ?> </a></li> <?php } ?> <li><span>» </span><strong><?php echo $action; ?> </strong></li> </ul> </div> </div>
<div class="pagepost"> <p class="pagelink conl"><?php echo $paging_links; ?> </p> <?php echo $post_link; ?> </div> <ul class="crumbs"> <li><a href="accueil"><?php echo $lang_common['Index']; ?> </a></li> <li><span>» </span><strong><a href="<?php echo fluxrewrite($id, $cur_forum['forum_name'], 'f', false, false, false); ?> "><?php echo pun_htmlspecialchars($cur_forum['forum_name']); ?> </strong></a></li> </ul> <?php echo !empty($forum_actions) ? "\t\t" . '<p class="subscribelink clearb">' . implode(' - ', $forum_actions) . '</p>' . "\n" : ''; ?> <div class="clearer"></div> </div> </div> <?php $forum_id = $id; $footer_style = 'viewforum';
$generator->addUrl(get_base_url() . '/', time(), null, '1.0'); // Output the data for the forums $result = $db->query('SELECT f.id as forum_id, f.forum_name, last_post, num_topics FROM ' . $db->prefix . 'forums AS f LEFT JOIN ' . $db->prefix . 'forum_perms AS fp ON (fp.forum_id=f.id AND fp.group_id=3) WHERE fp.read_forum IS NULL OR fp.read_forum=1 ORDER BY f.id DESC') or error('Unable to fetch forum list', __FILE__, __LINE__, $db->error()); while ($cur_forum = $db->fetch_assoc($result)) { $generator->addUrl(get_base_url() . '/' . fluxrewrite("forum-", $cur_forum['forum_id'], $cur_forum['forum_name'], 1, false, false), $cur_forum['last_post'], null, '0.5'); $num_pages = ceil($cur_forum['num_topics'] / $pun_config['o_disp_topics_default']); // Add page number for subsequent pages for ($i = 2; $i <= $num_pages; ++$i) { $generator->addUrl(get_base_url() . '/forum-' . $cur_forum['forum_id'] . '-' . clean_url($cur_forum['forum_name']) . '-page-' . $i . '.html', $cur_forum['last_post'], null, '0.5'); } } // Output the data for the topics $result = $db->query('SELECT t.id as topic_id, t.subject, last_post, sticky, num_replies FROM ' . $db->prefix . 'topics AS t LEFT JOIN ' . $db->prefix . 'forum_perms AS fp ON (fp.forum_id=t.forum_id AND fp.group_id=3) WHERE (fp.read_forum IS NULL OR fp.read_forum=1) AND t.moved_to IS NULL ORDER BY last_post DESC') or error('Unable to fetch topic list', __FILE__, __LINE__, $db->error()); while ($cur_topic = $db->fetch_assoc($result)) { $priority = $cur_topic['sticky'] == '1' ? '1.0' : '0.75'; $generator->addUrl(get_base_url() . '/' . fluxrewrite("topic-", $cur_topic['topic_id'], $cur_topic['subject'], 1, false, false), $cur_topic['last_post'], null, $priority); // We add one because the first post is not counted as a reply but needs to be taken into account for display $num_pages = ceil(($cur_topic['num_replies'] + 1) / $pun_config['o_disp_posts_default']); for ($i = 2; $i <= $num_pages; ++$i) { $generator->addUrl(get_base_url() . '/topic-' . $cur_topic['topic_id'] . '-' . clean_url($cur_topic['subject']) . '-page-' . $i . '.html', $cur_topic['last_post'], null, $priority); } } $generator->completeSitemap(); abstract class SitemapGenerator { protected function beginSitemap() { global $pun_config; $output = '<?xml version="1.0" encoding="UTF-8"?>' . "\n"; $output .= '<?xml-stylesheet type="text/xsl" href="' . get_base_url() . '/sitemap.xsl"?>' . "\n"; $output .= '<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">' . "\n";