vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.5 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=113)
-   -   Staff can Post Hidden Posts (https://vborg.vbsupport.ru/showthread.php?t=112718)

dakuda 05-09-2006 10:15 PM

Quote:

Originally Posted by kall
Probably due to the can_moderate thing being called for people who can moderate.

(The confusion arises when you refer to a product as a plugin.)

One of these days I will get the whole product/plugin thing straight in my head. I see things in the plugin section and that just sticks in my head... ANyway:

I used the code from post 35, and did not use the navbar changes at all.

So, since a missing index seems to be the suggested fix, uh, this is where I sound stupid.

Is there an easy way to fix the missing index?

Xenon 05-14-2006 01:36 PM

well, it's a question what index is missing ;)

most likely it's on dateline or the visible field

Pyrix 08-04-2006 10:39 PM

Anyone had any luck getting this to work with 3.6.0?

Paul M 08-04-2006 11:20 PM

It won't work with 3.6 without a modification to one of the plugins - the deletionlog table has had a dateline column added to it in 3.6 - therefore you will get an sql error.

Pyrix 08-11-2006 09:52 PM

Got it working ok... Only main difference is, as Paul said, one of the queries needs to be changed otherwise you get a problem with ambiguity.

PHP Code:

    $posts $db->query_first("
        SELECT COUNT(postid) AS count
        FROM " 
TABLE_PREFIX "post AS post
        LEFT JOIN " 
TABLE_PREFIX "deletionlog AS deletionlog ON(deletionlog.primaryid = post.postid AND type = 'post')
        WHERE visible = 0 AND dateline > " 
$vbulletin->userinfo[lastvisit] . "
            AND deletionlog.primaryid IS NULL
    "
); 

becomes...

PHP Code:

    $posts $db->query_first("
        SELECT COUNT(postid) AS count
        FROM " 
TABLE_PREFIX "post AS post
        LEFT JOIN " 
TABLE_PREFIX "deletionlog AS deletionlog ON(deletionlog.primaryid = post.postid AND type = 'post')
        WHERE visible = 0 AND post.dateline > " 
$vbulletin->userinfo[lastvisit] . "
            AND deletionlog.primaryid IS NULL
    "
); 


kall 08-28-2006 01:42 AM

Quote:

Originally Posted by Pyrix
Got it working ok... Only main difference is, as Paul said, one of the queries needs to be changed otherwise you get a problem with ambiguity.

PHP Code:

    $posts $db->query_first("
        SELECT COUNT(postid) AS count
        FROM " 
TABLE_PREFIX "post AS post
        LEFT JOIN " 
TABLE_PREFIX "deletionlog AS deletionlog ON(deletionlog.primaryid = post.postid AND type = 'post')
        WHERE visible = 0 AND dateline > " 
$vbulletin->userinfo[lastvisit] . "
            AND deletionlog.primaryid IS NULL
    "
); 

becomes...

PHP Code:

    $posts $db->query_first("
        SELECT COUNT(postid) AS count
        FROM " 
TABLE_PREFIX "post AS post
        LEFT JOIN " 
TABLE_PREFIX "deletionlog AS deletionlog ON(deletionlog.primaryid = post.postid AND type = 'post')
        WHERE visible = 0 AND post.dateline > " 
$vbulletin->userinfo[lastvisit] . "
            AND deletionlog.primaryid IS NULL
    "
); 


Pyrix,

Those 2 code blocks are the same..

Shahed 09-11-2006 09:23 PM

you must open product-xen_hidden_posts.xml with a plane text editor.
find:
PHP Code:

WHERE visible AND dateline " . $vbulletin->userinfo[lastvisit] . " 

and replace with :
PHP Code:

WHERE visible AND post.dateline " . $vbulletin->userinfo[lastvisit] . " 

Now you can Upload the new Product File and apply Template Modifications.

Enjoy it with 3.6 !

rms-2004 11-06-2006 04:00 PM

Is there any port of "Hidden Posts advanced" with editpost (make it visible/invisible)?
How to set a color to the hidden posts to warn a staff member? Thanks.

rms-2004 02-16-2007 04:25 PM

Anyone have the editpost part for this mod?

tspepper 03-16-2007 12:36 AM

THANK YOU! With the changes below, I am able to have this run perfectly in 3.6!

Quote:

Originally Posted by Zachery (Post 955770)
I'd suggest moving the bit of code to below the regular options, as $threadinfo[open] is not avaible in the showthread_quickreply template

find in the showthread template.
Code:

<label for="qr_quickreply"><input type="checkbox" name="quickreply" value="1" id="qr_quickreply" accesskey="w" tabindex="4" />$vbphrase[quote_message_in_reply]</label>
                                                </div>

Add after
Code:

<if condition="is_member_of($bbuserinfo, 5,6,7)"><fieldset class="fieldset" style="margin:$stylevar[formspacer]px 0px 0px 0px"><legend>Moderatory Options</legend>        <div>
        <label for="cb_hidepost" style="float:$stylevar[left]"><input type="checkbox" name="hidepost" value="1" id="cb_hidepost" />Hide Post?</label>
        <div style="float:$stylevar[right]">
                <label for="cb_openclose"><input type="checkbox" name="openclose" value="1" id="cb_openclose" /><if condition="$threadinfo['open']">Close<else />Open</if> Thread</label>$threadinfo[open]
        </div>
</div></fieldset></if>


Quote:

Originally Posted by Shahed (Post 1072945)
you must open product-xen_hidden_posts.xml with a plane text editor.
find:
PHP Code:

WHERE visible AND dateline " . $vbulletin->userinfo[lastvisit] . " 

and replace with :
PHP Code:

WHERE visible AND post.dateline " . $vbulletin->userinfo[lastvisit] . " 

Now you can Upload the new Product File and apply Template Modifications.

Enjoy it with 3.6 !



All times are GMT. The time now is 08:15 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.01273 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_code_printable
  • (8)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (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