Topic: Post status indicators

Hi there once again,

I want to ad a new Symbol for the Post status indicators "moved topics"(imoved = moved topics). I think I must it ad on the "viewforum.php" but I dont know how.

On http://punbb.org/forums/viewtopic.php?id=7800 #4 is a List wich indicators are available.

/* 10.1 These are the post status indicators which appear at the left of some tables.
.inew = new posts, .iredirect = redirect forums, .iclosed = closed topics and
.isticky = sticky topics. By default only .inew is different from the default.*/

Is there anyone who can help me to find a solution?

Greetz L.

Sorry for my stupid English, but I'm an old and unteachable man.
Visit My PunBB Forum

Re: Post status indicators

Check the while loop for $cur_topic in viewforum.php
Specifically the icon_type variable

Re: Post status indicators

Sorry but I'm a DAU

I looked in viewforum.php and found this:

while ($cur_topic = $db->fetch_assoc($result))
    {
        $icon_text = $lang_common['Normal icon'];
        $item_status = '';
        $icon_type = 'icon';

        if ($cur_topic['moved_to'] == null)
            $last_post = '<a href="viewtopic.php?pid='.$cur_topic['last_post_id'].'#p'.$cur_topic['last_post_id'].'">'.format_time($cur_topic['last_post']).'</a> <span class="byuser">'.$lang_common['by'].' '.pun_htmlspecialchars($cur_topic['last_poster']).'</span>';
        else
            $last_post = ' ';

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

        if ($cur_topic['moved_to'] != 0)
            $subject = $lang_forum['Moved'].': <a href="viewtopic.php?id='.$cur_topic['moved_to'].'">'.

I think you mean where == null, I must edit something????? Right???

Sorry for my stupid English, but I'm an old and unteachable man.
Visit My PunBB Forum

4 (edited by Smartys 2005-09-17 22:06)

Re: Post status indicators

No, I was thinking more like this:

FIND

if ($cur_topic['moved_to'] != 0)
            $subject = $lang_forum['Moved'].': <a href="viewtopic.php?id='.$cur_topic['moved_to'].'">'.pun_htmlspecialchars($cur_topic['subject']).'</a> <span class="byuser">'.$lang_common['by'].' '.pun_htmlspecialchars($cur_topic['poster']).'</span>';

REPLACE WITH

if ($cur_topic['moved_to'] != 0)
{
            $icon_type = 'imoved';
            $subject = $lang_forum['Moved'].': <a href="viewtopic.php?id='.$cur_topic['moved_to'].'">'.pun_htmlspecialchars($cur_topic['subject']).'</a> <span class="byuser">'.$lang_common['by'].' '.pun_htmlspecialchars($cur_topic['poster']).'</span>';
}

Re: Post status indicators

I've made it corectly, now comes:

Parse error: parse error, unexpected '}' in /web/forum/viewforum.php on line 159

I think there is something wrong or missing in my DB????

Sorry for my stupid English, but I'm an old and unteachable man.
Visit My PunBB Forum

Re: Post status indicators

lol, you messed up the code you pasted from the file, so my code was messed up
Edited tongue

7 (edited by Lucky Looser 2005-09-18 10:51)

Re: Post status indicators

My code was not messed, it's from my viewforum.php. *???*

I think I know what you mean, but I can't PHP, so I must see a functional code then I can make one for me I think.
I must also ad a table in my db for that. *My God; SQL* sad

I want much but its not my world.

Sorry for my stupid English, but I'm an old and unteachable man.
Visit My PunBB Forum