Version 3.1.4

This commit is contained in:
Neo committed 2025-12-19 00:32:22 -08:00
1 parent 1d4720f3e2
commit ae5c01cc78
2563 files changed
+283048 -240689

No files matched your search

@@ -1,17 +1,19 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.0.5
* IP.Board v3.1.4
* Admin Output Library
* Last Updated: $LastChangedDate: 2009-10-23 21:23:07 -0400 (Fri, 23 Oct 2009) $
* Last Updated: $LastChangedDate: 2010-10-11 20:21:22 -0400 (Mon, 11 Oct 2010) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.iinvisionpower.com/community/board/license.html
* @package Invision Power Board
* @link http://www.iinvisionpower.com
* @version $Rev: 5283 $
* @license http://www.invisionpower.com/community/board/license.html
* @package IP.Board
* @link http://www.invisionpower.com
* @version $Rev: 6962 $
*
*/
@@ -40,8 +42,6 @@ class adminOutput extends output
* @var string
*/
public $html = '';
public $html_help_title = '';
public $html_help_msg = '';
public $html_main = '';
public $body_extra = '';
public $cm_output = '';
@@ -78,7 +78,7 @@ class adminOutput extends output
* Global messages
*
* @access public
* @access string
* @var string
*/
public $global_message;
public $global_error;
@@ -115,6 +115,14 @@ class adminOutput extends output
* @var string
*/
public $default_tab = '';
/**
* Any extra HTML to stick in the sidebar
*
* @access public
* @var string
*/
public $sidebar_extra = '';
/**
* Constructor
@@ -201,7 +209,7 @@ class adminOutput extends output
}
else
{
$this->showError( "Не удалось загрузить шаблон: $template", 4100, true );
$this->showError( sprintf( $this->lang->words['notemplatefiletoload'], $template ), 4100, true );
}
}
@@ -272,14 +280,13 @@ class adminOutput extends output
if ( ipsRegistry::$current_module )
{
$this->html_title .= " &gt; " . ipsRegistry::$modules_by_section [ ipsRegistry::$current_application ][ ipsRegistry::$current_module ]['sys_module_title'];
$this->html_title .= " &gt; " . ipsRegistry::$modules_by_section[ ipsRegistry::$current_application ][ ipsRegistry::$current_module ]['sys_module_title'];
}
}
$html = str_replace( '<%CONTENT%>' , $this->html , $this->global_template->global_main_popup_wrapper() );
$html = str_replace( "<%TITLE%>" , $this->html_title , $html );
$html = str_replace( "<%BODYEXTRA%>" , ' '.$this->body_extra , $html );
$html = preg_replace( "#{txt\.(.+?)}#e", "IPSText::\$words['\\1']", $html );
$html = str_replace( '<%CONTENT%>' , $this->html , $this->global_template->global_main_popup_wrapper() );
$html = str_replace( "<%TITLE%>" , $this->html_title , $html );
$html = str_replace( "<%BODYEXTRA%>", ' ' . $this->body_extra , $html );
print $html;
exit();
@@ -392,7 +399,7 @@ class adminOutput extends output
{
$this->_sendOutputSetUp( 'redirect' );
$this->html .= "<iframe src='$url' scrolling='auto' border='0' frameborder='0' width='100%' height='400'></iframe>";
$this->html .= "<iframe src='{$url}' scrolling='auto' border='0' frameborder='0' width='100%' height='400'></iframe>";
$this->html_main .= $this->global_template->global_frame_wrapper();
$this->sendOutput();
@@ -434,9 +441,10 @@ class adminOutput extends output
* @param integer Error code
* @param boolean Log error message
* @param string Extra log data
* @param integer Header code to send (ignored for ACP)
* @return void
*/
public function showError( $message, $code=0, $logError=FALSE, $logExtra='' )
public function showError( $message, $code=0, $logError=FALSE, $logExtra='', $header=500 )
{
$this->_sendOutputSetUp( 'error' );
@@ -537,109 +545,51 @@ class adminOutput extends output
}
//-----------------------------------------
// Sticky tabs
// Context sensitive stuff
//-----------------------------------------
$this->member->setProperty( 'global_sticky_tabs', is_array( $this->memberData['global_sticky_tabs'] ) ? $this->memberData['global_sticky_tabs'] : array() );
//-----------------------------------------
// Keith's help mode (tm)
//-----------------------------------------
if( $this->settings['acp_tutorial_mode'] )
if( !$this->cm_output )
{
/* Is this a non IPS app? */
if ( $this->request['app'] == 'subscriptions' OR ! strstr( IPSLib::getAppDir( $this->request['app'] ), '/other/' ) )
{
// Decided to use request instead of (e.g.) ipsRegistry::$current_application to make it easier for us to map.
// We can change in the future if it's preferred
$check_key = $this->request['app'] . '_' . $this->request['module'] . '_' . $this->request['section'] . '_' . $this->request['do'] . '_';
if ( $this->request['groupHelpKey'] )
{
$check_key .= $this->request['groupHelpKey'];
}
$help .= $this->global_template->help_box( $check_key );
}
else
{
$this->settings['acp_tutorial_mode'] = 0;
}
}
//-----------------------------------------
// Start function proper
//-----------------------------------------
if ( $no_wrapper === FALSE )
{
//-----------------------------------------
// Context sensitive stuff
//-----------------------------------------
if( !$this->cm_output )
{
$_file = IPS_APPLICATION_PATH . 'skin_cp/cp_skin_' . $clean_module . '_context_menu.php';
$_class = 'cp_skin_' . $clean_module . '_context_menu';
if ( file_exists( $_file ) )
{
require $_file;
$context_menu = new $_class( $this->registry );
$cm_function_full = ipsRegistry::$request['do'] ? 'context_menu__' . $clean_module.'__'.ipsRegistry::$request['section'].'__'.ipsRegistry::$request['do'] : 'context_menu__' . $clean_module.'__'.ipsRegistry::$request['section'];
$cm_function = 'context_menu__' . $clean_module.'__'.ipsRegistry::$request['section'];
$cm_module = 'context_menu__' . $clean_module;
if ( method_exists( $_class, $cm_function_full ) )
{
$this->cm_output = $context_menu->__wrap( $context_menu->$cm_function_full() );
}
else if ( method_exists( $_class, $cm_function ) )
{
$this->cm_output = $context_menu->__wrap( $context_menu->$cm_function() );
}
else if ( method_exists( $_class, $cm_module ) )
{
$this->cm_output = $context_menu->__wrap( $context_menu->$cm_module() );
}
else
{
if( ipsRegistry::$request['section'] != 'dashboard' && ipsRegistry::$request['do'] != 'index' )
{
$this->cm_output = $this->global_template->no_context_menu();
}
}
}
else
{
$this->cm_output = $this->global_template->no_context_menu();
}
}
//-----------------------------------------
// Global Context Menu Stuff
//-----------------------------------------
$_file = IPS_ROOT_PATH . "skin_cp/cp_skin_global_context_menu.php";
$_file = IPSLib::getAppDir( IPS_APP_COMPONENT ) . '/skin_cp/cp_skin_' . $clean_module . '_context_menu.php';
$_class = 'cp_skin_' . $clean_module . '_context_menu';
if ( file_exists( $_file ) )
{
require_once $_file;
require $_file;
$global_context = new cp_skin_global_context_menu( $this->registry );
$global_context_output = $global_context->get();
$context_menu = new $_class( $this->registry );
$cm_function_full = ipsRegistry::$request['do'] ? 'context_menu__' . $clean_module.'__'.ipsRegistry::$request['section'].'__'.ipsRegistry::$request['do'] : 'context_menu__' . $clean_module.'__'.ipsRegistry::$request['section'];
$cm_function = 'context_menu__' . $clean_module.'__'.ipsRegistry::$request['section'];
$cm_module = 'context_menu__' . $clean_module;
if ( method_exists( $_class, $cm_function_full ) )
{
$this->cm_output = $context_menu->__wrap( $context_menu->$cm_function_full() );
}
else if ( method_exists( $_class, $cm_function ) )
{
$this->cm_output = $context_menu->__wrap( $context_menu->$cm_function() );
}
else if ( method_exists( $_class, $cm_module ) )
{
$this->cm_output = $context_menu->__wrap( $context_menu->$cm_module() );
}
else
{
if( ipsRegistry::$request['section'] != 'dashboard' && ipsRegistry::$request['do'] != 'index' )
{
$this->cm_output = $this->global_template->no_context_menu();
}
}
}
else
{
$this->cm_output = $this->global_template->no_context_menu();
}
}
$html = str_replace( '<%CONTENT%>', $this->html_main, $this->global_template->global_main_wrapper(IPS_DOC_CHAR_SET, $this->_css ) );
}
else
{
$html = str_replace( '<%CONTENT%>', $this->html_main, $this->global_template->global_main_wrapper_no_furniture(IPS_DOC_CHAR_SET, $this->_css ) );
}
$html = str_replace( '<%CONTENT%>', $this->html_main, $this->global_template->global_main_wrapper(IPS_DOC_CHAR_SET, $this->_css ) );
//------------------------------------------------
// Message in a bottle?
@@ -657,17 +607,6 @@ class adminOutput extends output
$message .= ( $message ) ? '<br />' . $this->global_template->global_message() : $this->global_template->global_message();
}
//------------------------------------------------
// Help?
//------------------------------------------------
/*if ( isset( $this->html_help_title ) AND isset( $this->html_help_msg ) AND $this->html_help_title != '' )
{
$help = $this->global_template->information_box( $this->html_help_title, $this->html_help_msg ) . "<br >";
}*/
//-----------------------------------------
// Figure out title...
//-----------------------------------------
@@ -680,7 +619,7 @@ class adminOutput extends output
if ( ipsRegistry::$current_module )
{
$this->html_title .= " &gt; " . ipsRegistry::$modules_by_section [ ipsRegistry::$current_application ][ ipsRegistry::$current_module ]['sys_module_title'];
$this->html_title .= " &gt; " . ipsRegistry::$modules_by_section[ ipsRegistry::$current_application ][ ipsRegistry::$current_module ]['sys_module_title'];
}
}
@@ -708,13 +647,12 @@ class adminOutput extends output
$html = str_replace( "<%TITLE%>" , $this->html_title, $html );
$html = str_replace( "<%SUBMENU%>" , $this->_buildSubMenu() , $html ); # Must be called first
$html = str_replace( "<%MENU%>" , $this->_buildMenu() , $html );
$html = str_replace( "<%SIDEBAR_EXTRA%>" , $this->sidebar_extra , $html );
$html = str_replace( "<%CONTEXT_MENU%>" , $this->cm_output , $html );
$html = str_replace( "<%GLOBAL_CONTEXT_MENU%>", $global_context_output , $html );
$html = str_replace( "<%SECTIONCONTENT%>" , $this->html , $html );
# This has to be called after the menu has been set so that query_string is set correctly
$html = str_replace( "<%MSG%>" , $message , $html );
$html = str_replace( "<%HELP%>" , isset( $help ) ? $help : '', $html );
//-----------------------------------------
// Fix up navigation
@@ -845,12 +783,6 @@ class adminOutput extends output
$html = str_replace( "<body", "<body ".$this->body_extra, $html );
}
//-----------------------------------------
// Lang Replace
//-----------------------------------------
$html = preg_replace( "#{txt\.(.+?)}#e", "\$this->lang->words['\\1']", $html );
//-----------------------------------------
// Emoticons fix
//-----------------------------------------
@@ -895,7 +827,7 @@ class adminOutput extends output
if ( is_array( IPSDebug::$memory_debug ) )
{
$memory .= "<br />\n<div align='center' style='margin-left:auto;margin-right:auto'><div class='tableborder' style='width:75%'>\n<div class='tableheaderalt'>MEMORY USAGE</div><div class='tablerow1' style='padding:6px'>\n";
$memory .= "<table cellpadding='4' cellspacing='0' border='0' width='100%'>\n";
$memory .= "<table width='100%'>\n";
$_c = 0;
foreach( IPSDebug::$memory_debug as $usage )
@@ -928,7 +860,7 @@ class adminOutput extends output
$peak_used = $peak_end - IPS_MEMORY_START;
print $memory;
print "Total Memory Used: " . IPSLib::sizeFormat( $_used ) . " (Peak:".IPSText::sizeFormat( $peak_used ).")";
print "Total Memory Used: " . IPSLib::sizeFormat( $_used ) . " (Peak:" . IPSLib::sizeFormat( $peak_used ).")";
}
$this->_IS_PRINTED = 1;
@@ -979,7 +911,7 @@ class adminOutput extends output
$app = ipsRegistry::$current_application;
$link_array = array();
/* Fetch fke apps */
/* Fetch fake apps */
$fakeApps = $this->registry->output->fetchFakeApps();
$inFakeApp = FALSE;
$fakeApp = '';
@@ -1041,23 +973,12 @@ class adminOutput extends output
continue;
}
if ( ! $data['sys_module_parent'] )
{
$_tab_title = $data['sys_module_title'];
$_tab_key = $data['sys_module_key'];
$_tab_title = $data['sys_module_title'];
$_tab_key = $data['sys_module_key'];
$tabs[ $app ]['items'][ $_tab_key ] = array( 'tab_title' => $_tab_title,
'tab_key' => $_tab_key );
$tabs[ $app ]['data'] = $data;
}
else
{
$_tab_title = $data['sys_module_title'];
$_tab_key = $data['sys_module_key'];
$children[ $app ][ $data['sys_module_parent'] ][ $_tab_key ] = array( 'tab_title' => $_tab_title,
'tab_key' => $_tab_key );
}
$tabs[ $app ]['items'][ $_tab_key ] = array( 'tab_title' => $_tab_title,
'tab_key' => $_tab_key );
$tabs[ $app ]['data'] = $data;
}
}
@@ -1417,6 +1338,7 @@ class adminOutput extends output
}
}
}
//print_r($this->core_nav);
//print_r($this->menu);
if ( isset( $this->menu ) && count( $this->menu ) )
{
@@ -1666,14 +1588,15 @@ class adminOutput extends output
*
* @access public
* @param string Field name
* @param array Options. Multidimensional array in format of array( array( 'value', 'display' ), array( 'value', 'display' ) )
* @param array Options. Multidimensional array in format of array( array( 'value', 'display' ), array( 'value', 'display', 'optgroup_key' ) )
* @param string Default value
* @param string HTML id attribute [defaults to $name]
* @param string Javascript to add to list
* @param string CSS class(es) to add to field
* @param array Optgroups
* @return string Form dropdown list
*/
public function formDropdown( $name, $list=array(), $default_val="", $id="", $js="", $css="" )
public function formDropdown( $name, $list=array(), $default_val="", $id="", $js="", $css="", $optgroups=array() )
{
if ($js != "")
{
@@ -1689,16 +1612,101 @@ class adminOutput extends output
$html = "<select name='{$name}'" . $js . " id='{$id}' class='dropdown{$css}'>\n";
foreach ( $list as $v )
//-----------------------------------------
// Support for optgroups
//-----------------------------------------
if( count($optgroups) )
{
$selected = "";
if ( ($default_val !== "") and ($v[0] == $default_val) )
$_printed = 0;
foreach ( $list as $v )
{
$selected = ' selected="selected"';
if( $v[2] != '_root_' )
{
continue;
}
$selected = "";
if ( ($default_val !== "") and ($v[0] == $default_val) )
{
$selected = ' selected="selected"';
}
$html .= "<option value='" . $v[0] . "'" . $selected . ">" . $v[1] . "</option>\n";
$_printed++;
}
foreach( $optgroups as $_key => $value )
{
$html .= "<optgroup label='{$value}'>\n";
foreach ( $list as $v )
{
if( !$v[2] OR $v[2] != $_key )
{
continue;
}
$selected = "";
if ( ($default_val !== "") and ($v[0] == $default_val) )
{
$selected = ' selected="selected"';
}
$html .= "<option value='" . $v[0] . "'" . $selected . ">" . $v[1] . "</option>\n";
$_printed++;
}
$html .= "</optgroup>\n";
}
if( $_printed < count($list) )
{
$html .= "<optgroup label='{$this->lang->words['optgroup_other']}'>\n";
foreach ( $list as $v )
{
if( $v[2] )
{
continue;
}
$selected = "";
if ( ($default_val !== "") and ($v[0] == $default_val) )
{
$selected = ' selected="selected"';
}
$html .= "<option value='" . $v[0] . "'" . $selected . ">" . $v[1] . "</option>\n";
}
$html .= "</optgroup>\n";
}
}
//-----------------------------------------
// Normal
//-----------------------------------------
else
{
foreach ( $list as $v )
{
$selected = "";
if ( ($default_val !== "") and ($v[0] == $default_val) )
{
$selected = ' selected="selected"';
}
$html .= "<option value='" . $v[0] . "'" . $selected . ">" . $v[1] . "</option>\n";
}
$html .= "<option value='" . $v[0] . "'" . $selected . ">" . $v[1] . "</option>\n";
}
$html .= "</select>\n\n";
@@ -1734,13 +1742,13 @@ class adminOutput extends output
}
$html = "<select name='{$name}" . "'" . $js . " id='{$id}' class='dropdown{$css}' multiple='multiple' size='{$size}'>\n";
foreach ($list as $v)
{
$selected = "";
if ( count($default) > 0 )
{
{
if ( in_array( $v[0], $default ) )
{
$selected = ' selected="selected"';
@@ -1841,287 +1849,6 @@ class adminOutput extends output
}
}
/**
* Add a table row
*
* @access public
* @param array Cell data
* @param string CSS clasname
* @param string align value
* @return string HTML
* @deprecated
*/
public function add_td_row( $array, $css="", $align='middle' ) {
if (is_array($array))
{
$html = "<tr>\n";
$count = count($array);
$this->td_colspan = $count;
for ($i = 0; $i < $count ; $i++ )
{
$td_col = $i % 2 ? 'tablerow2' : 'tablerow1';
if ($css != "")
{
$td_col = $css;
}
if (is_array($array[$i]))
{
$text = $array[$i][0];
$colspan = $array[$i][1];
$td_col = $array[$i][2] != "" ? $array[$i][2] : $td_col;
$html .= "<td class='$td_col' colspan='$colspan' valign='$align'>".$text."</td>\n";
}
else
{
if (isset($this->td_header[$i][1]) AND $this->td_header[$i][1] != "")
{
$width = " width='{$this->td_header[$i][1]}' ";
}
else
{
$width = "";
}
$html .= "<td class='$td_col' $width valign='$align'>".$array[$i]."</td>\n";
}
}
$html .= "</tr>\n";
return $html;
}
}
/**
* Add a basic table row
*
* @access public
* @param string Text
* @param string Align value
* @param string HTML id attribute
* @param integer Colspan
* @return string HTML
* @deprecated
*/
public function add_td_basic($text="",$align="left",$id="tablerow1", $colspanint=0) {
$html = "";
$colspan = "";
if ( $colspanint )
{
$this->td_colspan = $colspanint;
}
if ($text != "")
{
if ($this->td_colspan > 0)
{
$colspan = " colspan='".$this->td_colspan."' ";
}
$html .= "<tr><td align='$align' class='$id'".$colspan.">$text</td></tr>\n";
}
return $html;
}
/**
* End a table
*
* @access public
* @return string HTML
* @deprecated
*/
public function end_table() {
$this->td_header = array(); // Reset TD headers
if ($this->has_title == 1)
{
$this->has_title = 0;
return "</table></div><br />\n\n";
}
else
{
return "</table>\n\n";
}
}
/**
* Start a table
*
* @access public
* @param string Title
* @param string Description
* @return string HTML
* @deprecated
*/
public function start_table( $title="", $desc="") {
$html = "";
if ($title != "")
{
$this->has_title = 1;
$html .= "<div class='tableborder'>
<div class='tableheaderalt'>LEGACY -- FIX ME -- $title</div>\n";
if ( $desc != "" )
{
$html .= "<div class='tablesubheader'>$desc</div>\n";
}
}
$html .= "\n<table width='100%' cellspacing='0' cellpadding='5' align='center' border='0'>";
if (isset($this->td_header[0]))
{
// Auto remove two &nbsp; only headers..
$this->td_header[1][0] = ( isset($this->td_header[1][0]) AND $this->td_header[1][0] ) ? $this->td_header[1][0] : '';
$this->td_header[1][1] = ( isset($this->td_header[1][1]) AND $this->td_header[1][1] ) ? $this->td_header[1][1] : '';
if ( $this->td_header[0][0] == '&nbsp;' && $this->td_header[1][0] == '&nbsp;' && ( ! isset( $this->td_header[2][0] ) ) )
{
$this->td_header[0][0] = '{none}';
$this->td_header[1][0] = '{none}';
}
$tds = "";
foreach ($this->td_header as $td)
{
if ($td[1] != "")
{
$width = " width='{$td[1]}' ";
}
else
{
$width = "";
}
if ($td[0] != '{none}')
{
$tds .= "<td class='tablesubheader'".$width."align='center'>{$td[0]}</td>\n";
}
$this->td_colspan++;
}
if( $tds )
{
$html .= "<tr>\n{$tds}</tr>\n";
}
}
return $html;
}
/**
* Start a form tag
*
* @access public
* @param array Hidden input field names => values
* @param string Form name
* @param string Javascript to add to form tag
* @param string HTML id attribute
* @return string HTML
* @deprecated
*/
public function start_form($hiddens="", $name='theAdminForm', $js="", $id="")
{
if ( ! $id )
{
$id = $name;
}
$form = "LEGACY -- FIX ME --<form action='" . $this->settings['base_url'] . "' method='post' name='$name' $js id='$id'>";
if (is_array($hiddens))
{
foreach ($hiddens as $v)
{
$form .= "\n<input type='hidden' name='{$v[0]}' value='{$v[1]}' />";
}
}
//-----------------------------------------
// Add in auth key
//-----------------------------------------
$form .= "\n<input type='hidden' name='_admin_auth_key' value='".ipsRegistry::getClass('adminFunctions')->_admin_auth_key."' />";
return $form;
}
/**
* Add hidden input fields to the form
*
* @access public
* @param array Hidden input fields
* @return string HTML
* @deprecated
*/
public function form_hidden($hiddens="")
{
if (is_array($hiddens))
{
foreach ($hiddens as $v)
{
$form .= "\n<input type='hidden' name='{$v[0]}' value='{$v[1]}'>";
}
}
return $form;
}
/**
* End form (expects to be inside a table)
*
* @access public
* @param string Text
* @param string Javascript
* @param string Extra data to put in table cell
* @return string HTML
* @deprecated
*/
public function end_form($text = "", $js = "", $extra = "")
{
$html = "";
$colspan = "";
if ($text != "")
{
if ($this->td_colspan > 0)
{
$colspan = " colspan='".$this->td_colspan."' ";
}
$html .= "<tr><td align='center' class='tablesubheader'".$colspan."><input type='submit' value='$text'".$js." class='realbutton' accesskey='s'>{$extra}</td></tr>\n";
}
$html .= "</form>";
return $html;
}
/**
* Creates a new menu. Array should be in the format: ( link, title, [image], [delete] )
* The image param is optional.
@@ -2151,6 +1878,10 @@ class adminOutput extends output
{
$links[] = "<li style='z-index: 10000;' class='icon {$img}'><a style='z-index: 10000;' href='#' onclick='return acp.confirmDelete(\"{$menu_item[0]}\");'>{$menu_item[1]}</a></li>";
}
else if( ! $menu_item[0] )
{
$links[] = "<li style='z-index: 10000;' class='icon {$img}'><i>{$menu_item[1]}</i></li>";
}
/* Normal Link */
else
{
@@ -1,19 +1,21 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.0.5
* IP.Board v3.1.4
* Ouput format: HTML
* (Matt Mecham)
* Last Updated: $Date: 2009-08-28 05:22:55 -0400 (Fri, 28 Aug 2009) $
* Last Updated: $Date: 2010-10-28 12:07:41 -0400 (Thu, 28 Oct 2010) $
* </pre>
*
* @author $Author: matt $
* @author $Author: mmecham $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.iinvisionpower.com/community/board/license.html
* @package Invision Power Board
* @link http://www.iinvisionpower.com
* @license http://www.invisionpower.com/community/board/license.html
* @package IP.Board
* @link http://www.invisionpower.com
* @since 9th March 2005 11:03
* @version $Revision: 5053 $
* @version $Revision: 7063 $
*
*/
@@ -122,6 +124,29 @@ class coreOutput
*/
protected $_outputType = 'normal';
/**
* Store canonical tag
*
* @access protected
* @var string
*/
protected $_canonicalUrl;
/**
* Force download flag
*
* @access protected
* @var boolean
*/
protected $_forceDownload = false;
/**
* Temporary title holder
*
* @var string
*/
public $_current_page_title = '';
/**
* Constructor
* We could use 'extends' and build the registry object up but
@@ -147,6 +172,23 @@ class coreOutput
$this->cache = $output->cache;
$this->caches = $output->caches;
$this->skin = $output->skin;
/* Check for forceDownload */
if ( isset( $_GET['forceDownload'] ) AND $_GET['forceDownload'] AND ( $_GET['_k'] == $this->member->form_hash ) )
{
$this->_forceDownload = true;
}
}
/**
* Set forced download mode
*
* @access protected
* @param boolean
*/
protected function forceDownload( $bool )
{
$this->_forceDownload = ( $bool === true ) ? true : false;
}
/**
@@ -179,16 +221,33 @@ class coreOutput
case 200:
$this->_headerStatus = 'OK';
break;
case 301:
$this->_headerStatus = 'Moved Permanently';
break;
case 403:
$this->_headerStatus = 'Forbidden';
break;
case 404:
$this->_headerStatus = 'Not Found';
break;
case 500:
$this->_headerStatus = 'Internal Server Error';
break;
case 503:
$this->_headerStatus = 'Service Unavailable';
break;
}
}
}
/**
* Add Canonical Tag
* @example: $output->addCanonicalTag( 'showtopic=xx', 'my-test-topic', 'showtopic' );
* <code>$output->addCanonicalTag( 'showtopic=xx', 'my-test-topic', 'showtopic' );</code>
*
* @access public
* @param string URL bit (showtopic=x)
@@ -201,7 +260,16 @@ class coreOutput
/* Build it */
if ( $urlBit AND $seoTemplate )
{
$url = $this->registry->getClass('output')->buildSEOUrl( $urlBit, 'public', $seoTitle, $seoTemplate );
$url = $this->registry->getClass('output')->buildSEOUrl( $urlBit, 'publicNoSession', $seoTitle, $seoTemplate );
/* Strip off /index$ */
if ( substr( $url, -6 ) == '/index' )
{
$url = substr_replace( $url, '', -5 );
}
/* Store it */
$this->_canonicalUrl = $url;
if ( $url )
{
@@ -210,23 +278,45 @@ class coreOutput
}
}
/**
* Fetch Canonical Tag
*
* @access public
* @return string
*/
public function getCanonicalUrl()
{
return ( $this->_canonicalUrl ) ? $this->_canonicalUrl : false;
}
/**
* Add meta tag
* @example: $output->addMetaTag( 'description', 'This is a short description' );
* <code>$output->addMetaTag( 'description', 'This is a short description' );</code>
*
* @access public
* @param string tag name
* @param string tag content
* @param boolean Encode content
* @param int Length to trim to (default 500)
* @return void
* @link http://community.invisionpower.com/tracker/issue-22826-case-sensitivity-in-meta-tags/
*/
public function addMetaTag( $tag, $content, $encode='' )
public function addMetaTag( $tag, $content, $encode='', $trimLen=500 )
{
$encode = ( $encode === FALSE ) ? FALSE : TRUE;
$encode = ( $encode === FALSE ) ? FALSE : TRUE;
$trimLen = ( $trimLen - 3 );
$tag = strtolower($tag); // 'ROBOTS' should overwrite 'robots'
switch( $tag )
{
case 'description':
$content = IPSText::truncate( strip_tags($content), 247 );
/* Clear out 'Quote' if it's present in the bbcode parsed content */
$content = preg_replace( '/\<p class=\'citation\'\>.+?\<\/p\>/ims', '', $content );
# There is no max value, but we trim so we don't bloat the output.
# It's not just search engines that use this, also link sharing services
# pick up the meta description.
$content = IPSText::truncate( strip_tags($content), $trimLen );
break;
case 'keywords':
if ( $encode === TRUE )
@@ -234,7 +324,7 @@ class coreOutput
//Bug #15323 breaks accented characters, etc
//$content = strtolower( preg_replace( "/[^0-9a-zA-Z ]/", "", preg_replace( "/&([^;]+?);/", "", $content ) ) );
$content = str_replace( array( '.', ',', '!', ':', ';', "'", "'", '@', '%', '*', '(', ')' ), '', preg_replace( "/&([^;]+?);/", "", $content ) );
$_vals = preg_split( "/\s+?/", $content, -1, PREG_SPLIT_NO_EMPTY );
$_vals = preg_split( '/\s+?/', $content, -1, PREG_SPLIT_NO_EMPTY );
$_sw = explode( ',', $this->lang->words['_stopwords_'] );
$_fvals = array();
$_limit = 30;
@@ -262,8 +352,29 @@ class coreOutput
}
break;
}
$this->_metaTags[ $tag ] = ( $encode === TRUE ) ? htmlspecialchars( $content ) : $content;
$this->_metaTags[ $tag ] = ( $encode === TRUE ) ? preg_replace( '/&amp;#(\d+?);/', "&#\\1;", htmlspecialchars( $content ) ) : $content;
}
/**
* Retrieve meta tags
* <code>$output->getMetaTags( 'description' );
* $output->getMetaTags();</code>
*
* @access public
* @param string tag name (optional)
* @return mixed Array of meta tags, or meta tag specified if tag name is supplied
*/
public function getMetaTags( $tag='' )
{
if( $tag )
{
return isset( $this->_metaTags[ $tag ] ) ? $this->_metaTags[ $tag ] : '';
}
else
{
return $this->_metaTags;
}
}
/**
@@ -292,8 +403,8 @@ class coreOutput
// Set up defaults
//-----------------------------------------
$this->memberData['msg_count_new'] = intval($this->memberData['msg_count_new']);
$this->memberData['msg_count_total'] = intval($this->memberData['msg_count_total']);
$this->memberData['msg_count_new'] = ( ! empty( $this->memberData['msg_count_new'] ) ) ? intval($this->memberData['msg_count_new']) : 0;
$this->memberData['msg_count_total'] = ( ! empty( $this->memberData['msg_count_total'] ) ) ? intval($this->memberData['msg_count_total']) : 0;
}
/**
@@ -308,47 +419,67 @@ class coreOutput
}
/**
* Fetch applications
* Fetch navigation tabs
*
* @access protected
* @return array
*/
protected function core_fetchApplicationData()
{
foreach( ipsRegistry::$applications as $app_dir => $app_data )
$tabs = array();
/* Check for cache */
if ( ! isset( $this->caches['navigation_tabs'] ) OR ! count( $this->caches['navigation_tabs'] ) )
{
$_appShow = 1;
$_appActive = 0;
$this->registry->cache()->rebuildCache( 'navigation_tabs', 'global' );
if ( IPSLib::appIsInstalled( $app_dir ) !== TRUE )
{
continue;
}
if( $app_data['app_hide_tab'] )
{
continue;
}
if ( $app_dir == 'core' OR $app_dir == 'forums' OR $app_dir == 'members' )
{
$_appShow = 0;
}
if ( IPS_APP_COMPONENT == $app_dir )
{
$_appActive = 1;
}
$applications[ $app_dir ] = array( 'app_dir' => $app_dir,
'app_title' => $app_data['app_public_title'],
'app_show' => $_appShow,
'app_active' => $_appActive,
'app_data' => $app_data );
$this->caches['navigation_tabs'] = $this->registry->cache()->getCache('navigation_tabs');
}
return $applications;
foreach( $this->caches['navigation_tabs'] as $tab )
{
if ( IPSLib::appIsInstalled( $tab['app'] ) !== TRUE )
{
continue;
}
$show = TRUE;
if ( $tab['app'] == 'core' OR $tab['app'] == 'forums' OR $tab['app'] == 'members' )
{
$show = FALSE;
}
$active = FALSE;
if ( ipsRegistry::$current_application == $tab['app'] )
{
if ( $tab['module'] )
{
if ( ipsRegistry::$current_module == $tab['module'] )
{
$active = TRUE;
}
}
else
{
$active = TRUE;
}
}
$link = "app={$tab['app']}";
if ( $tab['module'] )
{
$link = "app={$tab['app']}&amp;module={$tab['module']}";
}
$tabs[] = array( 'app_dir' => $tab['app'],
'app_module' => $tab['module'],
'app_title' => $tab['title'],
'app_show' => $show,
'app_active' => $active,
'app_link' => $link );
}
return $tabs;
}
/**
@@ -383,7 +514,7 @@ class coreOutput
}
else if( $type == 'import' )
{
if( ! $this->_css['import'][$data] )
if( !isset($this->_css['import'][$data]) )
{
$this->_css['import'][$data] = array(
'content' => $data,
@@ -1,15 +1,23 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.0.5
* IP.Board v3.1.4
* Ouput format: HTML
* (Matt Mecham)
* Last Updated: $Date: 2010-01-15 10:18:44 -0500 (Fri, 15 Jan 2010) $
* </pre>
*
* (c) IPS, Inc.
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/community/board/license.html
* @package IP.Board
* @link http://www.invisionpower.com
* @since 9th March 2005 11:03
* @version $Revision: 5713 $
*
* Configuration file for output formats
* FORMAT: HTML
*/
$config = array();
/* Identifies publicly as... */
@@ -1,19 +1,21 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.0.5
* IP.Board v3.1.4
* Ouput format: HTML
* (Matt Mecham)
* Last Updated: $Date: 2009-12-04 03:16:10 -0500 (Fri, 04 Dec 2009) $
* Last Updated: $Date: 2010-10-13 09:23:30 -0400 (Wed, 13 Oct 2010) $
* </pre>
*
* @author $Author: matt $
* @author $Author: mmecham $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.iinvisionpower.com/community/board/license.html
* @package Invision Power Board
* @link http://www.iinvisionpower.com
* @license http://www.invisionpower.com/community/board/license.html
* @package IP.Board
* @link http://www.invisionpower.com
* @since 9th March 2005 11:03
* @version $Revision: 5518 $
* @version $Revision: 6966 $
*
*/
@@ -27,6 +29,14 @@ class htmlOutput extends coreOutput implements interface_output
*/
protected $output;
/**
* Print only flag
*
* @access protected
* @var bool
*/
protected $_printOnly = false;
/**
* CSS array
*
@@ -46,6 +56,12 @@ class htmlOutput extends coreOutput implements interface_output
{
/* Make object */
parent::__construct( $output );
/* Print only seems only relevant to html method, so... */
if ( isset( $_GET['forcePrint'] ) AND $_GET['forcePrint'] AND ( $_GET['_k'] == $this->member->form_hash ) )
{
$this->_printOnly = true;
}
}
/**
@@ -93,20 +109,29 @@ class htmlOutput extends coreOutput implements interface_output
header("HTTP/1.1 " . $this->_headerCode . ' ' . $this->_headerStatus );
}
header( "Content-type: text/html;charset=" . IPS_DOC_CHAR_SET );
/* Forcing a download? */
if ( $this->_forceDownload )
{
header( "Content-type: unknown/unknown" );
header( "Content-Disposition: attachment; filename=\"" . IPSText::alphanumericalClean( IPSText::transliterate( mb_strtolower( $this->registry->output->getTitle() ) ) ) . ".html\"" );
}
else
{
header( "Content-type: text/html;charset=" . IPS_DOC_CHAR_SET );
}
if ( $this->settings['nocache'] )
{
$expires = ( $this->_headerExpire ) ? gmdate("D, d M Y H:i:s", time() + $this->_headerExpire ) . " GMT" : 0;
$maxAge = $this->_headerExpire;
$nocache = ( ! $this->_headerExpire ) ? ',no-cache' : '';
$expires = ( $this->_headerExpire ) ? gmdate( "D, d M Y H:i:s", time() + $this->_headerExpire ) . " GMT" : gmdate( "D, d M Y H:i:s", time() - 86400 ) . " GMT";
$maxAge = $this->_headerExpire;
$nocache = ( ! $this->_headerExpire ) ? 'no-cache,' : '';
header("Cache-Control: ". $nocache . "must-revalidate, max-age=" . $maxAge);
header("Expires: " . $expires);
header( "Cache-Control: ". $nocache . "must-revalidate, max-age=" . $maxAge );
header( "Expires: " . $expires );
if ( ! $this->_headerExpire )
{
header("Pragma: no-cache");
header( "Pragma: no-cache" );
}
}
}
@@ -235,27 +260,29 @@ class htmlOutput extends coreOutput implements interface_output
if ( $this->_outputType == 'normal' )
{
//-----------------------------------------
// Do we have a PM show?
// Do we have a notification show?
//-----------------------------------------
if ( ( $this->memberData['msg_count_reset'] OR $this->memberData['msg_show_notification'] ) AND ! $this->memberData['members_disable_pm'] )
$notifications = null;
if ( ! empty( $this->memberData['msg_show_notification'] ) AND $this->memberData['_cache']['show_notification_popup'] )
{
if ( ( $this->request['module'] != 'messaging' ) AND ( ! $this->settings['board_offline'] OR $this->memberData['g_access_offline']) )
if ( !$this->settings['board_offline'] OR $this->memberData['g_access_offline'] )
{
IPSMember::save( $this->memberData['member_id'], array( 'core' => array( 'msg_show_notification' => 0 ) ) );
/* Grab PM Data. We init if we need to recount... */
require_once( IPSLib::getAppDir( "members" ) . '/sources/classes/messaging/messengerFunctions.php' );
$messengerFunctions = new messengerFunctions( $this->registry );
/* Only collect data if we have notifications to show */
if ( $this->memberData['msg_show_notification'] )
if( strpos( ipsRegistry::$settings['query_string_real'], 'area=notificationlog' ) === false )
{
$_data = $messengerFunctions->fetchUnreadNotifications( $this->memberData['member_id'] );
IPSMember::save( $this->memberData['member_id'], array( 'core' => array( 'msg_show_notification' => 0 ) ) );
/* Grab inline notifications... */
$classToLoad = IPSLib::loadLibrary( IPS_ROOT_PATH . '/sources/classes/member/notifications.php', 'notifications' );
$notifyLibrary = new $classToLoad( $this->registry );
$notifyLibrary->setMember( $this->memberData );
$_data = $notifyLibrary->fetchUnreadNotifications( 1, 'notify_sent', 'DESC', true, true );
if ( count( $_data ) )
{
$pmData = array_shift( $_data );
$notifications = array_shift( $_data );
}
}
}
@@ -266,6 +293,7 @@ class htmlOutput extends coreOutput implements interface_output
//-----------------------------------------
$http = 'http://';
if ( strpos( $this->settings['board_url'], 'https://' ) === 0 )
{
$http = 'https://';
@@ -291,20 +319,22 @@ class htmlOutput extends coreOutput implements interface_output
//-----------------------------------------
$finalOutput = $this->output->getTemplate('global')->globalTemplate( $output, $documentHeadItems, $this->_css, $jsLoaderItems, $this->_metaTags,
array( 'title' => $title,
'applications' => $this->core_fetchApplicationData(),
array( 'title' => $title,
'applications' => $this->core_fetchApplicationData(),
'page' => $this->_current_page_title ),
array( 'navigation' => $navigation,
'pmData' => $pmData ),
array( 'time' => $this->registry->getClass('class_localization')->getDate( time(), 'SHORT', 1 ),
'lang_chooser' => $this->html_buildLanguageDropDown(),
'skin_chooser' => $this->html_fetchSetsDropDown(),
'copyright' => $this->html_fetchCopyright() ),
array( 'ex_time' => sprintf( "%.4f", IPSDebug::endTimer() ),
'gzip_status' => ( $this->settings['disable_gzip'] == 1 ) ? $this->lang->words['gzip_off'] : $this->lang->words['gzip_on'],
'server_load' => ipsRegistry::$server_load,
'queries' => $this->DB->getQueryCount(),
'task' => $task )
array( 'navigation' => $navigation,
'notifications' => $notifications,
'adHeaderCode' => ! empty( $extraData['adHeaderCode'] ) ? $extraData['adHeaderCode'] : '',
'adFooterCode' => ! empty( $extraData['adFooterCode'] ) ? $extraData['adFooterCode'] : '' ),
array( 'time' => $this->registry->getClass('class_localization')->getDate( time(), 'SHORT', 1 ),
'lang_chooser' => $this->html_buildLanguageDropDown(),
'skin_chooser' => $this->html_fetchSetsDropDown(),
'copyright' => $this->html_fetchCopyright() ),
array( 'ex_time' => ( isset($this->request['faster']) AND $this->request['faster'] == 'yes' ) ? $this->_getFasterText() : sprintf( "%.4f", IPSDebug::endTimer() ),
'gzip_status' => ( $this->settings['disable_gzip'] == 1 ) ? $this->lang->words['gzip_off'] : $this->lang->words['gzip_on'],
'server_load' => ipsRegistry::$server_load,
'queries' => $this->DB->getQueryCount(),
'task' => $task )
);
}
@@ -335,6 +365,15 @@ class htmlOutput extends coreOutput implements interface_output
$finalOutput = $this->output->getTemplate('global_other')->displayPopUpWindow( $documentHeadItems, $this->_css, $jsLoaderItems, $title, $output );
}
//-----------------------------------------
// Set a class on the body for print
//-----------------------------------------
if( $this->_printOnly )
{
$finalOutput = str_replace( "<body", "<body class='printpreview'", $finalOutput );
}
//-----------------------------------------
// Return
//-----------------------------------------
@@ -412,6 +451,19 @@ class htmlOutput extends coreOutput implements interface_output
foreach( $this->registry->getClass('output')->skin['_cssGroupsArray'] as $position => $data )
{
/* Print only */
if ( $this->_printOnly === true )
{
if ( $data['css_group'] != 'ipb_print' )
{
continue;
}
else
{
$this->registry->getClass('output')->skin['_css'][ $data['css_group'] ]['attributes'] = 'media="screen"';
}
}
$this->registry->getClass('output')->skin['_css'][ $data['css_group'] ]['content'] = str_replace( 'http://', 'https://', $this->registry->getClass('output')->skin['_css'][ $data['css_group'] ]['content'] );
}
}
@@ -424,19 +476,32 @@ class htmlOutput extends coreOutput implements interface_output
{
$name = $data['css_group'];
/* Print only */
if ( $this->_printOnly === true )
{
if ( $name != 'ipb_print' )
{
continue;
}
else
{
$this->registry->getClass('output')->skin['_css'][ $name ]['attributes'] = 'media="screen"';
}
}
/* Did we skip it? */
if ( ! isset( $this->registry->getClass('output')->skin['_css'][ $name ] ) )
{
continue;
}
/* Skip IE, print and lo-fi as it's hardcoded in the skin */
/* Skip IE, print and lo-fi as it's hardcoded in the skin */
if ( $name == 'ipb_ie' )
{
continue;
}
if ( $this->registry->getClass('output')->skin['set_css_inline'] AND @file_exists( IPS_CACHE_PATH . PUBLIC_DIRECTORY . '/style_css/'. $this->registry->getClass('output')->skin['_csscacheid'] .'/'. $name . '.css' ) )
if ( $this->registry->getClass('output')->skin['set_css_inline'] AND @file_exists( DOC_IPS_ROOT_PATH . PUBLIC_DIRECTORY . '/style_css/'. $this->registry->getClass('output')->skin['_csscacheid'] .'/'. $name . '.css' ) )
{
$_cssFile = $this->settings['public_dir'] . 'style_css/' . $this->registry->getClass('output')->skin['_csscacheid'] .'/'. $name . '.css';
$this->_css['import'][$_cssFile] = array(
@@ -529,7 +594,7 @@ class htmlOutput extends coreOutput implements interface_output
/* Strip session URL if there wasn't one */
if ( ! IN_ACP AND $this->member->session_type != 'cookie' AND ! $this->request['s'] )
{
$url = preg_replace( "/\?s=([a-zA-Z0-9]{32})(&amp;|&|$)/", '', $url );
$url = preg_replace( '/\?s=([a-zA-Z0-9]{32})(&amp;|&|$)/', '', $url );
}
/* Log it */
@@ -591,9 +656,17 @@ class htmlOutput extends coreOutput implements interface_output
if ( $this->settings['ipb_img_url'] )
{
$text = preg_replace( "#img\s+?src=[\"']public/style_(images|avatars|emoticons)(.+?)[\"'](.+?)?".">#is", "img src=\"".$this->settings['ipb_img_url']."public/style_\\1\\2\"\\3>", $text );
$text = preg_replace( '#img\s+?src=["\']public/style_(images|avatars|emoticons)(.+?)["\'](.+?)?' . '>#is', "img src=\"".$this->settings['ipb_img_url']."public/style_\\1\\2\"\\3>", $text );
}
//-----------------------------------------
// Fix up dates
//-----------------------------------------
if ( strstr( $text, '{timestamp:' ) )
{
$text = preg_replace_callback( '#<!--\{timestamp:(\d+?):([^\}]+?)\}-->#', create_function( '$key', 'return ipsRegistry::getClass(\'class_localization\')->getDate($key[1], \'$key[2]\', 1);' ), $text );
}
return $text;
}
@@ -612,22 +685,36 @@ class htmlOutput extends coreOutput implements interface_output
// CRIMINAL CHARGES
//-----------------------------------------
$version = ( $this->settings['ipb_display_version'] AND $this->settings['ipb_display_version'] != 0 ) ? IPB_VERSION : '';
$version = ( $this->settings['ipb_display_version'] AND $this->settings['ipb_display_version'] != 0 ) ? ' ' . IPB_VERSION : '';
if ($this->settings['ipb_copy_number'] && $this->settings['ips_cp_purchase'])
{
$copyright = "";
/**
* @link http://community.invisionpower.com/tracker/issue-23750-licensed-to-wont-work-if-copyright-removal-purchased/
*/
if ( $this->settings['ipb_reg_show'] and $this->settings['ipb_reg_name'] )
{
$copyright = "<!-- Copyright Information -->
<p id='copyright'>" .
$this->lang->words['licensed_to'] . $this->settings['ipb_reg_name'] .
"</p>\n\t\t<!-- / Copyright -->";
}
else
{
$copyright = "";
}
}
else
{
$copyright = "<!-- Copyright Information -->
<p id='copyright' class='right'>
Форум IP.Board {$version} &copy; ".date("Y")." &nbsp;IPS, In<abbr title='Incorporated'>c</abbr>.
<p id='copyright'>
Система для сообществ IP.Board{$version}
<div style='display: none;'><a href='http://prowebber.ru' title='PROWEBBER.RU - всё для вебмастера!'>PROWEBBER.RU - всё для вебмастера!</a></div>
";
if ( $this->settings['ipb_reg_show'] and $this->settings['ipb_reg_name'] )
{
$copyright .= "<br />Зарегистрирован на: ". $this->settings['ipb_reg_name'];
$copyright .= "<br />" . $this->lang->words['licensed_to'] . $this->settings['ipb_reg_name'];
}
@@ -769,7 +856,7 @@ class htmlOutput extends coreOutput implements interface_output
$cache['task_next_run'] = $cache['task_next_run'] ? $cache['task_next_run'] : 0;
$stats .= "<b>Следующая задача</b> = ".$this->registry->getClass( 'class_localization')->getDate( $cache['task_next_run'], 'LONG' )."\n<br /><b>Time now</b> = ".$this->registry->getClass( 'class_localization')->getDate( time(), 'LONG' );
$stats .= "<b>Следующая задача</b> = ".$this->registry->getClass( 'class_localization')->getDate( $cache['task_next_run'], 'LONG' )."\n<br /><b>Время</b> = ".$this->registry->getClass( 'class_localization')->getDate( time(), 'LONG' );
$stats .= "<br /><b>Сейчас</b> = ".time();
$stats .= "<p>Пользователь: last_visit: " . $this->memberData['last_visit'] . " / " . $this->registry->getClass( 'class_localization')->getDate( $this->memberData['last_visit'], 'LONG' ) . "</p>";
@@ -831,7 +918,7 @@ class htmlOutput extends coreOutput implements interface_output
if ( $stats )
{
$stats = "
<div align='center'>
<div align='center' id='debug_wrapper'>
<div class='row2' style='padding:8px;vertical-align:middle'><a href='#' onclick=\"$('debug').toggle(); return false;\">Скрыть</a></div>
<br />
<div class='tableborder' align='left' id='debug'>
@@ -947,4 +1034,33 @@ class htmlOutput extends coreOutput implements interface_output
return $output;
}
/**
* Get faster text
*
* @access private
* @return string
*/
private function _getFasterText()
{
$texts = array(
'Zooom',
'REALLY fast',
'Quick',
'Lightning',
'Chop chop',
'Expeditive',
'Flash',
'Lickety Split',
'On the double',
'Rapid',
'Velocious',
'Pronto',
'Speedy Gonzales',
'Warp Speed',
'Double espresso',
);
return $texts[ array_rand($texts) ];
}
}
@@ -1 +1,10 @@
<html>␍<head><title>IP.Board - Bulletin Board System</title></head>␍<body>␍<h1>403: IP.Board -> Forbidden</h1>␍<hr>␍You have reached this page in error, please use your back button to return to the forum.␍<hr>␍<a href="http://www.invisionboard.com/">IP.Board</a>␍</body>␍</html>␍
<html>
<head><title>IP.Board - Bulletin Board System</title></head>
<body>
<h1>403: IP.Board -&gt; Forbidden</h1>
<hr>
You have reached this page in error, please use your back button to return to the forum.
<hr>
<a href="http://www.invisionboard.com/">IP.Board</a>
</body>
</html>
@@ -1 +1,10 @@
<html>␍<head><title>IP.Board - Bulletin Board System</title></head>␍<body>␍<h1>403: IP.Board -> Forbidden</h1>␍<hr>␍You have reached this page in error, please use your back button to return to the forum.␍<hr>␍<a href="http://www.invisionboard.com/">IP.Board</a>␍</body>␍</html>␍
<html>
<head><title>IP.Board - Bulletin Board System</title></head>
<body>
<h1>403: IP.Board -&gt; Forbidden</h1>
<hr>
You have reached this page in error, please use your back button to return to the forum.
<hr>
<a href="http://www.invisionboard.com/">IP.Board</a>
</body>
</html>
@@ -1,13 +1,22 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.0.5
* IP.Board v3.1.4
* Ouput format: XML
* (Matt Mecham)
* Last Updated: $Date: 2010-01-15 10:18:44 -0500 (Fri, 15 Jan 2010) $
* </pre>
*
* (c) IPS, Inc.
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/community/board/license.html
* @package IP.Board
* @link http://www.invisionpower.com
* @since 9th March 2005 11:03
* @version $Revision: 5713 $
*
* Configuration file for output formats
* FORMAT: XML
*/
$config = array();
@@ -1 +1,10 @@
<html>␍<head><title>IP.Board - Bulletin Board System</title></head>␍<body>␍<h1>403: IP.Board -> Forbidden</h1>␍<hr>␍You have reached this page in error, please use your back button to return to the forum.␍<hr>␍<a href="http://www.invisionboard.com/">IP.Board</a>␍</body>␍</html>␍
<html>
<head><title>IP.Board - Bulletin Board System</title></head>
<body>
<h1>403: IP.Board -&gt; Forbidden</h1>
<hr>
You have reached this page in error, please use your back button to return to the forum.
<hr>
<a href="http://www.invisionboard.com/">IP.Board</a>
</body>
</html>
@@ -1,19 +1,21 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.0.5
* IP.Board v3.1.4
* Ouput format: HTML
* (Matt Mecham)
* Last Updated: $Date: 2009-02-16 13:44:12 -0500 (Mon, 16 Feb 2009) $
* Last Updated: $Date: 2010-09-15 17:14:23 -0400 (Wed, 15 Sep 2010) $
* </pre>
*
* @author $Author: josh $
* @author $Author: terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.iinvisionpower.com/community/board/license.html
* @package Invision Power Board
* @link http://www.iinvisionpower.com
* @license http://www.invisionpower.com/community/board/license.html
* @package IP.Board
* @link http://www.invisionpower.com
* @since 9th March 2005 11:03
* @version $Revision: 3998 $
* @version $Revision: 6881 $
*
*/
@@ -74,8 +76,15 @@ class xmlOutput extends coreOutput implements interface_output
print $buffer;
}
header("HTTP/1.0 200 OK");
header("HTTP/1.1 200 OK");
if ( isset( $_SERVER['SERVER_PROTOCOL'] ) AND strstr( $_SERVER['SERVER_PROTOCOL'], '/1.0' ) )
{
header("HTTP/1.0 200 OK" );
}
else
{
header("HTTP/1.1 200 OK" );
}
header( "Content-type: text/xml;charset=" . IPS_DOC_CHAR_SET );
if ( $this->settings['nocache'] )
@@ -143,12 +152,10 @@ class xmlOutput extends coreOutput implements interface_output
//-----------------------------------------
$finalOutput = $this->output->getTemplate('global')->globalTemplate( $output, $documentHeadItems, $this->_css, $jsLoaderItems,
array( 'title' => $title,
'applications' => $this->core_fetchApplicationData(),
'page' => $this->_current_page_title ),
array( 'navigation' => $navigation,
'pmData' => $pmData,
'showReportBox' => ($memberCache['report_last_updated'] < $reportsCache['last_updated'] && $memberCache['report_num'] > 0) ? 1 : 0 ),
array( 'title' => $title,
'applications' => $this->core_fetchApplicationData(),
'page' => $this->_current_page_title ),
array( 'navigation' => $navigation ),
array( 'time' => $this->registry->getClass( 'class_localization')->getDate( time(), 'SHORT', 1 ),
'lang_chooser' => $this->html_buildLanguageDropDown(),
'skin_chooser' => $this->html_fetchSetsDropDown(),
@@ -298,7 +305,9 @@ class xmlOutput extends coreOutput implements interface_output
{
$copyright = "<!-- Copyright Information -->
<p id='copyright'>
Форум IP.Board {$version} &copy; ".date("Y")." &nbsp;IPS, In<abbr title='Incorporated'>c</abbr>.
Форум IP.Board
{$version} &copy; ".date("Y")." &nbsp;IPS, <abbr title='Incorporated'>Inc</abbr>.
<div style='display: none;'><a href='http://prowebber.ru' title='PROWEBBER.RU - всё для вебмастера!'>PROWEBBER.RU - всё для вебмастера!</a></div>
";
if ( $this->settings['ipb_reg_show'] and $this->settings['ipb_reg_name'] )
+10 -1
View File
@@ -1 +1,10 @@
<html>␍<head><title>IP.Board - Bulletin Board System</title></head>␍<body>␍<h1>403: IP.Board -> Forbidden</h1>␍<hr>␍You have reached this page in error, please use your back button to return to the forum.␍<hr>␍<a href="http://www.invisionboard.com/">IP.Board</a>␍</body>␍</html>␍
<html>
<head><title>IP.Board - Bulletin Board System</title></head>
<body>
<h1>403: IP.Board -&gt; Forbidden</h1>
<hr>
You have reached this page in error, please use your back button to return to the forum.
<hr>
<a href="http://www.invisionboard.com/">IP.Board</a>
</body>
</html>
File diff suppressed because it is too large. Load diff