PunBB Resource

Your ultimate PunBB resource!

Keywords:

    (Extended)

You are not logged in.


Login to move these ads to the bottom of the page

#1 2005-07-13 07:47:25

Ju
New member
From: Laon (Fr - 02)
Registered: 2005-07-13
Posts: 7
Website

Complete Management of the posts 1.0

Code:

##
##        Mod title:  Complete Management of the posts
##
##      Mod version:  1.0
##      Works on PunBB:  1.2.5, 1.2.6
##      Release date:  7-13-05
##      Author:  Julien VAUBOURG (CtrlAltSuppr.com - www.jsand.net)
##
##      Description:  Modulate management complete of the posts in mass or individual (function moderator/administrator) :
##                  - Move
##                  - Delete
##                  - Amalgamate (merge)
##
##      Affects DB:  No
##
##      Affected files:  viewtopic.php
##                            moderate.php 
##                            lang/English/misc.php
##                            lang/English/topic.php
##                            style/imports/base.css
##
##      Notes:  Tested on CtrlAltSuppr.com - Translated from french
##
##      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.
##

[[url=http://www.punbb.fr/forums/viewtopic.php?id=457]French version[/url]]

Download here

Offline

 

#2 2005-07-13 09:08:33

Ju
New member
From: Laon (Fr - 02)
Registered: 2005-07-13
Posts: 7
Website

Re: Complete Management of the posts 1.0

SCREENSHOTS (from CtrlAltSuppr.com) :
http://img306.imageshack.us/img306/4372/coucou3bv.jpg

http://img165.echo.cx/img165/5131/mod25ul.jpg

Offline

 

#3 2005-07-15 02:14:13

Bulgaricus
Member
From: Warsaw, Poland
Registered: 2005-05-12
Posts: 44
Website

Re: Complete Management of the posts 1.0

Great mod Ju!

Is there any possibility to move the first post of a topic?


www.bulgaricus.com
All about Bulgaria in Polish

Offline

 

#4 2005-07-15 02:17:43

Ju
New member
From: Laon (Fr - 02)
Registered: 2005-07-13
Posts: 7
Website

Re: Complete Management of the posts 1.0

No, because the firt post is special, it's the "master post".
If you move the first post to other topic, it's not logic.
If you delete the first post, you delete the topic.

Offline

 

#5 2005-07-15 03:21:06

Bulgaricus
Member
From: Warsaw, Poland
Registered: 2005-05-12
Posts: 44
Website

Re: Complete Management of the posts 1.0

Yes, I see...

Is there any possibility to merge two topics?


www.bulgaricus.com
All about Bulgaria in Polish

Offline

 

#6 2005-07-15 03:31:13

Bulgaricus
Member
From: Warsaw, Poland
Registered: 2005-05-12
Posts: 44
Website

Re: Complete Management of the posts 1.0

I noticed one bug in that mod. When you amalgamate posts, the topic decreases and fits into smaller number of pages than before. Anyway the displayed number of pages remaines unchanged and the last pages are of course empty sad


www.bulgaricus.com
All about Bulgaria in Polish

Offline

 

#7 2005-07-15 18:14:57

IdleFire
Member
From: Australia
Registered: 2005-06-09
Posts: 44
Website

Re: Complete Management of the posts 1.0

Anyone know how to fix that problem? This is a mod I'd really like, but it'd be nice to have it all fixed first.

Offline

 

#8 2005-07-17 02:53:44

Ju
New member
From: Laon (Fr - 02)
Registered: 2005-07-13
Posts: 7
Website

Re: Complete Management of the posts 1.0

Bulgaricus wrote:

I noticed one bug in that mod. When you amalgamate posts, the topic decreases and fits into smaller number of pages than before. Anyway the displayed number of pages remaines unchanged and the last pages are of course empty sad

ok !
It's good.

[color=red]I corrected the mod.[/red]

hdiff :
Replace :

Code:

        // Déplacement de posts
        case 'move' :

            if(!isset($_POST['confirm'])) {

                //confirm_referrer('viewtopic.php'); // Bug IE
                $page_title = pun_htmlspecialchars($pun_config['o_board_title']).' / '.$lang_misc['Moderate'];
                require PUN_ROOT.'header.php';

                ?> <div class="blockform">
                    <h2><?php echo $lang_misc['Deplacer posts'] ?></h2>
                    <div class="box">
                        <form method="post" action="moderate.php?fid=<?php echo $fid ?>&ptid=<?php echo $_GET['ptid'] ?>&actionposts=move">
                            <input type="hidden" name="posts" value="<?php echo urlencode($posts) ?>" />
                            <div class="inform">
                                <fieldset>
                                    <legend><?php echo $lang_misc['Choisir topic'] ?></legend>
                                    <div class="infldset">
                                        <p><?php echo $lang_misc['Topic destination'] ?><br />
                                        <input type="text" style="width:50%" name="postsmoveto" /><br />
                                        <br />
                                        <input type="checkbox" name="anterieurs" value="1" /> <?php echo $lang_misc['Avertissement date'] ?></p>
                                    </div>
                                </fieldset>
                            </div>
                            <p><input type="submit" name="confirm" value="<?php echo $lang_misc['Deplacer posts ok'] ?>" /><a href="javascript:history.go(-1)"><?php echo $lang_common['Go back'] ?></a></p>
                        </form>
                    </div>
                </div> <?

                require PUN_ROOT.'footer.php';
                break;

            } else {

                confirm_referrer('moderate.php');

                // Extraction de l'id du topic de destination
                preg_match('/id=([0-9]+)/',$_POST['postsmoveto'], $postsmoveto);
                if(empty($postsmoveto[1]))
                    message($lang_misc['Erreur topic destination']);
                $posts = unserialize(urldecode(stripslashes($_POST['posts'])));

                $result = $db->query('SELECT id FROM '.$db->prefix.'posts WHERE topic_id='.$postsmoveto[1].' ORDER BY posted LIMIT 1');
                $topic_post_id = $db->result($result);
                for($i=0; $i < count($posts); $i++) {
                    // On réécrit les messages qui sont plus anciens que le topic ou tous si anterieurs a été coché pour avoir un id récent
                    if($posts[$i] < $topic_post_id || isset($_POST['anterieurs'])) {
                        $post = $db->fetch_assoc($db->query('SELECT * FROM '.$db->prefix.'posts WHERE id='.$posts[$i]));
                        $db->query('INSERT INTO '.$db->prefix.'posts(poster,poster_id,poster_ip,poster_email,message,hide_smilies,posted,edited,edited_by,topic_id) VALUES("'.$post['poster'].'", "'.$post['poster_id'].'", "'.$post['poster_ip'].'", '.(!isset($post['poster_email']) ? 'NULL' : '"'.$post['poster_email'].'"').', "'.$post['message'].'", "'.$post['hide_smilies'].'", "'.time().'", '.(!isset($post['edited']) ? 'NULL' : '"'.$post['edited'].'"').', '.(!isset($post['edited_by']) ? 'NULL' : '"'.$post['edited_by'].'"').', "'.$postsmoveto[1].'")');
                        // On supprime les doublons qui comportent l'ancienne date
                        $db->query('DELETE FROM '.$db->prefix.'posts WHERE id='.$posts[$i]);
                        // On supprime la clé du topic qui n'est plus à écrire
                        unset($posts[$i]);
                    }
                }

                // Si il reste des topic qui sont à insérer avec leur date initiale
                if(!empty($posts))
                    $db->query('UPDATE '.$db->prefix.'posts SET topic_id='.$postsmoveto[1].' WHERE id='.implode(' OR id=',$posts));

                redirect('viewtopic.php?id='.$postsmoveto[1], $lang_misc['Posts deplaces']);
                break;

            }


        // Supprimer des posts
        case 'delete' :

            if(!isset($_POST['confirm'])) {

                //confirm_referrer('viewtopic.php'); // Bug IE
                $page_title = pun_htmlspecialchars($pun_config['o_board_title']).' / '.$lang_misc['Moderate'];
                require PUN_ROOT.'header.php';

                ?> <div class="blockform">
                    <h2><?php echo $lang_misc['Supprimer posts'] ?></h2>
                    <div class="box">
                        <form method="post" action="moderate.php?fid=<?php echo $fid ?>&ptid=<?php echo $_GET['ptid'] ?>&actionposts=delete">
                            <input type="hidden" name="posts" value="<?php echo urlencode($posts) ?>" />
                            <div class="inform">
                                <fieldset>
                                    <legend><?php echo $lang_misc['Confirmer'] ?></legend>
                                    <div class="infldset">
                                        <p><?php echo $lang_misc['Confirmer suppression'] ?><br />
                                    </div>
                                </fieldset>
                            </div>
                            <p><input type="submit" name="confirm" value="<?php echo $lang_misc['Supprimer posts ok'] ?>" /><a href="javascript:history.go(-1)"><?php echo $lang_common['Go back'] ?></a></p>
                        </form>
                    </div>
                </div> <?

                require PUN_ROOT.'footer.php';
                break;

            } else {

                confirm_referrer('moderate.php');
                $posts = unserialize(urldecode(stripslashes($_POST['posts'])));

                // On vérifie que le post initial du topic ne fait pas partie de la sélection
                $result = $db->query('SELECT id FROM '.$db->prefix.'posts WHERE topic_id='.$_GET['ptid'].' ORDER BY posted LIMIT 1');
                $topic_post_id = $db->result($result);
                if(isset($posts[$topic_post_id]))
                    unset($posts[$topic_post_id]);

                // On supprime les topics concernés
                if(!empty($posts))
                    $db->query('DELETE FROM '.$db->prefix.'posts WHERE id='.implode(' OR id=',$posts));

                redirect('viewtopic.php?id='.$_GET['ptid'], $lang_misc['Posts supprimes']);
                break;

            }


        // Fusionner des posts
        case 'fusion' :

            if(!isset($_POST['confirm'])) {

                //confirm_referrer('viewtopic.php'); // Bug IE
                $page_title = pun_htmlspecialchars($pun_config['o_board_title']).' / '.$lang_misc['Moderate'];
                require PUN_ROOT.'header.php';

                ?> <div class="blockform">
                    <h2><?php echo $lang_misc['Fusionner posts'] ?></h2>
                    <div class="box">
                        <form method="post" action="moderate.php?fid=<?php echo $fid ?>&ptid=<?php echo $_GET['ptid'] ?>&actionposts=fusion">
                            <input type="hidden" name="posts" value="<?php echo urlencode($posts) ?>" />
                            <div class="inform">
                                <fieldset>
                                    <legend><?php echo $lang_misc['Confirmer'] ?></legend>
                                    <div class="infldset">
                                        <p><?php echo $lang_misc['Separer fusion'] ?><br />
                                        <textarea name="fusion_sep"></textarea><br />
                                        <br />
                                        <?php echo $lang_misc['Avertissement fusion'] ?>
                                    </div>
                                </fieldset>
                            </div>
                            <p><input type="submit" name="confirm" value="<?php echo $lang_misc['Fusionner posts ok'] ?>" /><a href="javascript:history.go(-1)"><?php echo $lang_common['Go back'] ?></a></p>
                        </form>
                    </div>
                </div> <?

                require PUN_ROOT.'footer.php';
                break;

            } else {

                confirm_referrer('moderate.php');
                $posts = unserialize(urldecode(stripslashes($_POST['posts'])));
                sort($posts);
                reset($posts);

                // On récupére et on concatène les différents messages
                $message_add = '';
                for($i=0; $i < count($posts); $i++)
                    $message_add .= $db->result($db->query('SELECT message FROM '.$db->prefix.'posts WHERE id='.$posts[$i])).$_POST['fusion_sep'];

                // On écrit la concaténation à la place du message du plus ancien post
                $db->query('UPDATE '.$db->prefix.'posts SET message="'.$message_add.'" WHERE id='.$posts[0]);

                // On supprime tous les messages sauf le plus ancien
                unset($posts[0]);
                if(!empty($posts))
                    $db->query('DELETE FROM '.$db->prefix.'posts WHERE id='.implode(' OR id=',$posts));

                redirect('viewtopic.php?id='.$_GET['ptid'], $lang_misc['Posts fusionnes']);
                break;

            }

By :

Code:

        // Déplacement de posts
        case 'move' :

            if(!isset($_POST['confirm'])) {

                //confirm_referrer('viewtopic.php'); // Bug IE
                $page_title = pun_htmlspecialchars($pun_config['o_board_title']).' / '.$lang_misc['Moderate'];
                require PUN_ROOT.'header.php';

                ?> <div class="blockform">
                    <h2><?php echo $lang_misc['Deplacer posts'] ?></h2>
                    <div class="box">
                        <form method="post" action="moderate.php?fid=<?php echo $fid ?>&ptid=<?php echo $_GET['ptid'] ?>&actionposts=move">
                            <input type="hidden" name="posts" value="<?php echo urlencode($posts) ?>" />
                            <div class="inform">
                                <fieldset>
                                    <legend><?php echo $lang_misc['Choisir topic'] ?></legend>
                                    <div class="infldset">
                                        <p><?php echo $lang_misc['Topic destination'] ?><br />
                                        <input type="text" style="width:50%" name="postsmoveto" /><br />
                                        <br />
                                        <input type="checkbox" name="anterieurs" value="1" /> <?php echo $lang_misc['Avertissement date'] ?></p>
                                    </div>
                                </fieldset>
                            </div>
                            <p><input type="submit" name="confirm" value="<?php echo $lang_misc['Deplacer posts ok'] ?>" /><a href="javascript:history.go(-1)"><?php echo $lang_common['Go back'] ?></a></p>
                        </form>
                    </div>
                </div> <?

                require PUN_ROOT.'footer.php';
                break;

            } else {

                confirm_referrer('moderate.php');
                require PUN_ROOT.'include/search_idx.php';

                // Extraction de l'id du topic de destination
                preg_match('/id=([0-9]+)/',$_POST['postsmoveto'], $postsmoveto);
                if(empty($postsmoveto[1]))
                    message($lang_misc['Erreur topic destination']);
                $posts = unserialize(urldecode(stripslashes($_POST['posts'])));

                $result = $db->query('SELECT id FROM '.$db->prefix.'posts WHERE topic_id='.$postsmoveto[1].' ORDER BY posted LIMIT 1');
                $topic_post_id = $db->result($result);
                for($i=0; $i < count($posts); $i++) {
                    // On réécrit les messages qui sont plus anciens que le topic ou tous si anterieurs a été coché pour avoir un id récent
                    if($posts[$i] < $topic_post_id || isset($_POST['anterieurs'])) {
                        $post = $db->fetch_assoc($db->query('SELECT * FROM '.$db->prefix.'posts WHERE id='.$posts[$i]));
                        $db->query('INSERT INTO '.$db->prefix.'posts(poster,poster_id,poster_ip,poster_email,message,hide_smilies,posted,edited,edited_by,topic_id) VALUES("'.$post['poster'].'", "'.$post['poster_id'].'", "'.$post['poster_ip'].'", '.(!isset($post['poster_email']) ? 'NULL' : '"'.$post['poster_email'].'"').', "'.$post['message'].'", "'.$post['hide_smilies'].'", "'.time().'", '.(!isset($post['edited']) ? 'NULL' : '"'.$post['edited'].'"').', '.(!isset($post['edited_by']) ? 'NULL' : '"'.$post['edited_by'].'"').', "'.$postsmoveto[1].'")');
                        // On supprime les doublons qui comportent l'ancienne date
                        delete_post($posts[$i], $_GET['ptid']);
                        // On supprime la clé du topic qui n'est plus à écrire
                        unset($posts[$i]);
                    }
                }

                // Si il reste des topic qui sont à insérer avec leur date initiale
                if(!empty($posts))
                    $db->query('UPDATE '.$db->prefix.'posts SET topic_id='.$postsmoveto[1].' WHERE id='.implode(' OR id=',$posts));

                redirect('viewtopic.php?id='.$postsmoveto[1], $lang_misc['Posts deplaces']);
                break;

            }


        // Supprimer des posts
        case 'delete' :

            if(!isset($_POST['confirm'])) {

                //confirm_referrer('viewtopic.php'); // Bug IE
                $page_title = pun_htmlspecialchars($pun_config['o_board_title']).' / '.$lang_misc['Moderate'];
                require PUN_ROOT.'header.php';

                ?> <div class="blockform">
                    <h2><?php echo $lang_misc['Supprimer posts'] ?></h2>
                    <div class="box">
                        <form method="post" action="moderate.php?fid=<?php echo $fid ?>&ptid=<?php echo $_GET['ptid'] ?>&actionposts=delete">
                            <input type="hidden" name="posts" value="<?php echo urlencode($posts) ?>" />
                            <div class="inform">
                                <fieldset>
                                    <legend><?php echo $lang_misc['Confirmer'] ?></legend>
                                    <div class="infldset">
                                        <p><?php echo $lang_misc['Confirmer suppression'] ?><br />
                                    </div>
                                </fieldset>
                            </div>
                            <p><input type="submit" name="confirm" value="<?php echo $lang_misc['Supprimer posts ok'] ?>" /><a href="javascript:history.go(-1)"><?php echo $lang_common['Go back'] ?></a></p>
                        </form>
                    </div>
                </div> <?

                require PUN_ROOT.'footer.php';
                break;

            } else {

                confirm_referrer('moderate.php');
                require PUN_ROOT.'include/search_idx.php';

                $posts = unserialize(urldecode(stripslashes($_POST['posts'])));

                // On vérifie que le post initial du topic ne fait pas partie de la sélection
                $result = $db->query('SELECT id FROM '.$db->prefix.'posts WHERE topic_id='.$_GET['ptid'].' ORDER BY posted LIMIT 1');
                $topic_post_id = $db->result($result);
                if(isset($posts[$topic_post_id]))
                    unset($posts[$topic_post_id]);

                // On supprime les topics concernés
                foreach($posts AS $post)
                    delete_post($post, $_GET['ptid']);

                redirect('viewtopic.php?id='.$_GET['ptid'], $lang_misc['Posts supprimes']);
                break;

            }


        // Fusionner des posts
        case 'fusion' :

            if(!isset($_POST['confirm'])) {

                //confirm_referrer('viewtopic.php'); // Bug IE
                $page_title = pun_htmlspecialchars($pun_config['o_board_title']).' / '.$lang_misc['Moderate'];
                require PUN_ROOT.'header.php';

                ?> <div class="blockform">
                    <h2><?php echo $lang_misc['Fusionner posts'] ?></h2>
                    <div class="box">
                        <form method="post" action="moderate.php?fid=<?php echo $fid ?>&ptid=<?php echo $_GET['ptid'] ?>&actionposts=fusion">
                            <input type="hidden" name="posts" value="<?php echo urlencode($posts) ?>" />
                            <div class="inform">
                                <fieldset>
                                    <legend><?php echo $lang_misc['Confirmer'] ?></legend>
                                    <div class="infldset">
                                        <p><?php echo $lang_misc['Separer fusion'] ?><br />
                                        <textarea name="fusion_sep"></textarea><br />
                                        <br />
                                        <?php echo $lang_misc['Avertissement fusion'] ?>
                                    </div>
                                </fieldset>
                            </div>
                            <p><input type="submit" name="confirm" value="<?php echo $lang_misc['Fusionner posts ok'] ?>" /><a href="javascript:history.go(-1)"><?php echo $lang_common['Go back'] ?></a></p>
                        </form>
                    </div>
                </div> <?

                require PUN_ROOT.'footer.php';
                break;

            } else {

                confirm_referrer('moderate.php');
                require PUN_ROOT.'include/search_idx.php';

                $posts = unserialize(urldecode(stripslashes($_POST['posts'])));
                sort($posts);
                reset($posts);

                // On récupére et on concatène les différents messages
                $message_add = '';
                for($i=0; $i < count($posts); $i++)
                    $message_add .= $db->result($db->query('SELECT message FROM '.$db->prefix.'posts WHERE id='.$posts[$i])).$_POST['fusion_sep'];

                // On écrit la concaténation à la place du message du plus ancien post
                $db->query('UPDATE '.$db->prefix.'posts SET message="'.$message_add.'" WHERE id='.$posts[0]);

                // On supprime tous les messages sauf le plus ancien
                unset($posts[0]);
                foreach($posts AS $post)
                    delete_post($post, $_GET['ptid']);

                redirect('viewtopic.php?id='.$_GET['ptid'], $lang_misc['Posts fusionnes']);
                break;

            }

Offline

 

#9 2005-07-22 20:58:01

a63548
New member
Registered: 2005-07-22
Posts: 8

Re: Complete Management of the posts 1.0

Thanks for the mod, but I get this error when trying to move/delete/amalgamate posts:

Code:

Parse error: parse error, unexpected T_STRING, expecting ')' in /home/.dapper/a63548/a63548.net/forum/lang/English/misc.php on line 70

Offline

 

#10 2005-07-25 19:41:15

ph4t
New member
Registered: 2005-07-25
Posts: 2

Re: Complete Management of the posts 1.0

The problem is in the lang file.. he forgot to had "\" before the ' which causes the problem..

Thanks for the mod Ju smile

Offline

 

#11 2005-07-25 19:43:01

ph4t
New member
Registered: 2005-07-25
Posts: 2

Re: Complete Management of the posts 1.0

Why can't I edit my post?

oh well, there another problem, it seems the posts counter does not update..
i tried to use Maintenance but it doesn't help..

Offline

 

#12 2005-08-13 06:28:33

Zoltor
Member
From: Minsk, Belarus
Registered: 2005-04-10
Posts: 19
Website

Re: Complete Management of the posts 1.0

I'm using Easy Poll mod.. Can you apply your mod to EasyPoll? what changes I must do in viewpoll.php?


Sorry for my english! roll

Offline

 

#13 2005-08-19 15:21:24

Arvid
New member
Registered: 2005-08-12
Posts: 9

Re: Complete Management of the posts 1.0

Exactly what i was looking for!

Unfortunately there seems to be a problem.. If i move a couple of posts to another thread the dates gets messed up, wich also messes up the order of the posts.

Is this the development of this mod still on?

(if so, beeing able to move the first post aswell into another topic would be nice..)

Offline

 

#14 2005-08-20 04:07:47

Bulgaricus
Member
From: Warsaw, Poland
Registered: 2005-05-12
Posts: 44
Website

Re: Complete Management of the posts 1.0

Arvid wrote:

(if so, beeing able to move the first post aswell into another topic would be nice..)

Yes this feature will be very useful for me too.


www.bulgaricus.com
All about Bulgaria in Polish

Offline

 

#15 2005-09-11 05:19:54

Bulgaricus
Member
From: Warsaw, Poland
Registered: 2005-05-12
Posts: 44
Website

Re: Complete Management of the posts 1.0

I upgraded my forum from 1.2.6 to 1.2.7 and the mod stopped working sad During the upgrade I uploaded only the changed files among which there were no files affected by this mod.


www.bulgaricus.com
All about Bulgaria in Polish

Offline

 

#16 2005-09-11 05:30:06

Smartys
Member
Registered: 2005-03-17
Posts: 332
Website

Re: Complete Management of the posts 1.0

What's not working about it?


Free PunBB Hosting - lots of mods, easy to customize

Offline

 

#17 2005-09-11 09:26:53

Bulgaricus
Member
From: Warsaw, Poland
Registered: 2005-05-12
Posts: 44
Website

Re: Complete Management of the posts 1.0

It was not working the move topic feature, but it is O.K. now smile


www.bulgaricus.com
All about Bulgaria in Polish

Offline

 

#18 2006-12-10 12:21:05

Andre
New member
Registered: 2006-12-10
Posts: 3

Re: Complete Management of the posts 1.0

Will this mod work with PunBB 1.2.14 ?

Offline

 

#19 2006-12-11 08:29:26

Romain
Member
From: 127.0.0.1
Registered: 2006-09-17
Posts: 23
Website

Re: Complete Management of the posts 1.0

Yes. big_smile

Offline

 

#20 2006-12-11 08:52:51

elbekko
Moderator
From: Leuven, Belgium
Registered: 2006-01-31
Posts: 1422

Re: Complete Management of the posts 1.0

I edited the post a little... to make it more understandable tongue
Added (merge) to the line where it says Amalgamate. Had to look it up myself tongue


FluxBB
dictionary.com on programming: The most fun you can have with your clothes on (although clothes are not mandatory).

Offline

 

#21 2006-12-11 12:15:50

Andre
New member
Registered: 2006-12-10
Posts: 3

Re: Complete Management of the posts 1.0

Is there any mod doing the same thing + topics merging ?

Offline

 

#22 2007-01-23 04:17:00

soulcreeper
Member
Registered: 2006-04-17
Posts: 28

Re: Complete Management of the posts 1.0

does anyone know if this mod is also compatible with the latest version of punBB forum software?

Offline

 

#23 2007-03-08 02:37:02

FBI
Member
Registered: 2007-02-28
Posts: 18

Re: Complete Management of the posts 1.0

Just installing this mod.
Work perfectly on version 1.2.14.

Installing tutorial here http://www.punres.org/files/projects/pr … 9/mod.html

Notes:
1. You will not find this, if you already install PunPortal smile
 

Code:

Line 350, after : 
        <ul><li><a href="index.php"><?php echo $lang_common['Index'] ?>

index.php & Index, already change to forum.php & Forum

2. I'll give you the English Translation from My French Friend "Ju" smile

Code:

LANG/ENGLISH/TOPIC.PHP
At the end, replace : 
);
By : 
,
'Select label'            =>    'Action Select',
'Select label groupe'        =>    'Selection management',
'Select Action'            =>    'Action',
'Select Deplacer'        =>    'Move posts',
'Select Supprimer'        =>    'Delete posts',
'Select Fusionner'        =>    'Merge posts'
);

Also, I try to translate another for more explanation.  This is important parts for Moderator and Admin. Sorry, My English smile

Code:

LANG/ENGLISH/MISC.PHP
At the end, replace : 
);
By : 
,
// Mass post management
'Erreur action'            =>    'Error: The action not available',
'Erreur posts selection'    =>    'Error: You are not select any post',
'Deplacer posts'        =>    'Move posts',
'Choisir topic'            =>    'Choose the destination topic (topic URL at your browser)',
'Topic destination'        =>    'Destination topic URL',
'Avertissement date'        =>    'Check this, if you want to apply and change the moved post to the current date and displaying the post at the bottom of new destination topic. If the moved post older than destination forum, it will change to today current date. So, it will not confusing the first topic and the destinatioan topic still has older date for first topic (Please consider in some case, the order of publication date will be respected and important)<br /><br /><strong>Caution</strong>, the older posts than the topic destination will be automatically placed at the end of topic target.',
'Deplacer posts ok'        =>    'Move',
'Erreur topic destination'    =>    'Error: The destination topic URL not valid',
'Posts deplaces'        =>    'The posts has been moved',
'Supprimer posts'        =>    'Delete posts',
'Confirmer'            =>    'Confirm',
'Confirmer suppression'        =>    'Confirm to delete the selected posts ?',
'Supprimer posts ok'        =>    'Delete',
'Posts supprimes'        =>    'The posts has been deleted',
'Fusionner posts'        =>    'Merge posts',
'Separer fusion'        =>    'Use ENTER to separate between posts<br>or use custom characters by',
'Avertissement fusion'        =>    '<strong>Note :</strong> The merged post, will have the older (first) post informations. Please check that merged posts must have same owner (poster)',
'Fusionner posts ok'        =>    'Merge',
'Posts fusionnes'        =>    'The posts has been merged'
);

Enjoy the new feature of Moderation..


PunBB, Simplicity has been easier than before
Smart is Simple. Fast is Smart. Think Fast, You'll be Smart..

PunBB & SMF Fans

Offline

 

#24 2007-07-16 13:29:47

AhmedAA
New member
Registered: 2007-05-16
Posts: 7

Re: Complete Management of the posts 1.0

I tried to aply this mod to modified russian pusBB 1.2.14 but it went quite strange.

When I open topic, I can see only first Post and no later posts. Also this post has no checkbox, but inputbox with action, move etc I have...

(I have succesful MovePost 1.2 but it has no mass move for now...)

Offline

 

#25 2007-07-16 17:18:27

AhmedAA
New member
Registered: 2007-05-16
Posts: 7

Re: Complete Management of the posts 1.0

OK - When I tried to aply Easy profile fields then I got the same problem and solved.

I just had "antispam" mod inside, so by carefuly looking on diferences I aplied what I did not have.

So with these two codes variations in viewtopic.php it is working for me (others who have clean PunBB version seems that should not have these problems):

Code:

$result = $db->query('SELECT u.id AS uid, u.email, u.title, u.url, u.location, u.use_avatar, u.signature, u.email_setting, u.num_posts, u.registered, u.admin_note, p.id, p.poster AS username, p.poster_id, p.poster_ip, p.poster_email, p.message, p.hide_smilies, p.posted, p.edited, p.edited_by, g.g_id, g.g_user_title, o.user_id AS is_online, spam.id AS spam_id FROM '.$db->prefix.'posts AS p INNER JOIN '.$db->prefix.'users AS u ON u.id=p.poster_id INNER JOIN '.$db->prefix.'groups AS g ON g.g_id=u.group_id LEFT JOIN '.$db->prefix.'online AS o ON (o.user_id=u.id AND o.user_id!=1 AND o.idle=0) LEFT JOIN '.$db->prefix.'spam_repository AS spam ON spam.post_id=p.id  WHERE p.topic_id='.$id.' ORDER BY p.id LIMIT '.$start_from.','.$pun_user['disp_posts'], false) or error('Unable to fetch post info', __FILE__, __LINE__, $db->error());

Code:

<h2><span><span class="conr">#<?php echo ($start_from + $post_count) ?>&nbsp; </span> <?php if($is_admmod && !$is_topic_post) : ?><input type="checkbox" name="ps<?php echo $cur_post['id'] ?>" class="postselection" /><?php endif; ?> <a href="viewtopic.php?pid=<?php echo $cur_post['id'].'#p'.$cur_post['id'] ?>"><?php echo format_time($cur_post['posted']) ?></a></span></h2>

Offline

 

Board footer

Based on PunBB
© Copyright 2002–2005 Rickard Andersson

© Copyright 2004–2006 Kristoffer Jansson

User contributed files are property of their respective owners.