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)
-   -   Reason for Closing Thread (https://vborg.vbsupport.ru/showthread.php?t=69625)

WhSox21 09-19-2004 04:41 PM

How did you get that error? That should not happen. I made it so that if you did not fill in a reason it would not display. What were the steps you took to do that? Did you click cancel or ok or how did you do it?

EDIT:
Are you sure you did all the steps in the install? Are you sure you edited postings.php file correctly?

alqafelah 09-19-2004 04:48 PM

oh, yes .. your right .. i'm clicked Cancel ! with click Ok no problem .

thanks for support me :)

WhSox21 09-19-2004 04:52 PM

If you click cancel you shouldn't recieve that either.

alqafelah 09-19-2004 04:58 PM

that is what happened for me !

if i not write reason and click OK it's not display anything .. if CANCEL it's display !

WhSox21 09-19-2004 05:01 PM

What version of vb are you using? Can you post me lines 165-182 of your postings.php file? It's not doing that for me when I click cancel nor should it for you. There is something wrong with your install or something.

alqafelah 09-19-2004 05:10 PM

i'm using 3.03 ..
i will reinstall this hack and take what you request : ( all open/close section )

PHP Code:

// ############################### start do open / close thread ###############################
if ($_POST['do'] == 'openclosethread')
{
    
// permission check
    
if (!can_moderate($threadinfo['forumid'], 'canopenclose'))
    {
        
$forumperms fetch_permissions($threadinfo['forumid']);
        if (!(
$forumperms CANVIEW) OR !($forumperms CANOPENCLOSE))
        {
            
print_no_permission();
        }
        else
        {
            if (!
is_first_poster($threadid))
            {
                
print_no_permission();
            }
        }
    }

    
// check if there is a forum password and if so, ensure the user has it set
    
verify_forum_password($foruminfo['forumid'], $foruminfo['password']);

    if (
$threadinfo['open'])
    {
        
$threadinfo['open'] = 0;
        
$logaction $vbphrase['closed_thread'];
        
$action $vbphrase['closed'];
    }
    else
    {
        
$threadinfo['open'] = 1;
        
$logaction $vbphrase['opened_thread'];
        
$action $vbphrase['opened'];
        
$_POST['reason'] = null;
    }

    
log_moderator_action($threadinfo$logaction);

    
$DB_site->query("UPDATE " TABLE_PREFIX "thread SET open = $threadinfo[open], reason = '" addslashes($_POST[reason]) . "' WHERE threadid = $threadid");

    
$_REQUEST['forceredirect'] = 1;
    
$url "showthread.php?$session[sessionurl]t=$threadid";
    eval(
print_standard_redirect('redirect_openclose'));

}

// ############################### start delete thread ############################### 


WhSox21 09-19-2004 05:12 PM

Well, that file is correct. I'll see if I can't figure something else out?

WhSox21 09-19-2004 05:16 PM

I figured it out. It's related to IE. You can do this to simply fix the problem:
postings.php
***************
Code:

FIND:
-------------------
                $action = $vbphrase['closed'];
-------------------
BELOW IT ADD:
-------------------
                if($_POST['reason'] == 'null') $_POST['reason'] = null;


shadiguy1 09-19-2004 05:19 PM

i installed it the box pops up But after wards there is no reason listed for closing thread.

WhSox21 09-19-2004 05:21 PM

Did you add the hidden field in showthread template?


All times are GMT. The time now is 01:11 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.01035 seconds
  • Memory Usage 1,749KB
  • 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_code_printable
  • (1)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)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