Sorry what exactly do you want? Do you want the same side blocks on each of them and then just different main content?

352

(2 replies, posted in PunBB 1.2 discussion)

What's up with punres? I can't open it...

353

(26 replies, posted in PunBB 1.2 show off)

the "gameplay" link doesn't work

could you post the final working code?

it shows up as 6.2 because the variable $num_pages is a decimal number... you cant just divide by 15... you must do some number formatting... can't help you with that...sorry...just google it!!!

356

(26 replies, posted in PunBB 1.2 show off)

LOVE your punBB integration...

In viewtopic.php you have to play around with the variable $user_info[]

358

(13 replies, posted in Programming)

omg i am an idiot...
THANK YOU SO MUCH!!!

please post comments

##
##
##        Mod title:  Deleted posts log 
##
##      Mod version:  1.1 
##   Works on PunBB:  1.2.* (as far as I know) 
##     Release date:  05-23-2007 
##           Author:  Franz Liedke 
##
##      Description:  Provides a plugin that displays a log of all deleted posts. These posts can be restored or deleted forever. 
##
##       Affects DB:  Yes 
##
##   Affected files:  viewtopic.php 
##                    include\functions.php 
##                    delete.php 
##                    viewforum.php 
##
##            Notes:  Adds columns to the following database tables:
##            topics
##            posts
##            subscriptions 
##
##      Changelog:  Version 1.0.1
##            now includes an install_mod.php file
##              Version 1.0,2
##            full subscription support
##              Version 1.1
##            now working completely with topics that are deleted
##            also fixes number of replies and topics in viewforum.php and index.php
##            plugin is now also available for moderators
##
##  To be fixed yet:  Version 1.2
##            latest post display
##            more user-friendly / idiot-proof
##            users won't be able to restore posts as long as the topic post is not restored / does not exist
##
##     Generated By:  Auto Read-Me(by Caleb Champlin) - http://www.rscheatnet.com/Auto_Readme.zip
##
##       DISCLAIMER:  Please note that 'mods' are not officially supported by
##                    PunBB. Installation of this modification is done at your
##                    own risk. Backup your forum database and any and all
##                    applicable files before proceeding.
##
##    PLEASE REPORT ERRORS TO ME! I TRIED TO FIX THEM ALL, BUT I AM SURE I MISSED SOME OF THEM...
##

Download here

361

(13 replies, posted in Programming)

anybody?

362

(13 replies, posted in Programming)

thanks guys. one more question... this query is inside another query ($db->fetch_assoc($result) and stuff), but it looks like the query is only run once, although it should run once for every single one of the loops of the bigger queries. How can I fix that? Here is the whole code:

$result = $db->query("SELECT p.id, p.poster, p.poster_id, p.message, p.topic_id, p.first_post, t.subject, t.forum_id FROM ".$db->prefix."posts AS p INNER JOIN ".$db->prefix."topics AS t ON t.id=p.topic_id WHERE p.deleted=1");
if (!$db->num_rows($result))
    echo 'No deleted posts.';
else
{
?>
<table>
<tr>
<th style="width:250px;">Subject</th>
<th style="width:300px;">Message</th>
<th style="width:100px;">Poster</th>
</tr>
<?php
while ($deleted_post = $db->fetch_assoc($result))
{
$poster = '<a href="profile.php?id='.$deleted_post['poster_id'].'">'.$deleted_post['poster'].'</a>';
$db->query('SELECT id FROM '.$db->prefix.'posts WHERE first_post=1 AND topic_id='.$deleted_post['topic_id'].' AND id!='.$deleted_post['id']);
if ($db->num_rows($result) == '1')
    $restore = '0';
else
    $restore = '1';
?>
<form id="postlog" method="post" action="admin_loader.php?plugin=AMP_Deleted_post_log.php&id=<?php echo $deleted_post['id'] ?>&topic=<?php echo $deleted_post['topic_id'] ?>&forum=<?php echo $deleted_post['forum_id'] ?>&first_post=<?php echo $deleted_post['first_post'] ?>">
<tr>
<td style="width:250px;"><?php echo $deleted_post['subject'] ?></td>
<td style="width:300px;"><?php echo $deleted_post['message'] ?></td>
<td style="width:100px;"><?php echo $poster ?></td>
<td>
<input type="submit" name="delete" value="Delete forever" />
</td>
<td>
<input type="submit" name="restore" value="Restore" <?php if ($restore == '0') echo 'disabled ' ?>/>
</td>
</tr>
</form>
<?php
}
?>
</table>
<?php
}
?>

363

(13 replies, posted in Programming)

anybody... pleeeeeeeeeaaaazzzzeeee?

364

(13 replies, posted in Programming)

I am not really good in php. I am trying to find out if the query fetches a result or not. Which mysql function do I have to use?

365

(13 replies, posted in Programming)

This is what I am trying to do:

while ($deleted_post = $db->fetch_assoc($result))
{
$poster = '<a href="profile.php?id='.$deleted_post['poster_id'].'">'.$deleted_post['poster'].'</a>';
$db->query('SELECT id FROM '.$db->prefix.'posts WHERE first_post=1 AND topic_id='.$deleted_post['topic_id'].' AND id!='.$deleted_post['id']);
if ($db->num_rows($result))
    $restore = '0';
else
    $restore = '1';

But $restore always seems to be 0, which should not be true always.
Is $db->num_rows the right function? What should I use instead? $db->result?

366

(13 replies, posted in Programming)

ok does this code after it make sense?

if ($db->num_rows($result))
    $restore = '0';
else
    $restore = '1';

367

(13 replies, posted in Programming)

Is this query correct?

$db->query('SELECT id FROM '.$db->prefix.'posts WHERE first_post=1 AND topic_id='.$deleted_post['topic_id'].' AND id!='.$deleted_post['id']);

the subscribe link at the bottom is still there. this mod displays a link under every post (only for moderators and administrators) that lets you subscribe the poster to that topic, so that is another functionality than the link at the bottom...
i am planning on adding some functionality, but i don't have the time for that right now.

not totally sure but i guess you mean to remove the ",true" part?

anybody?

could you give an example?

EDIT: oh do you mean the "or error" part?

@SMARTYS:
Ok I am working on a mod right now. I need to do a query inside a query also... how can I make the first query buffered?

Any comments?

Subscribe User 1.0.1 released!!! This version is actually working wink

##
##
##        Mod title:  Subscribe User 
##
##      Mod version:  1.0.1
##   Works on PunBB:  1.2.* (as far as I know) 
##     Release date:  05-20-2007 
##           Author:  Franz Liedke 
##
##      Description:  Adds the possibility (for admins and, I think, moderators, too) to subscribe a user to a topic if he has already posted there.
##
##       Affects DB:  No 
##
##   Affected files:  viewtopic.php 
##                    misc.php 
##
##            Notes:  Will display a link "Subscribe this user" under every post.
##
##      Changelog:  Version 1.0.1
##            some bugfixes -> first version that is actually working ;)
##
##     Generated By:  Auto Read-Me(by Caleb Champlin) - http://www.rscheatnet.com/Auto_Readme.zip
##
##       DISCLAIMER:  Please note that 'mods' are not officially supported by
##                    PunBB. Installation of this modification is done at your
##                    own risk. Backup your forum database and any and all
##                    applicable files before proceeding.
##

Download here

375

(24 replies, posted in PunBB 1.2 show off)

ok shedrock, i like it
like it a lot!!!
i wanted to do the same thing and i don't think it's gonna happen anymore
anyways... could you post some screenshots of the backoffice... how much can you configure? can you configure where the blocks are and stuff or which template to use (blocks on one side, blocks on two sides,...)?