Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.0 > vBulletin 3.0 Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Customized Forum Closed Screen Details »»
Customized Forum Closed Screen
Version: 1.01, by Michael Morris Michael Morris is offline
Developer Last Online: Jun 2009 Show Printable Version Email this Page

Version: 3.0.3 Rating:
Released: 12-24-2004 Last Update: Never Installs: 15
 
No support by the author.

By default the vbulletin closed screen is a simple message with the standard header and footer for the boards. You can change this to a different page entirely with this hack.

This hack requires you to create a new template entirely and install a slight modification in your global.php file.

The file modification is as follows:

Search for this code.
PHP Code:
// #############################################################################
// check that board is active - if not admin, then display error
if (!$vboptions['bbactive'] AND THIS_SCRIPT != 'login')
{
    if (!(
$permissions['adminpermissions'] & CANCONTROLPANEL))
    {
        eval(
'standard_error("' str_replace("\'""'"addslashes($vboptions['bbclosedreason'])) . '");');
        unset(
$shutdownqueries['lastvisit']); 
Comment out the eval('standard_error.... line and place this below the unset($shutdownque.... line.
PHP Code:
eval('print_output("' fetch_template('boards_closed') . '");'); 
The finished code, assuming you have no other hacks in this section of the code, will look like this:

PHP Code:
// #############################################################################
// check that board is active - if not admin, then display error
if (!$vboptions['bbactive'] AND THIS_SCRIPT != 'login')
{
    if (!(
$permissions['adminpermissions'] & CANCONTROLPANEL))
    {
        
//eval('standard_error("' . str_replace("\'", "'", addslashes($vboptions['bbclosedreason'])) . '");');
        
unset($shutdownqueries['lastvisit']);
        eval(
'print_output("' fetch_template('boards_closed') . '");'); 
Now create a new template called boards_closed. This can be any html document you want and you can of course call some of the variables from vbulletin.

If you want the boards closed reason to appear in the page you'll need to include $vboptions[bbclosedreason] somewhere in the file.

Below is a very simple template that will include the reason on a blank page.

HTML Code:
<html>
<body>
$vboptions[bbclosedreason]
</body>
</html>
From this model you can build up a page. Attached is a screenshot of ENWorld's closing screen using this modification.

Supporters / CoAuthors

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #2  
Old 12-25-2004, 09:26 AM
MrNase MrNase is offline
 
Join Date: May 2003
Location: Germany
Posts: 670
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you for sharing it with us
Reply With Quote
  #3  
Old 12-25-2004, 11:10 AM
error_22 error_22 is offline
 
Join Date: Nov 2004
Location: Stockholm, Sweden
Posts: 108
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

cool, thanks for sharing *clicks install*
Reply With Quote
  #4  
Old 12-25-2004, 01:48 PM
moley's Avatar
moley moley is offline
 
Join Date: Sep 2002
Location: England
Posts: 78
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

thanks a lot the vb default is so boring will be fun to make a new one.
Reply With Quote
  #5  
Old 12-25-2004, 04:14 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Why didn't you include this in your code replacement?
PHP Code:
        unset($shutdownqueries['lastvisit']); 
Reply With Quote
  #6  
Old 12-25-2004, 06:46 PM
Red Blaze's Avatar
Red Blaze Red Blaze is offline
 
Join Date: Jan 2003
Location: Texas
Posts: 493
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Very cool, I'll definatly have this in my to-do list.
Reply With Quote
  #7  
Old 12-25-2004, 07:32 PM
Michael Morris's Avatar
Michael Morris Michael Morris is offline
 
Join Date: Nov 2003
Location: Knoxville TN
Posts: 774
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Boofo
Why didn't you include this in your code replacement?
PHP Code:
        unset($shutdownqueries['lastvisit']); 
The print_output function doesn't check this variable and that function terminates the script. Hence the line isn't necessary (as far as I'm aware) - though there is no harm in it's inclusion.
Reply With Quote
  #8  
Old 01-01-2005, 05:55 PM
The Ghost's Avatar
The Ghost The Ghost is offline
 
Join Date: Feb 2002
Posts: 57
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi,

I get only a white Page?

Greetz
Reply With Quote
  #9  
Old 01-01-2005, 06:35 PM
Michael Morris's Avatar
Michael Morris Michael Morris is offline
 
Join Date: Nov 2003
Location: Knoxville TN
Posts: 774
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You have to create a new template for your custom forum closed screen named boards_closed. This can be any XML document you like - but it has to be loaded into the template boards_closed
Reply With Quote
  #10  
Old 01-01-2005, 06:44 PM
Dan's Avatar
Dan Dan is offline
 
Join Date: Dec 2002
Location: Titusville, Florida
Posts: 1,787
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I like this mod Thanks for sharing it with us
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07:39 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04772 seconds
  • Memory Usage 2,308KB
  • Queries Executed 24 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_html
  • (5)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete