Topic: Help with my active topics list.

I use a modified version of portal by daris active topics. but i have a small problem in it. can some one please help.

Here is image of the Problem and explanation: http://i42.tinypic.com/2udxpg8.png
Here is the Site: http://sports2all.com/forum/

http://i42.tinypic.com/2udxpg8.png

Code:

<?php

/***********************************************************************



    PunBB extension

    Portal

    Daris <daris91@gmail.com>



************************************************************************/





// Make sure no one attempts to run this script "directly"

if (!defined('FORUM'))

    exit;



$count = 15; // active topics count

$cur_panel['class'] = 'forum';



// Load the viewforum.php language file

require_once FORUM_ROOT.'lang/'.$forum_user['language'].'/forum.php';

require_once FORUM_ROOT.'lang/'.$forum_user['language'].'/search.php';



// Fetch list of topics

$query = array(

    'SELECT'    => 't.id, t.poster, t.subject, t.posted, t.first_post_id, t.last_post, t.last_post_id, t.last_poster, t.num_views, t.num_replies, t.closed, t.sticky, t.moved_to, t.forum_id',

    'FROM'        => 'topics AS t',

    'JOINS'        => array(

        array(

            'LEFT JOIN'         => 'forums as f',

            'ON'            => 't.forum_id=f.id'

        ),

        array(

            'LEFT JOIN'        => 'forum_perms AS fp',

            'ON'            => '(fp.forum_id=t.forum_id AND fp.group_id='.$forum_user['g_id'].')'

        )

    ),

    'WHERE'        => '(fp.read_forum IS NULL OR fp.read_forum=1) AND t.moved_to IS NULL',

    'ORDER BY'    => 't.last_post DESC',

    'LIMIT'        => '0, '.$count

);



// With "has posted" indication

if (!$forum_user['is_guest'] && $forum_config['o_show_dot'] == '1')

{

    $subquery = array(

        'SELECT'    => 'COUNT(p.id)',

        'FROM'        => 'posts AS p',

        'WHERE'        => 'p.poster_id='.$forum_user['id'].' AND p.topic_id=t.id'

    );



    ($hook = get_hook('xn_portal_by_daris_at_qr_get_has_posted')) ? eval($hook) : null;

    $query['SELECT'] .= ', ('.$forum_db->query_build($subquery, true).') AS has_posted';

}



($hook = get_hook('xn_portal_by_daris_at_qr_get_topics')) ? eval($hook) : null;

$result_at = $forum_db->query_build($query) or error(__FILE__, __LINE__);



// Get topic/forum tracking data

if (!$forum_user['is_guest'])

    $tracked_topics = get_tracked_topics();





($hook = get_hook('xn_portal_by_daris_at_pre_header_load')) ? eval($hook) : null;





$forum_page['item_header'] = array();

$forum_page['item_header']['subject']['title'] = '<strong class="subject-title">'.$lang_forum['Topics'].'</strong>';

$forum_page['item_header']['info']['replies'] = '<strong class="info-replies">'.$lang_forum['replies'].'</strong>';



if ($forum_config['o_topic_views'] == '1')

    $forum_page['item_header']['info']['views'] = '<strong class="info-views">'.$lang_forum['views'].'</strong>';



$forum_page['item_header']['info']['lastpost'] = '<strong class="info-lastpost">'.$lang_forum['last post'].'</strong>';



($hook = get_hook('xn_portal_by_daris_at_main_output_start')) ? eval($hook) : null;



// If there are topics in this forum

if ($forum_db->num_rows($result_at))

{



?>

    <div class="main-subhead">

        <p class="item-summary<?php echo ($forum_config['o_topic_views'] == '1') ? ' forum-views' : ' forum-noview' ?>"><span><?php printf($lang_forum['Forum subtitle'], implode(' ', $forum_page['item_header']['subject']), implode(', ', $forum_page['item_header']['info'])) ?></span></p>

    </div>

    <div id="forum" class="main-content main-forum<?php echo ($forum_config['o_topic_views'] == '1') ? ' forum-views' : ' forum-noview' ?>">

<?php



    ($hook = get_hook('xn_portal_by_daris_at_pre_topic_loop_start')) ? eval($hook) : null;



    $forum_page['item_count'] = 0;



    while ($cur_topic = $forum_db->fetch_assoc($result_at))

    {

        ($hook = get_hook('xn_portal_by_daris_at_topic_loop_start')) ? eval($hook) : null;



        ++$forum_page['item_count'];



        // Start from scratch

        $forum_page['item_subject'] = $forum_page['item_body'] = $forum_page['item_status'] = $forum_page['item_nav'] = $forum_page['item_title'] = $forum_page['item_title_status'] = array();

        $forum_page['item_indicator'] = '';



        if ($forum_config['o_censoring'] == '1')

            $cur_topic['subject'] = censor_words($cur_topic['subject']);



        if ($cur_topic['moved_to'] != null)

        {

            $forum_page['item_status']['moved'] = 'moved';

            $forum_page['item_title']['link'] = '<span class="item-status"><em class="moved">'.sprintf($lang_forum['Item status'], $lang_forum['Moved']).'</em></span> <a href="'.forum_link($forum_url['topic'], array($cur_topic['moved_to'], sef_friendly($cur_topic['subject']))).'">'.forum_htmlencode($cur_topic['subject']).'</a>';



            // Combine everything to produce the Topic heading

            $forum_page['item_body']['subject']['title'] = '<h3 class="hn"><span class="item-num">'.forum_number_format($forum_page['start_from'] + $forum_page['item_count']).'</span>'.$forum_page['item_title']['link'].'</h3>';



            ($hook = get_hook('xn_portal_by_daris_at_topic_loop_moved_topic_pre_item_subject_merge')) ? eval($hook) : null;



            if ($forum_config['o_topic_views'] == '1')

                $forum_page['item_body']['info']['views'] = '<li class="info-views"><span class="label">'.$lang_forum['No views info'].'</span></li>';



            $forum_page['item_body']['info']['replies'] = '<li class="info-replies"><span class="label">'.$lang_forum['No replies info'].'</span></li>';

            $forum_page['item_body']['info']['lastpost'] = '<li class="info-lastpost"><span class="label">'.$lang_forum['No lastpost info'].'</span></li>';

        }

        else

        {

            // Assemble the Topic heading



            // Should we display the dot or not? :)

            if (!$forum_user['is_guest'] && $forum_config['o_show_dot'] == '1' && $cur_topic['has_posted'] > 0)

            {

                $forum_page['item_title']['posted'] = '<span class="posted-mark">'.$lang_forum['You posted indicator'].'</span>';

                $forum_page['item_status']['posted'] = 'posted';

            }



            if ($cur_topic['sticky'] == '1')

            {

                $forum_page['item_title_status']['sticky'] = '<em class="sticky">'.$lang_forum['Sticky'].'</em>';

                $forum_page['item_status']['sticky'] = 'sticky';

            }



            if ($cur_topic['closed'] == '1')

            {

                $forum_page['item_title_status']['closed'] = '<em class="closed">'.$lang_forum['Closed'].'</em>';

                $forum_page['item_status']['closed'] = 'closed';

            }



            ($hook = get_hook('xn_portal_by_daris_at_topic_loop_normal_topic_pre_item_title_status_merge')) ? eval($hook) : null;



            if (!empty($forum_page['item_title_status']))

                $forum_page['item_title']['status'] = '<span class="item-status">'.sprintf($lang_forum['Item status'], implode(', ', $forum_page['item_title_status'])).'</span>';



            $forum_page['item_title']['link'] = '<a href="'.forum_link($forum_url['topic'], array($cur_topic['id'], sef_friendly($cur_topic['subject']))).'">'.forum_htmlencode($cur_topic['subject']).'</a>';



            ($hook = get_hook('xn_portal_by_daris_at_topic_loop_normal_topic_pre_item_title_merge')) ? eval($hook) : null;



            $forum_page['item_body']['subject']['title'] = '<h3 class="hn"><span class="item-num">'.$forum_page['item_count'].'</span> '.implode(' ', $forum_page['item_title']).'</h3>';



            // Assemble the Topic subject



            if (empty($forum_page['item_status']))

                $forum_page['item_status']['normal'] = 'normal';



            $forum_page['item_pages'] = ceil(($cur_topic['num_replies'] + 1) / $forum_user['disp_posts']);



            if ($forum_page['item_pages'] > 1)

                $forum_page['item_nav']['pages'] = '<span>'.$lang_forum['Pages'].'&#160;</span>'.paginate($forum_page['item_pages'], -1, $forum_url['topic'], $lang_common['Page separator'], array($cur_topic['id'], sef_friendly($cur_topic['subject'])));



            // Does this topic contain posts we haven't read? If so, tag it accordingly.

            if (!$forum_user['is_guest'] && $cur_topic['last_post'] > $forum_user['last_visit'] && (!isset($tracked_topics['topics'][$cur_topic['id']]) || $tracked_topics['topics'][$cur_topic['id']] < $cur_topic['last_post']))

            {

                $forum_page['item_nav']['new'] = '<em class="item-newposts"><a href="'.forum_link($forum_url['topic_new_posts'], array($cur_topic['id'], sef_friendly($cur_topic['subject']))).'">'.$lang_forum['New posts'].'</a></em>';

                $forum_page['item_status']['new'] = 'new';

            }



            ($hook = get_hook('xn_portal_by_daris_at_topic_loop_normal_topic_pre_item_nav_merge')) ? eval($hook) : null;



            if (!empty($forum_page['item_nav']))

                $forum_page['item_subject']['nav'] = '<span class="item-nav">'.sprintf($lang_forum['Topic navigation'], implode('&#160;&#160;', $forum_page['item_nav'])).'</span>';



            ($hook = get_hook('xn_portal_by_daris_at_topic_loop_normal_topic_pre_item_subject_merge')) ? eval($hook) : null;



            $forum_page['item_body']['info']['replies'] = '<li class="info-replies"><strong>'.forum_number_format($cur_topic['num_replies']).'</strong> <span class="label">'.(($cur_topic['num_replies'] == 1) ? $lang_forum['reply'] : $lang_forum['replies']).'</span></li>';



            if ($forum_config['o_topic_views'] == '1')

                $forum_page['item_body']['info']['views'] = '<li class="info-views"><strong>'.forum_number_format($cur_topic['num_views']).'</strong> <span class="label">'.(($cur_topic['num_views'] == 1) ? $lang_forum['view'] : $lang_forum['views']).'</span></li>';



            $forum_page['item_body']['info']['lastpost'] = '<li class="info-lastpost"><span class="label">'.$lang_forum['Last post'].'</span> <strong><a href="'.forum_link($forum_url['post'], $cur_topic['last_post_id']).'">'.format_time($cur_topic['last_post']).'</a></strong> <cite>'.sprintf($lang_forum['by poster'], forum_htmlencode($cur_topic['last_poster'])).'</cite></li>';

        }



        $forum_page['item_subject']['starter'] = '<span class="item-starter">'.sprintf($lang_forum['Topic starter'], '<cite>'.forum_htmlencode($cur_topic['poster']).'</cite>').'</span>';

        $forum_page['item_body']['subject']['desc'] = implode(' ', $forum_page['item_subject']);



        ($hook = get_hook('xn_portal_by_daris_at_row_pre_item_status_merge')) ? eval($hook) : null;



        $forum_page['item_style'] = (($forum_page['item_count'] % 2 != 0) ? ' odd' : ' even').(($forum_page['item_count'] == 1) ? ' main-first-item' : '').((!empty($forum_page['item_status'])) ? ' '.implode(' ', $forum_page['item_status']) : '');



        ($hook = get_hook('xn_portal_by_daris_at_row_pre_display')) ? eval($hook) : null;



?>

        <div id="topic<?php echo $cur_topic['id'] ?>" class="main-item<?php echo $forum_page['item_style'] ?>">

            <span class="icon <?php echo implode(' ', $forum_page['item_status']) ?>"><!-- --></span>

            <div class="item-subject">

                <?php echo implode("\n\t\t\t\t", $forum_page['item_body']['subject'])."\n" ?>

            </div>

            <ul class="item-info">

                <?php echo implode("\n\t\t\t\t", $forum_page['item_body']['info'])."\n" ?>

            </ul>

        </div>

<?php



    }



?>

    </div>

<?php



}

// Else there are no topics in this forum

else

{

    $forum_page['item_body']['subject']['title'] = '<h3 class="hn">'.$lang_forum['No topics'].'</h3>';

    $forum_page['item_body']['subject']['desc'] = '<p>'.$lang_forum['First topic nag'].'</p>';



    ($hook = get_hook('xn_portal_by_daris_at_no_results_row_pre_display')) ? eval($hook) : null;



?>

    <div id="forum" class="main-content main-forum">

        <div class="main-item empty main-first-item">

            <span class="icon empty"><!-- --></span>

            <div class="item-subject">

                <?php echo implode("\n\t\t\t\t", $forum_page['item_body']['subject'])."\n" ?>

            </div>

        </div>

    </div>

<?php



}

?>
MyFootballCafe.com  is Now Online!

Re: Help with my active topics list.

so any one got any fixes neutral

MyFootballCafe.com  is Now Online!

Re: Help with my active topics list.

http://www.msn-smiley.net/upload/images/116/1209489917693.gif

MyFootballCafe.com  is Now Online!

Re: Help with my active topics list.

any one. LOL just noticed, i got 700 posts in this forum, WOW big_smile

MyFootballCafe.com  is Now Online!

Re: Help with my active topics list.

I think you should try examining the code of "viewtopic.php" and reproduce the markup with CSS-classes, ids of the topics list in your script.

Re: Help with my active topics list.

i think u mean viewforum.php, i already checked that but i cant understand it. thats why i need help here.

MyFootballCafe.com  is Now Online!

Re: Help with my active topics list.

slavok, can u point me what to change please.

MyFootballCafe.com  is Now Online!

Re: Help with my active topics list.

Seems like "active topics" uses old markup. For example, a piece of the code from http://sports2all.com/community/:

            <div class="item-subject">
                <h3 class="hn"><span class="item-num">5</span> <a href="http://sports2all.com/community/topic/429/another-wwe-tv-show-coming-vince-worth-478-million-more/">Another WWE TV Show Coming?, Vince Worth $478+ Million, More</a></h3>
                <span class="item-starter">by <cite>SuperMAG</cite></span>
            </div>

And the code from 1.3.3 (http://punbb.informer.com/forums/search/recent/):

            <div class="item-subject">
                <h3 class="hn"><span class="item-num">1</span> <a href="http://punbb.informer.com/forums/topic/21043/need-help-on-punbb-1217/">Need help on PunBB 1.2.17</a></h3>
                <p><span class="item-starter">by <cite>Papillon</cite></span></p>
            </div>

The difference is that the <span class="item-starter"> tag is placed inside the <p> tag.

If you want to ensure the proper work of 1.3.3 styles, you should have 1.3.3 markup.
I think the markup changes you need are about this changeset: http://punbb.informer.com/trac/changeset/1092

Otherwise, your style will probably be not 100% compatible with PunBB 1.3.3.

Re: Help with my active topics list.

ok from what i understand the problem is the <p> tag.

but i don't see that in the active_topics.php file, so what exatly i should change so it shows as the 1.3.3 style markup.

MyFootballCafe.com  is Now Online!

Re: Help with my active topics list.

I'd recommend you to compare files viewforum.php and active_topics.php and to correct the latter.
I use the Notepad++ text editor, it compares files just by pressing Alt + D.

But I think all changes you have to do are here.

11 (edited by SuperMAG 2009-05-16 13:21)

Re: Help with my active topics list.

mmm i saw the change log and replaced all the lines there, except the last three changes in that page. ended up getting an error. hmm

the main problem is i don't understand php, so don't understand where the problem is coming from.

oh and thanks for the Notepad++ soft, i was always using the orignal notepad, this one is alot bitter.

i can provide you an ftp access if you think u can solve the problem quickly that way. so can u do it.

MyFootballCafe.com  is Now Online!

Re: Help with my active topics list.

I took the code from your first post and made the changes (moved up $forum_page['item_subject']['starter'] = ... and added "<p>" tag in $forum_page['item_body']['subject']['desc'] = ...). Here is the code with fixes (I didn't test it):

<?php
/***********************************************************************

    PunBB extension
    Portal
    Daris <daris91@gmail.com>

************************************************************************/


// Make sure no one attempts to run this script "directly"
if (!defined('FORUM'))
    exit;

$count = 15; // active topics count
$cur_panel['class'] = 'forum';

// Load the viewforum.php language file
require_once FORUM_ROOT.'lang/'.$forum_user['language'].'/forum.php';
require_once FORUM_ROOT.'lang/'.$forum_user['language'].'/search.php';

// Fetch list of topics
$query = array(
    'SELECT'    => 't.id, t.poster, t.subject, t.posted, t.first_post_id, t.last_post, t.last_post_id, t.last_poster, t.num_views, t.num_replies, t.closed, t.sticky, t.moved_to, t.forum_id',
    'FROM'        => 'topics AS t',
    'JOINS'        => array(
        array(
            'LEFT JOIN'         => 'forums as f',
            'ON'            => 't.forum_id=f.id'
        ),
        array(
            'LEFT JOIN'        => 'forum_perms AS fp',
            'ON'            => '(fp.forum_id=t.forum_id AND fp.group_id='.$forum_user['g_id'].')'
        )
    ),
    'WHERE'        => '(fp.read_forum IS NULL OR fp.read_forum=1) AND t.moved_to IS NULL',
    'ORDER BY'    => 't.last_post DESC',
    'LIMIT'        => '0, '.$count
);

// With "has posted" indication
if (!$forum_user['is_guest'] && $forum_config['o_show_dot'] == '1')
{
    $subquery = array(
        'SELECT'    => 'COUNT(p.id)',
        'FROM'        => 'posts AS p',
        'WHERE'        => 'p.poster_id='.$forum_user['id'].' AND p.topic_id=t.id'
    );

    ($hook = get_hook('xn_portal_by_daris_at_qr_get_has_posted')) ? eval($hook) : null;
    $query['SELECT'] .= ', ('.$forum_db->query_build($subquery, true).') AS has_posted';
}

($hook = get_hook('xn_portal_by_daris_at_qr_get_topics')) ? eval($hook) : null;
$result_at = $forum_db->query_build($query) or error(__FILE__, __LINE__);

// Get topic/forum tracking data
if (!$forum_user['is_guest'])
    $tracked_topics = get_tracked_topics();


($hook = get_hook('xn_portal_by_daris_at_pre_header_load')) ? eval($hook) : null;


$forum_page['item_header'] = array();
$forum_page['item_header']['subject']['title'] = '<strong class="subject-title">'.$lang_forum['Topics'].'</strong>';
$forum_page['item_header']['info']['replies'] = '<strong class="info-replies">'.$lang_forum['replies'].'</strong>';

if ($forum_config['o_topic_views'] == '1')
    $forum_page['item_header']['info']['views'] = '<strong class="info-views">'.$lang_forum['views'].'</strong>';

$forum_page['item_header']['info']['lastpost'] = '<strong class="info-lastpost">'.$lang_forum['last post'].'</strong>';

($hook = get_hook('xn_portal_by_daris_at_main_output_start')) ? eval($hook) : null;

// If there are topics in this forum
if ($forum_db->num_rows($result_at))
{

?>
    <div class="main-subhead">
        <p class="item-summary<?php echo ($forum_config['o_topic_views'] == '1') ? ' forum-views' : ' forum-noview' ?>"><span><?php printf($lang_forum['Forum subtitle'], implode(' ', $forum_page['item_header']['subject']), implode(', ', $forum_page['item_header']['info'])) ?></span></p>
    </div>
    <div id="forum" class="main-content main-forum<?php echo ($forum_config['o_topic_views'] == '1') ? ' forum-views' : ' forum-noview' ?>">
<?php

    ($hook = get_hook('xn_portal_by_daris_at_pre_topic_loop_start')) ? eval($hook) : null;

    $forum_page['item_count'] = 0;

    while ($cur_topic = $forum_db->fetch_assoc($result_at))
    {
        ($hook = get_hook('xn_portal_by_daris_at_topic_loop_start')) ? eval($hook) : null;

        ++$forum_page['item_count'];

        // Start from scratch
        $forum_page['item_subject'] = $forum_page['item_body'] = $forum_page['item_status'] = $forum_page['item_nav'] = $forum_page['item_title'] = $forum_page['item_title_status'] = array();

        if ($forum_config['o_censoring'] == '1')
            $cur_topic['subject'] = censor_words($cur_topic['subject']);

        $forum_page['item_subject']['starter'] = '<span class="item-starter">'.sprintf($lang_forum['Topic starter'], forum_htmlencode($cur_topic['poster'])).'</span>';

        if ($cur_topic['moved_to'] != null)
        {
            $forum_page['item_status']['moved'] = 'moved';
            $forum_page['item_title']['link'] = '<span class="item-status"><em class="moved">'.sprintf($lang_forum['Item status'], $lang_forum['Moved']).'</em></span> <a href="'.forum_link($forum_url['topic'], array($cur_topic['moved_to'], sef_friendly($cur_topic['subject']))).'">'.forum_htmlencode($cur_topic['subject']).'</a>';

            // Combine everything to produce the Topic heading
            $forum_page['item_body']['subject']['title'] = '<h3 class="hn"><span class="item-num">'.forum_number_format($forum_page['start_from'] + $forum_page['item_count']).'</span>'.$forum_page['item_title']['link'].'</h3>';

            ($hook = get_hook('xn_portal_by_daris_at_topic_loop_moved_topic_pre_item_subject_merge')) ? eval($hook) : null;

            if ($forum_config['o_topic_views'] == '1')
                $forum_page['item_body']['info']['views'] = '<li class="info-views"><span class="label">'.$lang_forum['No views info'].'</span></li>';

            $forum_page['item_body']['info']['replies'] = '<li class="info-replies"><span class="label">'.$lang_forum['No replies info'].'</span></li>';
            $forum_page['item_body']['info']['lastpost'] = '<li class="info-lastpost"><span class="label">'.$lang_forum['No lastpost info'].'</span></li>';
        }
        else
        {
            // Assemble the Topic heading

            // Should we display the dot or not? :)
            if (!$forum_user['is_guest'] && $forum_config['o_show_dot'] == '1' && $cur_topic['has_posted'] > 0)
            {
                $forum_page['item_title']['posted'] = '<span class="posted-mark">'.$lang_forum['You posted indicator'].'</span>';
                $forum_page['item_status']['posted'] = 'posted';
            }

            if ($cur_topic['sticky'] == '1')
            {
                $forum_page['item_title_status']['sticky'] = '<em class="sticky">'.$lang_forum['Sticky'].'</em>';
                $forum_page['item_status']['sticky'] = 'sticky';
            }

            if ($cur_topic['closed'] == '1')
            {
                $forum_page['item_title_status']['closed'] = '<em class="closed">'.$lang_forum['Closed'].'</em>';
                $forum_page['item_status']['closed'] = 'closed';
            }

            ($hook = get_hook('xn_portal_by_daris_at_topic_loop_normal_topic_pre_item_title_status_merge')) ? eval($hook) : null;

            if (!empty($forum_page['item_title_status']))
                $forum_page['item_title']['status'] = '<span class="item-status">'.sprintf($lang_forum['Item status'], implode(', ', $forum_page['item_title_status'])).'</span>';

            $forum_page['item_title']['link'] = '<a href="'.forum_link($forum_url['topic'], array($cur_topic['id'], sef_friendly($cur_topic['subject']))).'">'.forum_htmlencode($cur_topic['subject']).'</a>';

            ($hook = get_hook('xn_portal_by_daris_at_topic_loop_normal_topic_pre_item_title_merge')) ? eval($hook) : null;

            $forum_page['item_body']['subject']['title'] = '<h3 class="hn"><span class="item-num">'.$forum_page['item_count'].'</span> '.implode(' ', $forum_page['item_title']).'</h3>';

            // Assemble the Topic subject

            if (empty($forum_page['item_status']))
                $forum_page['item_status']['normal'] = 'normal';

            $forum_page['item_pages'] = ceil(($cur_topic['num_replies'] + 1) / $forum_user['disp_posts']);

            if ($forum_page['item_pages'] > 1)
                $forum_page['item_nav']['pages'] = '<span>'.$lang_forum['Pages'].'&#160;</span>'.paginate($forum_page['item_pages'], -1, $forum_url['topic'], $lang_common['Page separator'], array($cur_topic['id'], sef_friendly($cur_topic['subject'])));

            // Does this topic contain posts we haven't read? If so, tag it accordingly.
            if (!$forum_user['is_guest'] && $cur_topic['last_post'] > $forum_user['last_visit'] && (!isset($tracked_topics['topics'][$cur_topic['id']]) || $tracked_topics['topics'][$cur_topic['id']] < $cur_topic['last_post']))
            {
                $forum_page['item_nav']['new'] = '<em class="item-newposts"><a href="'.forum_link($forum_url['topic_new_posts'], array($cur_topic['id'], sef_friendly($cur_topic['subject']))).'">'.$lang_forum['New posts'].'</a></em>';
                $forum_page['item_status']['new'] = 'new';
            }

            ($hook = get_hook('xn_portal_by_daris_at_topic_loop_normal_topic_pre_item_nav_merge')) ? eval($hook) : null;

            if (!empty($forum_page['item_nav']))
                $forum_page['item_subject']['nav'] = '<span class="item-nav">'.sprintf($lang_forum['Topic navigation'], implode('&#160;&#160;', $forum_page['item_nav'])).'</span>';

            ($hook = get_hook('xn_portal_by_daris_at_topic_loop_normal_topic_pre_item_subject_merge')) ? eval($hook) : null;

            $forum_page['item_body']['info']['replies'] = '<li class="info-replies"><strong>'.forum_number_format($cur_topic['num_replies']).'</strong> <span class="label">'.(($cur_topic['num_replies'] == 1) ? $lang_forum['reply'] : $lang_forum['replies']).'</span></li>';

            if ($forum_config['o_topic_views'] == '1')
                $forum_page['item_body']['info']['views'] = '<li class="info-views"><strong>'.forum_number_format($cur_topic['num_views']).'</strong> <span class="label">'.(($cur_topic['num_views'] == 1) ? $lang_forum['view'] : $lang_forum['views']).'</span></li>';

            $forum_page['item_body']['info']['lastpost'] = '<li class="info-lastpost"><span class="label">'.$lang_forum['Last post'].'</span> <strong><a href="'.forum_link($forum_url['post'], $cur_topic['last_post_id']).'">'.format_time($cur_topic['last_post']).'</a></strong> <cite>'.sprintf($lang_forum['by poster'], forum_htmlencode($cur_topic['last_poster'])).'</cite></li>';
        }

        $forum_page['item_body']['subject']['desc'] = '<p>'.implode(' ', $forum_page['item_subject']).'</p>';

        ($hook = get_hook('xn_portal_by_daris_at_row_pre_item_status_merge')) ? eval($hook) : null;

        $forum_page['item_style'] = (($forum_page['item_count'] % 2 != 0) ? ' odd' : ' even').(($forum_page['item_count'] == 1) ? ' main-first-item' : '').((!empty($forum_page['item_status'])) ? ' '.implode(' ', $forum_page['item_status']) : '');

        ($hook = get_hook('xn_portal_by_daris_at_row_pre_display')) ? eval($hook) : null;

?>
        <div id="topic<?php echo $cur_topic['id'] ?>" class="main-item<?php echo $forum_page['item_style'] ?>">
            <span class="icon <?php echo implode(' ', $forum_page['item_status']) ?>"><!-- --></span>
            <div class="item-subject">
                <?php echo implode("\n\t\t\t\t", $forum_page['item_body']['subject'])."\n" ?>
            </div>
            <ul class="item-info">
                <?php echo implode("\n\t\t\t\t", $forum_page['item_body']['info'])."\n" ?>
            </ul>
        </div>
<?php

    }

?>
    </div>
<?php

}
// Else there are no topics in this forum
else
{
    $forum_page['item_body']['subject']['title'] = '<h3 class="hn">'.$lang_forum['No topics'].'</h3>';
    $forum_page['item_body']['subject']['desc'] = '<p>'.$lang_forum['First topic nag'].'</p>';

    ($hook = get_hook('xn_portal_by_daris_at_no_results_row_pre_display')) ? eval($hook) : null;

?>
    <div id="forum" class="main-content main-forum">
        <div class="main-item empty main-first-item">
            <span class="icon empty"><!-- --></span>
            <div class="item-subject">
                <?php echo implode("\n\t\t\t\t", $forum_page['item_body']['subject'])."\n" ?>
            </div>
        </div>
    </div>
<?php

}
?>

Re: Help with my active topics list.

thanks alot, that perfectly fixed the positioning.

there is still that double line at the end, though its not that important. can u give me a tip where that line is caused.

MyFootballCafe.com  is Now Online!

Re: Help with my active topics list.

Maybe it's about this code (http://sports2all.com/community/style/SilverLight/SilverLight.css, line 163):

.brd .main-content,
#brd-index #brd-visit, #brd-qpost,
#brd-index #brd-announcement {
    margin-bottom: 1em;
    }

Re: Help with my active topics list.

i don't think it has some thing to do with that, but it might be related to this: http://sports2all.com/community/extensi … /style.css

though it doesn't really matter. Thanks alooot for the first fix.

Parpalak can you help me with one more thing, i want to put the Login block that you see on my forum main page into a widget in the wordpress. http://sports2all.com/community/

http://punbb.informer.com/forums/topic/ … ss-widget/

i can write the php in my widgets so i just need the correct code, that topic has the code but not working outside the forum.

thanks again.

MyFootballCafe.com  is Now Online!

16

Re: Help with my active topics list.

SuperMAG, you are being too fussy, IMHO, and sweating on stuff you don't need to worry about.

Remember CSS and HTML/PHP aren't there to produce desktop publishing style layout and positioning results for the web.

I mean, heavens, the results your users will be getting will probably (and properly) vary wildly according to which browser and platform the page is being viewed from.

So IMHO: don't sweat the small stuff and don't try and achieve precise positioning effects. WAY more trouble than it's worth. Stick to default behaviours.

PS - seems like an awful lot of bot registrations on your board - about 1000+. Not good.

Re: Help with my active topics list.

mmm what you talking about, sorry not that professional in english language, but i did understand the last sentence, i dont think they are bots. may be there are 1-10 bots but not 1000, these are real members. though most of them do not post.

MyFootballCafe.com  is Now Online!

18

Re: Help with my active topics list.

SuperMAG wrote:

these are real members. though most of them do not post.

lol:lol::lol::lol:

Re: Help with my active topics list.

lol whats so funny, by real members i mean human created members, not bots.

MyFootballCafe.com  is Now Online!

Re: Help with my active topics list.

SuperMAG wrote:

i want to put the Login block that you see on my forum main page into a widget in the wordpress.

Maybe you'll find something useful in this topic: http://punbb.informer.com/forums/topic/ … for-login/

Re: Help with my active topics list.

thanks i think that will help.

MyFootballCafe.com  is Now Online!