vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Inline Moderation Tools (v1.2.1) (https://vborg.vbsupport.ru/showthread.php?t=68791)

rob_daemon 12-04-2004 11:10 AM

Quote:

Originally Posted by sv1cec
I have one question. An admin of one forum cannot delete a thread from the forumdisplay, while he can from the thread tools within the thread. I checked your code in inlinemod.php and it appears that you are using the following conditional:

PHP Code:

if (!can_moderate($vars['forumid'], 'canremoveposts'))
{
    
print_no_permission();


Wouldn't that check for permanent deletion? I suppose that you should use candeleteposts, instead of canremoveposts, but I am not sure. Can you please clarify?

Rgds and tnx

Thanks for catching that. It should be candeleteposts, not canremoveposts; hard delete is a separate entity.

Dean C 12-04-2004 11:18 AM

Thankyou for sharing your work with the community :)

sv1cec 12-07-2004 07:16 AM

Quote:

Originally Posted by Dean C
Thankyou for sharing your work with the community :)

Do we have an ETA for the merge threads option?

Tnx
---------
John

rob_daemon 12-07-2004 01:48 PM

Quote:

Originally Posted by sv1cec
Do we have an ETA for the merge threads option?

Tnx
---------
John

Merging threads is in the next version. I was planning to release it last night, but after six hours of homework I really wasn't up for it. Should be updated this evening.

sv1cec 12-07-2004 02:21 PM

Quote:

Originally Posted by rob_daemon
Merging threads is in the next version. I was planning to release it last night, but after six hours of homework I really wasn't up for it. Should be updated this evening.

Thanks for your response, I know it is hard for you, given your school obligations.

No hurry for me, I came up with my own version, but I would be interested to see how it compares with yours. If you need the code, please let me know.

Rgds
-----------
John

sv1cec 12-08-2004 06:12 AM

I am not sure if someone would be interested in that, but I noticed that if you do a search and come up with the results, then you do an inline moderation action, like delete a thread (supposing you are allowed to do that), then you are no longer returned to the search results, but to the forums home page.

That bothered me, since I use the search to find all posts since yesterday, and I want to return there to check for more.

What I came up with, is that you may catch up the fact that you called the inlinemod.php from the search results, and have the program return you there. All you have to do is to pass a hidden parameter from the search_results template form to inlinemod.php.

Here is what you have to do:

Open your search_results template and find:

HTML Code:

<input type="hidden" name="unsafe" value="1" />
Right below that, add:

HTML Code:

<input type="hidden" name="searchid" value="$searchid" />
Save the template. Now open your inlinemod.php file and find:

PHP Code:

if ($_POST['type'] == 'thread')
{
    
// Set our globals
    
$vars['inlineid'] = htmlspecialchars_uni($_COOKIE['bbinlineid']);
    
$vars['forumid'] = intval(end(explode('_'$vars['inlineid'])));
    
$vars['action'] = htmlspecialchars_uni($_POST['inlinemodact']);
    
$vars['forum'] = fetch_foruminfo($vars['forumid']); 

Right below that, add:

PHP Code:

    $searchid=$_POST['searchid']; 

Further down in the same file, find:

PHP Code:

if ($vars['forumid'])
    {
        
$url "forumdisplay.php?$session[sessionurl]f=$vars[forumid]&mod=1";
    } 

Replace all occurences of that piece of code, with:

PHP Code:

if ($vars['forumid'])
    {
            
$url "forumdisplay.php?$session[sessionurl]f=$vars[forumid]&mod=1";
    }
if (
$searchid!='')
    {
        
$url "search.php?searchid=$searchid";
    } 

Now everytime you went to inlinemod.php from a search results page, you will be returned to your search results, after the inline moderation action is completed.

Rgds
---------
John

rob_daemon 12-08-2004 06:16 AM

Alrighty! At long last, here it is! Inline Moderation Tools 1.2.0 should resolve all of the JavaScript users were having. Check boxes now only display when they need to, all templates are now cached, thread merging has been added (however, threads with polls it will not merge because it was too much work to figure out all of that logic), it removed search results moderation (sorry but this was a security hole that needed to be closed (if you want it enabled, I can explain how for you)), and a few other various fixes.

Upgrade instructions as well as fresh install ones are in the ZIP. Don't forget to click install!

sv1cec 12-08-2004 07:48 AM

Quote:

Originally Posted by rob_daemon
Alrighty! At long last, here it is! Inline Moderation Tools 1.2.0 should resolve all of the JavaScript users were having. Check boxes now only display when they need to, all templates are now cached, thread merging has been added (however, threads with polls it will not merge because it was too much work to figure out all of that logic), it removed search results moderation (sorry but this was a security hole that needed to be closed (if you want it enabled, I can explain how for you)), and a few other various fixes.

Upgrade instructions as well as fresh install ones are in the ZIP. Don't forget to click install!

Terrific,

Just change your instruction in global.php, it should say:

PHP Code:

if (THIS_SCRIPT == 'showthread' OR THIS_SCRIPT == 'forumdisplay')
{
    
$show['inlinemod'] = true;
}
else
{
    
$show['inlinemod'] = false;


you use forumdisplay.php, while the script name is forumdisplay.

Rgds

Revan 12-08-2004 09:05 AM

Great, thanks for the update :) And thank you for that fix sv1, dunno if I'd notice that on my own, well now we dont have to find out ;)

Small suggestion: Getting rid of the .DS_Store files to save zip space :p
PS: I just wanted to say, whatever you did to the install HTML file, thank you! You have no idea how great it is to be able to use Crtl+A inside a textarea to fetch only the text inside that :D Oooh me happy now :D
*ahem*
Ill go away now :p

WebMasterAJ 12-08-2004 12:00 PM

Hello -

I've installed this hack, but for some reason nothing displays at all. Am I supposed to activate it someway?

Please let me know!

Thank you for your time and energy!


All times are GMT. The time now is 12:06 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02385 seconds
  • Memory Usage 1,768KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_html_printable
  • (6)bbcode_php_printable
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete