451

(1 replies, posted in PunBB 1.2 bug reports)

the bandwidth and space us up to you, if you modify your punbb files, how much trafic comes into your site...If you do some research that ill get you a long way.

There are video's on how to installing punbb. Just upload the punbb 1.2.17 files to your server , run install mod > create config.php >chmod a few folders .

i know someone on the forum (here or punres) has banned certian addreses... im sure you could use that but with a * somewhere?

And you dont have to have image verification.. things like a question, two + five.. and it tells you the answer, you just have to copy it, or clicking on the image as the submit button?

use systems that dont allow the bot to join? Their are a few around

And i think if the word censoring is enabled it does the names to? or is that just punhtml....?

To change the width of the forum

Item 5.1 in Oxygen.css change this

#punwrap {margin: 12px 20px}

to this

#punwrap {width: 800px}

where it says 800px put whatever width you want, you will need to do this in each style file
[edit]
To change the width and center the forum

Item 5.1 in Oxygen.css change this

#punwrap {margin: 12px 20px}

to this

#punwrap {width: 800px; margin: 12px auto}

where it says 800px put whatever width you want, you will need to do this in each style file

Yes If you are using 1.2.16, If you are using 1.3 you can do the hdiff.

Check the wiki at punres.org

Under CSS

457

(22 replies, posted in PunBB 1.2 show off)

When you have a larger screen res, more than what you are, the banner repates

Pic:

http://img229.imageshack.us/my.php?image=bgwk6.png

Username: matt1298

Change password

on the profile page

this would be possible...will require allot of coding though.

On say a create_project.php (you can use some of the code from the admin stuff) and make a new table... then a new user privilage...and then set the user group to the new rank. The only down side with this: admins/mods wont be able to use it, though they will see the forum anyway... im just thinking that is is too much modifcation to do to viewforum.php without effecting the other forums..?

will be awhile... they reccomend not making any major mods untill the full release.

MSN: matthew_hutchings[at]hotmail[dot]com

Just a note that you should NEVER give our your ftp detials to ANYONE!

ill help you problem by problem so install it and post your first problem.

Your'l need to explian a little more..

your own site or a free site, where you joined up?

Cant you do it or are you having problems?


What versions are you using?

No not in the current version... in most cases you upload all the files and run install_mod.php ...then look at read me and open up the files it tell you too and use the "find and replace" !

465

(7 replies, posted in PunBB 1.2 troubleshooting)

you will also need to change the 50 to 10 in the mysql select query below  line 130

466

(20 replies, posted in PunBB 1.3 troubleshooting)

On the assumption that the timezone isn't 100% user compatible... Personally i would (if it works like this) get the user to select the current hour they are on then find the difference and then that will be the time for them smile


Would that work?

467

(18 replies, posted in PunBB 1.2 troubleshooting)

hmm not too sure why that woudnt work, but if you change it to "or" insted of "," it seems to work (maby MattF can help me out)

// Fetch user count
$result = $db->query('SELECT COUNT(id) FROM '.$db->prefix.'topics WHERE forum_id =('.implode(' or', $forumids).') ') or error('Unable to fetch user list count', __FILE__, __LINE__, $db->error());
$num_users = $db->result($result);

and put this where you want the page's to show.

<div class="linkst">
    <div class="inbox">
        <p class="pagelink"><?php echo $paging_links ?></p>
    </div>
</div>

have you configured .htaccess and does /rewite.php exist?

469

(18 replies, posted in PunBB 1.2 troubleshooting)

works on mine smile

$page sets how many you want on a page, you ill need to change the master limit to how many pages you want * $perpage so you dont get just one page...

<?php
 
define('PUN_ROOT', './');
require_once PUN_ROOT.'include/common.php';
 
//Set the page title here
$page_title = pun_htmlspecialchars('reviewstash / by the stash, for the stash');

define('PUN_ALLOW_INDEX', 1);
require_once PUN_ROOT.'header.php';
require_once PUN_ROOT.'include/parser.php';
require_once PUN_ROOT.'lang/'.$pun_user['language'].'/index.php';
require_once PUN_ROOT.'lang/'.$pun_user['language'].'/common.php';
require_once PUN_ROOT.'lang/'.$pun_user['language'].'/topic.php';
require_once PUN_ROOT.'lang/'.$pun_user['language'].'/login.php';
require_once PUN_ROOT.'lang/'.$pun_user['language'].'/forum.php';

//----------------------------------------------------------------------//

//These are the forums from which the news is retrieved - You may add more forums in the array. Make sure to seperate them with a (,)
$forumids = array(1);

//How many items on a page \\ Created by Utchin
$perpage= 2;

//This is the overall limit for how many news items will be displayed
$master_limit = '10';

//This is the amount of characters above which truncation will occur
$trunc_chars = '1000';

//----------------------------------------------------------------------//

if ($pun_config['o_index_message_show'] == 1)
{
?>
    <div class="block">
        <h2><span><?php echo pun_htmlspecialchars($pun_config['o_index_message_head']) ?></span></h2>
        <div class="box">
            <div class="inbox">
            <?php echo $pun_config['o_index_message'] ?>
            </div>
        </div>
    </div>
<?php
}
?>
<?php
//----------------------------------------------------------------------//

function close_tags($string)
{
    if (preg_match_all ('/<([a-z]+)[ >]/', $string, $start_tags))
    {
        $start_tags = $start_tags[1];

        if (preg_match_all ('/<\/([a-z]+)>/', $string, $end_tags))
        {
            $complete_tags = array();
            $end_tags = $end_tags[1];

            foreach ($start_tags as $key => $val)
            {
                $posb = array_search ($val, $end_tags);
                if (is_integer ($posb))
                {
                    unset ($end_tags[$posb]);
                }
                else
                {
                    $complete_tags[] = $val;
                }
            }
        }
        else
        {
            $complete_tags = $start_tags;
        }

        $complete_tags = array_reverse ($complete_tags);
        for ($i = 0; $i < count ($complete_tags); $i++)
        {
            $string .= '</' . $complete_tags[$i] . '>';
        }
    }

        // Removes irrelevant tags
    $xhtml_tags = array ('</img>', '</hr>', '</br>');
    $string = str_replace ($xhtml_tags, '', $string);
    return $string;
}

//----------------------------------------------------------------------//

function truncate($string)
{
global $pun_config;
$trunc_chars = '350';
$length = $trunc_chars;
$append = '...';

    if (strlen ($string) <= $length)
    {
        return $string;
    }
    else if ($length > 0)
    {
        preg_match ('#^(?:[\x00-\x7F]|[\xC0-\xFF][\x80-\xBF]+){'.$length.',}\b#U', $string, $matches);
        $string = $matches[0];
        $string = close_tags (preg_replace ('#\s*<[^>]+>?\s*$#', '', $string).$append);
        return $string;
    }
}


// Fetch user count
$result = $db->query('SELECT COUNT(id) FROM '.$db->prefix.'topics WHERE forum_id =('.implode(',', $forumids).') ') or error('Unable to fetch user list count', __FILE__, __LINE__, $db->error());
$num_users = $db->result($result);
// Determine the user offset (based on $_GET['p'])
$num_pages = ceil($num_users / $perpage);

$p = (!isset($_GET['p']) || $_GET['p'] <= 1 || $_GET['p'] > $num_pages) ? 1 : $_GET['p'];
$start_from = $perpage * ($p - 1);

// Generate paging links
$paging_links = $lang_common['Pages'].': '.paginate($num_pages, $p, 'index.php?'.strtoupper($sort_dir));
?>
<div class="linkst">
    <div class="inbox">
        <p class="pagelink"><?php echo $paging_links ?></p>
    </div>
</div>
<?php

$result = $db->query('SELECT t.id, t.subject, t.num_replies, t.last_post, t.last_post_id, t.last_poster, t.num_views, t.forum_id, u.use_avatar, u.num_posts, u.registered, u.title, p.id AS pid, p.poster, p.poster_id, p.message, p.hide_smilies, p.posted, g.g_title, f.forum_name FROM '.$db->prefix.'topics AS t INNER JOIN '.$db->prefix.'posts AS p ON p.topic_id=t.id AND p.posted=t.posted INNER JOIN '.$db->prefix.'users AS u ON u.id=p.poster_id LEFT JOIN '.$db->prefix.'groups AS g ON g.g_id=u.group_id INNER JOIN '.$db->prefix.'forums AS f ON f.id=t.forum_id WHERE t.forum_id IN ('.implode(',', $forumids).') AND t.moved_to IS NULL AND f.redirect_url IS NULL ORDER BY t.posted DESC LIMIT '.$start_from.', '.$perpage) or error('Unable to fetch announcements', __FILE__, __LINE__, $db->error());

if ($db->num_rows($result))
{
    while($cur_post = $db->fetch_assoc($result))
    {
        echo '<div class="block">';
        if ($pun_config['o_avatars'] == '1' && $cur_post['use_avatar'] == '1' && $pun_user['show_avatars'] != '0')
        {
            if ($img_size = @getimagesize($pun_config['o_avatars_dir'].'/'.$cur_post['poster_id'].'.gif'))
            {
                $user_avatar = '<a href="profile.php?id=' . $cur_post['poster_id'] . '"><img src="'.$pun_config['o_avatars_dir'].'/'.$cur_post['poster_id'].'.gif" '.$img_size[3].' title="'.$cur_post['poster'].'\'s Avatar" alt="'.$cur_post['poster'].'\'s Avatar" /></a>';
            }
            else if ($img_size = @getimagesize($pun_config['o_avatars_dir'].'/'.$cur_post['poster_id'].'.jpg'))
            {
                $user_avatar = '<a href="profile.php?id=' . $cur_post['poster_id'] . '"><img src="'.$pun_config['o_avatars_dir'].'/'.$cur_post['poster_id'].'.jpg" '.$img_size[3].' title="'.$cur_post['poster'].'\'s Avatar" alt="'.$cur_post['poster'].'\'s Avatar" /></a>';
            }
            else if ($img_size = @getimagesize($pun_config['o_avatars_dir'].'/'.$cur_post['poster_id'].'.png'))
            {
                $user_avatar = '<a href="profile.php?id=' . $cur_post['poster_id'] . '"><img src="'.$pun_config['o_avatars_dir'].'/'.$cur_post['poster_id'].'.png" '.$img_size[3].' title="'.$cur_post['poster'].'\'s Avatar" alt="'.$cur_post['poster'].'\'s Avatar" /></a>';
            }
        }
        else
        {
            $user_avatar = '<a href="profile.php?id=' . $cur_post['poster_id'] . '"><img src="img/noimage.gif" alt=""/></a>';
        }

      $news_message = parse_message($cur_post['message'], $cur_post['hide_smilies']);

        if (pun_strlen($news_message) > $trunc_chars)
        {
            $news_message = truncate($news_message);
            $read_more = ' | <a href="viewtopic.php?id='.$cur_post['id'].'">Read More</a> | ';
        }
        else
        {
            $read_more = ' | ';
        }

        if ($cur_post['num_replies'] != '0')
        {
            $replies = ' <a href="viewtopic.php?id='.$cur_post['id'].'#p'.$cur_post['last_post_id'].'">Replies</a>: '.$cur_post['num_replies'].' ';
        }
        else
        {
            $replies = ' Replies: '.$cur_post['num_replies'].' ';
        }

echo "\t\t\t\t\t\t\t".'<h2><strong><a href="forum.php">Forum</a> » <a href="viewforum.php?id='.$cur_post['forum_id'].'">'.pun_htmlspecialchars($cur_post['forum_name']).'</a>'.'</strong></h2>'."\n";
?>
    <div class="box">
        <div class="inbox">
<ul><li>
<table width="100%" border="0">
    <tr>
        <td style="border: 0px; padding: 0px 10px 7px 7px;"><a class="news_subject" href="viewtopic.php?id=<?php echo $cur_post['id']; ?>"><?php echo $cur_post['subject']; ?></a></td>
    </tr>
</table> 
<table width="100%" border="0">
    <tr>
        <td style="text-align: left; border: 0px; padding-top: 0px;" valign="top"><?php echo $news_message."\n" ?></td>
    </tr>
</table>

    <div style="padding-bottom: 20px;" class="news_footer"><div style="padding: 5px 5px 0px 5px;">

<?php

                if ($cur_post['poster_id'] == $pun_user['id'] || $pun_user['g_id'] < PUN_GUEST){
                echo "\t\t\t\t\t\t\t".'<span class="user" style="float:left">Posted: '.format_time($cur_post['posted']).' by:<span class="user'.(isset($cur_post['g_title']) ? ' '.strtolower(str_replace(' ', '', $cur_post['g_title'])) : '').'"> <a class="poster" href="profile.php?id='.$cur_post['poster_id'].'">'.pun_htmlspecialchars($cur_post['poster']).'</a>'.$read_more.'Views: '.$cur_post['num_views'].' |'.$replies.'</span></span>'."\n\n\n\n";
                echo "\t\t\t\t\t\t\t".'<a href="viewtopic.php?id='.$cur_post['id'].'">'.pun_htmlspecialchars($lang_portal['Visit_Topic']).'</a>'.'<span style="white-space: nowrap; float:right">'.'<a href="misc.php?report='.$cur_post['pid'].'">'.$lang_topic['Report'].'</a>'.' | <a href="delete.php?id='.$cur_post['pid'].'">'.$lang_topic['Delete'].'</a> | <a href="edit.php?id='.$cur_post['pid'].'">'.$lang_topic['Edit'].'</a>'.' | <a href="post.php?tid='.$cur_post['id'].'">'.'Reply'.'</a>'.' | <a href="post.php?tid='.$cur_post['id'].'&qid='.$cur_post['pid'].'">'.$lang_topic['Quote'].'</a>'.'</span></div></div>'."\n\n\n\n";
            }else{
                echo "\t\t\t\t\t\t\t".'<span class="user" style="float:left">Posted: '.format_time($cur_post['posted']).' by:<span class="user'.(isset($cur_post['g_title']) ? ' '.strtolower(str_replace(' ', '', $cur_post['g_title'])) : '').'"> <a class="poster" href="profile.php?id='.$cur_post['poster_id'].'">'.pun_htmlspecialchars($cur_post['poster']).'</a>'.$read_more.'Views: '.$cur_post['num_views'].' |'.$replies.'</span></span></div></div>'."\n";
}
?>   
</li></ul>
        </div>
    </div>
</div>
<?php
    }
}

require PUN_ROOT.'footer.php';

?>

470

(1 replies, posted in PunBB 1.2 troubleshooting)

i know one way, the ID would be in the breadcrums?

EDIT: $cur_topic['forum_id']

471

(18 replies, posted in PunBB 1.2 troubleshooting)

I justed used the orgianal userlist items and havnt renamed them! well 10, thats how many they want to show?

472

(18 replies, posted in PunBB 1.2 troubleshooting)

ok ill install pp on my local and make a worknig on tonight...

473

(18 replies, posted in PunBB 1.2 troubleshooting)

just made this, have no idea if it ill work..

    if (strlen ($string) <= $length)
    {
        return $string;
    }
    else if ($length > 0)
    {
        preg_match ('#^(?:[\x00-\x7F]|[\xC0-\xFF][\x80-\xBF]+){'.$length.',}\b#U', $string, $matches);
        $string = $matches[0];
        $string = close_tags (preg_replace ('#\s*<[^>]+>?\s*$#', '', $string).$append);
        return $string;
    }
}

// Fetch user count
$result = $db->query('SELECT COUNT(id) FROM '.$db->prefix.'posts WHERE forum_id'.('.implode(',', $forumids).')) or error('Unable to fetch user list count', __FILE__, __LINE__, $db->error());
$num_users = $db->result($result);
// Determine the user offset (based on $_GET['p'])
$num_pages = ceil($num_users / 10);

$p = (!isset($_GET['p']) || $_GET['p'] <= 1 || $_GET['p'] > $num_pages) ? 1 : $_GET['p'];
$start_from = 10 * ($p - 1);

// Generate paging links
$paging_links = $lang_common['Pages'].': '.paginate($num_pages, $p, 'index.php?'.strtoupper($sort_dir));
 
$result = $db->query('SELECT t.id, t.subject, t.num_replies, t.last_post, t.last_post_id, t.last_poster, t.num_views, t.forum_id, u.use_avatar, u.num_posts, u.registered, u.title, p.id AS pid, p.poster, p.poster_id, p.message, p.hide_smilies, p.posted, g.g_title, f.forum_name FROM '.$db->prefix.'topics AS t INNER JOIN '.$db->prefix.'posts AS p ON p.topic_id=t.id AND p.posted=t.posted INNER JOIN '.$db->prefix.'users AS u ON u.id=p.poster_id LEFT JOIN '.$db->prefix.'groups AS g ON g.g_id=u.group_id INNER JOIN '.$db->prefix.'forums AS f ON f.id=t.forum_id WHERE t.forum_id IN ('.implode(',', $forumids).') AND t.moved_to IS NULL AND f.redirect_url IS NULL ORDER BY t.posted DESC LIMIT '.$start_from, 10) or error('Unable to fetch announcements', __FILE__, __LINE__, $db->error());

474

(20 replies, posted in PunBB 1.3 troubleshooting)

firefox has an addon like this, as you click the link it starts a timer, as the page stops loading Eveything it stops...

475

(6 replies, posted in PunBB 1.2 troubleshooting)

enable debug mode and paste the full error message.