vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Hide Post Delete Option Hack Ver. 1.0 (https://vborg.vbsupport.ru/showthread.php?t=40861)

Birdie501 07-10-2002 09:51 AM

Ok thanks! Even if only you will use it , it was worth to make it :)

Darren Lewis 07-10-2002 10:00 AM

I'll play around with a clean fresh install of vbulletin on my local PC and maybe drop a comment to Jelsoft about it if I still get the same. My online vb has been hacked a little so this may be interfering with things - can't see how though.

Cheers,

Darren

Boofo 07-10-2002 10:17 AM

Will this hack work with the WYSIWYG hack?

Quote:

Originally posted by Birdie501
Darren do you have any hacks installed that uses different editpost templates like the wysiwyg hack? and did you try with my code?

Birdie501 07-10-2002 10:35 AM

Yes it will, but you don't need this hack. This function is already included in vb. You just have to disable the function 'can delete post" in admin Cp for the specific usergroup.

Boofo 07-10-2002 10:42 AM

I already did that but I never tried to log on under one of the groups I disabled it for to see if the button still shows up. Does the button show up if it is turned off?

Quote:

Originally posted by Birdie501
Yes it will, but you don't need this hack. This function is already included in vb. You just have to disable the function 'can delete post" in admin Cp for the specific usergroup.

Birdie501 07-10-2002 10:53 AM

Nothing will be shown.

Boofo 07-10-2002 10:56 AM

You mean if I use this hack, nothing will be shown, right? Because I just tested it without the hack and the button is still there. :)

Quote:

Originally posted by Birdie501
Nothing will be shown.

Birdie501 07-10-2002 11:02 AM

Normally nothing will be shown if you turned it off!
Also if you use my code nothing will be shown! :)

Boofo 07-10-2002 11:31 AM

The delete button is still there (without your hack installed) even if it is turned off. It just gives you the "Can't delete" error message. If your hack is installed, the button is NOT shown. It works great for that part of it. But if you have the WYSIWYG hack installed, it is still shown in there unless I put the $deletepost in there. Then it doesn't show. But is also doesn't show even if you are allowed to delete messages in the WYSIWYG editor for some reason. Any ideas on how to make it work for that too? :)

Birdie501 07-10-2002 11:48 AM

Quote:

Originally posted by Boofo
The delte button is still there (without your hack installed) even if it is turned off. It just gives you the "Can't delete" error message. If your hack is installed, the button is NOT shown. It works great for that part of it. But if you have the WYSIWYG hack installed, it is still shown in there unless I put the $deletepost in there. Then it doesn't show. But is also doesn't show even if you are allowed to delete messages in the WYSIWYG editor for some reason. Any ideas on how to make it work for that too? :)
in editpost.php i have this and it works:


PHP Code:


if ( ($enableHTMLEdit == 1) AND ( ($bbuserinfo['enablewysiwyg']) ) ) {
if ( (
$bbuserinfo[usergroupid] == 6) OR (ismoderator($threadinfo[forumid],"candeleteposts")) ){
    eval(
"\$deletepost = \"".gettemplate("editpost_delete")."\";");
    } else {
    
$deletepost "";
    } 
 eval(
"dooutput(\"".gettemplate("editpost_wysiwyg")."\");");
  } else {

if ( (
$bbuserinfo[usergroupid] == 6) OR (ismoderator($threadinfo[forumid],"candeleteposts")) ){
    eval(
"\$deletepost = \"".gettemplate("editpost_delete")."\";");
    } else {
    
$deletepost "";
    }  
eval(
"dooutput(\"".gettemplate("editpost")."\");");
  } 

of course as you said you have to put $deletepost in template editpost_wysiwyg and delete the part of the form.


All times are GMT. The time now is 11:06 AM.

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.01181 seconds
  • Memory Usage 1,748KB
  • 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
  • (1)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)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