Version 3.3.4

This commit is contained in:
Neo committed 2025-12-19 00:35:52 -08:00
1 parent 78706903a2
commit fb6b5baabc
2206 files changed
+409828 -382984

No files matched your search

@@ -1,10 +1,10 @@
<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.invisionpower.com">IP.Board</a>
</body>
<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.invisionpower.com">IP.Board</a>
</body>
</html>
@@ -1,92 +1,92 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template Plugin: Add to head
* Last Updated: $Date: 2011-05-05 07:03:47 -0400 (Thu, 05 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @version $Rev: 8644 $
*/
/**
* Main loader class
*/
class tp_addtohead extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
$return = '';
switch( $options['type'] )
{
case 'javascript':
case 'js':
return '" . ' . "\$this->registry->getClass('output')->addToDocumentHead( 'javascript', \"" .$data . '" )' . ' . "';
break;
case 'inlinecss':
return '" . ' . "\$this->registry->getClass('output')->addToDocumentHead( 'inlinecss', \"" .$data . '" )' . ' . "';
break;
case 'importcss':
return '" . ' . "\$this->registry->getClass('output')->addToDocumentHead( 'importcss', \"" .$data . '" )' . ' . "';
break;
case 'raw':
return '" . ' . "\$this->registry->getClass('output')->addToDocumentHead( 'raw', \"" .$data . '" )' . ' . "';
break;
}
return '';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'addtohead',
'author' => 'IPS, Inc.',
'usage' => '{parse addtohead="{$this->settings[\'public_dir\']}js/myJS.js" type="javascript"}',
'options' => array( 'type' ) );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template Plugin: Add to head
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @version $Rev: 10914 $
*/
/**
* Main loader class
*/
class tp_addtohead extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
$return = '';
switch( $options['type'] )
{
case 'javascript':
case 'js':
return '" . ' . "\$this->registry->getClass('output')->addToDocumentHead( 'javascript', \"" .$data . '" )' . ' . "';
break;
case 'inlinecss':
return '" . ' . "\$this->registry->getClass('output')->addToDocumentHead( 'inlinecss', \"" .$data . '" )' . ' . "';
break;
case 'importcss':
return '" . ' . "\$this->registry->getClass('output')->addToDocumentHead( 'importcss', \"" .$data . '" )' . ' . "';
break;
case 'raw':
return '" . ' . "\$this->registry->getClass('output')->addToDocumentHead( 'raw', \"" .$data . '" )' . ' . "';
break;
}
return '';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'addtohead',
'author' => 'IPS, Inc.',
'usage' => '{parse addtohead="{$this->settings[\'public_dir\']}js/myJS.js" type="javascript"}',
'options' => array( 'type' ) );
}
}
@@ -1,65 +1,65 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template Pluging: Currency
* Last Updated: $Date: 2011-05-05 07:03:47 -0400 (Thu, 05 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @version $Rev: 8644 $
*/
/**
* Main loader class
*/
class tp_currency extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
$return = '$this->registry->getClass(\'class_localization\')->formatMoney( ' . $data . ', FALSE )';
return '" . ' . $return . ' . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @return array
*/
public function getPluginInfo()
{
return array( 'name' => 'currency',
'author' => 'IPS, Inc.',
'usage' => '{parse currency="5.00"}',
'options' => array( 'format', 'relative' ) );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template Pluging: Currency
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @version $Rev: 10914 $
*/
/**
* Main loader class
*/
class tp_currency extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
$return = '$this->registry->getClass(\'class_localization\')->formatMoney( ' . $data . ', FALSE )';
return '" . ' . $return . ' . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @return array
*/
public function getPluginInfo()
{
return array( 'name' => 'currency',
'author' => 'IPS, Inc.',
'usage' => '{parse currency="5.00"}',
'options' => array( 'format', 'relative' ) );
}
}
@@ -1,96 +1,96 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template Pluging: Date
* Last Updated: $Date: 2011-05-05 07:03:47 -0400 (Thu, 05 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @version $Rev: 8644 $
*/
/**
* Main loader class
*/
class tp_date extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
$return = '';
$timestamp = $data ? $data : "'{custom:now}'";
# Fix up string style dates
/*if ( ! preg_match( "#^[0-9]{10}$#", $timestamp ) AND ( substr( $timestamp, 0, 1 ) != '$' ) )
{
$_time = strtotime( $timestamp );
if ( $_time === FALSE OR $_time == -1 )
{
$timestamp = 0;
}
else
{
$timestamp = $_time;
}
}*/
$_relative = ( isset( $options['relative'] ) && $options['relative'] == 'false' ) ? 1 : 0;
$_format = empty( $options['format'] ) ? 'LONG' : $options['format'];
$return = '$this->registry->getClass(\'class_localization\')->getDate(' . $timestamp . ',"' . $_format . '", ' . $_relative . ')';
return '" . ' . $return . ' . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'date',
'author' => 'IPS, Inc.',
'usage' => '{parse date="now" format="long" relative="false"}',
'options' => array( 'format', 'relative' ) );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template Pluging: Date
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @version $Rev: 10914 $
*/
/**
* Main loader class
*/
class tp_date extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
$return = '';
$timestamp = $data ? $data : "'{custom:now}'";
# Fix up string style dates
/*if ( ! preg_match( "#^[0-9]{10}$#", $timestamp ) AND ( substr( $timestamp, 0, 1 ) != '$' ) )
{
$_time = strtotime( $timestamp );
if ( $_time === FALSE OR $_time == -1 )
{
$timestamp = 0;
}
else
{
$timestamp = $_time;
}
}*/
$_relative = ( isset( $options['relative'] ) && $options['relative'] == 'false' ) ? 1 : 0;
$_format = empty( $options['format'] ) ? 'LONG' : $options['format'];
$return = '$this->registry->getClass(\'class_localization\')->getDate(' . $timestamp . ',"' . $_format . '", ' . $_relative . ')';
return '" . ' . $return . ' . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'date',
'author' => 'IPS, Inc.',
'usage' => '{parse date="now" format="long" relative="false"}',
'options' => array( 'format', 'relative' ) );
}
}
@@ -1,90 +1,90 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template Pluging: CCS block parsing
* Last Updated: $Date: 2011-09-12 20:59:05 -0400 (Mon, 12 Sep 2011) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Content
* @link http://hatynka.in
* @version $Rev: 9483 $
*/
/**
* Main loader class
*/
class tp_editor extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Brandon Farber
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
if( ! $data )
{
return;
}
$_params = ( $options['options'] ) ? $options['options'] : array();
$_content = ( $options['content'] ) ? str_replace( '\'', '\\\'', $options['content'] ) : '';
$_phpCode = "<php>\n";
$_phpCode .= "\t" . '$pluginEditorHook = IPSLib::loadLibrary( IPS_ROOT_PATH . \'sources/classes/editor/composite.php\', \'classes_editor_composite\' );' . "\n";
$_phpCode .= "\t" . '$editor = new $pluginEditorHook();' . "\n</php>";
$_phpCode .= '" . $editor->show(\'' . $data . '\', ' . $_params . ', "' . $_content . '") . "';
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return $_phpCode;
}
/**
* Return information about this modifier
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Brandon Farber
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'editor',
'author' => 'Invision Power Services, Inc.',
'usage' => '{parse editor="FormFieldName" content="" options="array()"}',
'options' => array('options', 'content') );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template Pluging: CCS block parsing
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Content
* @link http://www.invisionpower.com
* @version $Rev: 10914 $
*/
/**
* Main loader class
*/
class tp_editor extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Brandon Farber
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
if( ! $data )
{
return;
}
$_params = ( $options['options'] ) ? $options['options'] : array();
$_content = ( $options['content'] ) ? str_replace( '\'', '\\\'', $options['content'] ) : '';
$_phpCode = "<php>\n";
$_phpCode .= "\t" . '$pluginEditorHook = IPSLib::loadLibrary( IPS_ROOT_PATH . \'sources/classes/editor/composite.php\', \'classes_editor_composite\' );' . "\n";
$_phpCode .= "\t" . '$editor = new $pluginEditorHook();' . "\n</php>";
$_phpCode .= '" . $editor->show(\'' . $data . '\', ' . $_params . ', "' . $_content . '") . "';
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return $_phpCode;
}
/**
* Return information about this modifier
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Brandon Farber
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'editor',
'author' => 'Invision Power Services, Inc.',
'usage' => '{parse editor="FormFieldName" content="" options="array()"}',
'options' => array('options', 'content') );
}
}
@@ -1,70 +1,70 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template plugin: execute PHP expression
* Last Updated: $Date: 2011-05-05 07:03:47 -0400 (Thu, 05 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @since 6/24/2008
* @version $Revision: 8644 $
*/
/**
* Main loader class
*/
class tp_expression extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return '" . ' . $data . ' . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
return array( 'name' => 'expression',
'author' => 'IPS, Inc.',
'usage' => '{parse expression="intval($data)"}',
'options' => array() );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template plugin: execute PHP expression
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @since 6/24/2008
* @version $Revision: 10914 $
*/
/**
* Main loader class
*/
class tp_expression extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return '" . ' . $data . ' . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
return array( 'name' => 'expression',
'author' => 'IPS, Inc.',
'usage' => '{parse expression="intval($data)"}',
'options' => array() );
}
}
@@ -1,75 +1,75 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template Pluging: Format Number
* Last Updated: $Date: 2011-05-05 07:03:47 -0400 (Thu, 05 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @version $Rev: 8644 $
*/
/**
* Main loader class
*/
class tp_format_number extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Brandon Farber
* @param string The initial data from the tag
* @param array Array of options [N/A]
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
$return = '$this->registry->getClass(\'class_localization\')->formatNumber( ' . $data . ' )';
return '" . ' . $return . ' . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'format_number',
'author' => 'IPS, Inc.',
'usage' => '{parse format_number="123456"}',
'options' => array() );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template Pluging: Format Number
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @version $Rev: 10914 $
*/
/**
* Main loader class
*/
class tp_format_number extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Brandon Farber
* @param string The initial data from the tag
* @param array Array of options [N/A]
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
$return = '$this->registry->getClass(\'class_localization\')->formatNumber( ' . $data . ' )';
return '" . ' . $return . ' . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'format_number',
'author' => 'IPS, Inc.',
'usage' => '{parse format_number="123456"}',
'options' => array() );
}
}
@@ -1,94 +1,94 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template Pluging: Include
* Last Updated: $Date: 2011-05-05 07:03:47 -0400 (Thu, 05 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @version $Rev: 8644 $
*/
/**
* Main loader class
*/
class tp_include extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
$return = '';
//-----------------------------------------
// Make life easier...
//-----------------------------------------
$data = str_replace( '#IPS_ROOT_PATH#' , IPS_ROOT_PATH , $data );
$data = str_replace( '#IPS_DOC_ROOT_PATH#', IPS_DOC_ROOT_PATH, $data );
$data = str_replace( '#ROOT#' , IPS_DOC_ROOT_PATH, $data );
//-----------------------------------------
// Attempt to get data
//-----------------------------------------
$return = <<<EOF
ob_start();
include( "$data" );/*noLibHook*/
\$data = ob_get_contents();
ob_end_clean();
EOF;
return "<!--included content-->\n\";\n {$return} \$IPBHTML .= \$data . \"\n<!--/ included content-->";
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'addtohead',
'author' => 'IPS, Inc.',
'usage' => '{parse include="/path/to/file"}',
'options' => array() );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template Pluging: Include
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @version $Rev: 10914 $
*/
/**
* Main loader class
*/
class tp_include extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
$return = '';
//-----------------------------------------
// Make life easier...
//-----------------------------------------
$data = str_replace( '#IPS_ROOT_PATH#' , IPS_ROOT_PATH , $data );
$data = str_replace( '#IPS_DOC_ROOT_PATH#', IPS_DOC_ROOT_PATH, $data );
$data = str_replace( '#ROOT#' , IPS_DOC_ROOT_PATH, $data );
//-----------------------------------------
// Attempt to get data
//-----------------------------------------
$return = <<<EOF
ob_start();
include( "$data" );/*noLibHook*/
\$data = ob_get_contents();
ob_end_clean();
EOF;
return "<!--included content-->\n\";\n {$return} \$IPBHTML .= \$data . \"\n<!--/ included content-->";
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'addtohead',
'author' => 'IPS, Inc.',
'usage' => '{parse include="/path/to/file"}',
'options' => array() );
}
}
@@ -0,0 +1,99 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template Plugin: Insert IP.C media file
* Last Updated: $Date$$
* </pre>
*
* @author $Author$
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Content
* @link http://www.invisionpower.com
* @version $Rev$
*/
/**
* Main loader class
*/
class tp_ipcmedia extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
if( !$data )
{
return;
}
//-----------------------------------------
// Check the media_path file
//-----------------------------------------
if( !is_file( DOC_IPS_ROOT_PATH . '/media_path.php' ) )
{
return;
}
require_once( DOC_IPS_ROOT_PATH . '/media_path.php' );/*noLibHook*/
if( !defined('CCS_MEDIA') OR !CCS_MEDIA_URL OR !CCS_MEDIA OR !is_dir(CCS_MEDIA) )
{
return;
}
$_phpCode = CCS_MEDIA_URL . '/' . ltrim( $data, '/' );
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return $_phpCode;
}
/**
* Return information about this modifier
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Brandon Farber
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'ipcmedia',
'author' => 'Invision Power Services, Inc.',
'usage' => '{parse ipcmedia="/path/to/media.jpg"}',
'options' => array() );
}
}
@@ -1,83 +1,83 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template Pluging: JS Module
* Last Updated: $Date: 2011-05-05 07:03:47 -0400 (Thu, 05 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @version $Rev: 8644 $
*/
/**
* Main loader class
*/
class tp_js_module extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Rikki Tissier
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
$return = '';
if( $data )
{
$priority = isset( $options['important'] ) ? $options['important'] : 0;
return '" . ' . "\$this->registry->getClass('output')->addJSModule(\"" . addslashes( $data ) . '", "' . addslashes( $priority ) . '" )' . ' . "';
//$this->registry->output->addJSModule( $data, $priority );
}
return '';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'js_module',
'author' => 'IPS, Inc.',
'usage' => '{parse js_module="name_of_module"}',
'options' => array('important') );
}
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template Pluging: JS Module
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @version $Rev: 10914 $
*/
/**
* Main loader class
*/
class tp_js_module extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Rikki Tissier
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
$return = '';
if( $data )
{
$priority = isset( $options['important'] ) ? $options['important'] : 0;
return '" . ' . "\$this->registry->getClass('output')->addJSModule(\"" . addslashes( $data ) . '", "' . addslashes( $priority ) . '" )' . ' . "';
//$this->registry->output->addJSModule( $data, $priority );
}
return '';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'js_module',
'author' => 'IPS, Inc.',
'usage' => '{parse js_module="name_of_module"}',
'options' => array('important') );
}
}
@@ -1,70 +1,70 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template plugin: execute PHP expression
* Last Updated: $Date: 2011-05-25 10:30:28 -0400 (Wed, 25 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @since 6/24/2008
* @version $Revision: 8887 $
*/
/**
* Main loader class
*/
class tp_lang extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return '" . $this->lang->words[\''.$data.'\'] . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
return array( 'name' => 'lang',
'author' => 'IPS, Inc.',
'usage' => '{parse lang="some_phrase"}',
'options' => array() );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template plugin: execute PHP expression
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @since 6/24/2008
* @version $Revision: 10914 $
*/
/**
* Main loader class
*/
class tp_lang extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return '" . $this->lang->words[\''.$data.'\'] . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
return array( 'name' => 'lang',
'author' => 'IPS, Inc.',
'usage' => '{parse lang="some_phrase"}',
'options' => array() );
}
}
@@ -1,72 +1,72 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template plugin: perform macro replacement
* Last Updated: $Date: 2011-05-05 07:03:47 -0400 (Thu, 05 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @since 6/24/2008
* @version $Revision: 8644 $
*/
/**
* Main loader class
*/
class tp_replacement extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
$return = "\$this->registry->getClass('output')->getReplacement(\"" . $data . "\")";
return '" . ' . $return . ' . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
return array( 'name' => 'replacement',
'author' => 'IPS, Inc.',
'usage' => '{parse replacement="a_post"}',
'options' => array() );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template plugin: perform macro replacement
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @since 6/24/2008
* @version $Revision: 10914 $
*/
/**
* Main loader class
*/
class tp_replacement extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
$return = "\$this->registry->getClass('output')->getReplacement(\"" . $data . "\")";
return '" . ' . $return . ' . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
return array( 'name' => 'replacement',
'author' => 'IPS, Inc.',
'usage' => '{parse replacement="a_post"}',
'options' => array() );
}
}
@@ -1,91 +1,91 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template Pluging: Resize images in templates proportionately
* Last Updated: $Date: 2011-05-05 07:03:47 -0400 (Thu, 05 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Content
* @link http://hatynka.in
* @version $Rev: 8644 $
*/
/**
* Main loader class
*/
class tp_resize_image extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Brandon Farber
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
if( !$data )
{
return;
}
if( substr( $data, 0, 1 ) == '$' )
{
$_phpCode = '" . IPSLib::getTemplateDimensions(' . $data . ', \'' . $options['maxwidth'] . '\', \'' . $options['maxheight'] . '\') . "';
}
else
{
$_phpCode = '" . IPSLib::getTemplateDimensions("' . $data . '", \'' . $options['maxwidth'] . '\', \'' . $options['maxheight'] . '\') . "';
}
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return $_phpCode;
}
/**
* Return information about this modifier
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Brandon Farber
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'resize_image',
'author' => 'Invision Power Services, Inc.',
'usage' => '{parse resize_image="/path/to/image" maxwidth="100" maxheight="100"}',
'options' => array( 'maxwidth', 'maxheight' ) );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template Pluging: Resize images in templates proportionately
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Content
* @link http://www.invisionpower.com
* @version $Rev: 10914 $
*/
/**
* Main loader class
*/
class tp_resize_image extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Brandon Farber
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
if( !$data )
{
return;
}
if( substr( $data, 0, 1 ) == '$' )
{
$_phpCode = '" . IPSLib::getTemplateDimensions(' . $data . ', \'' . $options['maxwidth'] . '\', \'' . $options['maxheight'] . '\') . "';
}
else
{
$_phpCode = '" . IPSLib::getTemplateDimensions("' . $data . '", \'' . $options['maxwidth'] . '\', \'' . $options['maxheight'] . '\') . "';
}
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return $_phpCode;
}
/**
* Return information about this modifier
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Brandon Farber
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'resize_image',
'author' => 'Invision Power Services, Inc.',
'usage' => '{parse resize_image="/path/to/image" maxwidth="100" maxheight="100"}',
'options' => array( 'maxwidth', 'maxheight' ) );
}
}
@@ -1,88 +1,88 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template plugin: Perform row striping
* Last Updated: $Date: 2011-05-05 07:03:47 -0400 (Thu, 05 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @since 6/24/2008
* @version $Revision: 8644 $
*/
/**
* Main loader class
*/
class tp_striping extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
$phpCode = '';
if ( ! isset( $options['classes'] ) )
{
return '" . IPSLib::next( $this->registry->templateStriping["'.$data.'"] ) . "';
}
else
{
$_classes = explode( ",", trim( $options['classes'] ) );
//$phpCode .= "\n " . '$this->registry->templateStriping[\'' . $data . '\'] = array( FALSE, "' . implode( '","', $_classes ) . "\");\n";
$phpCode .= "\n if ( ! isset( " . '$this->registry->templateStriping[\'' . $data . "'] ) ) {\n" . '$this->registry->templateStriping[\'' . $data . '\'] = array( FALSE, "' . implode( '","', $_classes ) . "\");\n}\n";
}
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return ( $phpCode ) ? "<php>" . $phpCode . "</php>" : '';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
return array( 'name' => 'striping',
'author' => 'IPS, Inc.',
'usage' => '{parse striping="someKey" classes="row1, row2"}',
'options' => array( 'classes' ) );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template plugin: Perform row striping
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @since 6/24/2008
* @version $Revision: 10914 $
*/
/**
* Main loader class
*/
class tp_striping extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
$phpCode = '';
if ( ! isset( $options['classes'] ) )
{
return '" . IPSLib::next( $this->registry->templateStriping["'.$data.'"] ) . "';
}
else
{
$_classes = explode( ",", trim( $options['classes'] ) );
//$phpCode .= "\n " . '$this->registry->templateStriping[\'' . $data . '\'] = array( FALSE, "' . implode( '","', $_classes ) . "\");\n";
$phpCode .= "\n if ( ! isset( " . '$this->registry->templateStriping[\'' . $data . "'] ) ) {\n" . '$this->registry->templateStriping[\'' . $data . '\'] = array( FALSE, "' . implode( '","', $_classes ) . "\");\n}\n";
}
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return ( $phpCode ) ? "<php>" . $phpCode . "</php>" : '';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
return array( 'name' => 'striping',
'author' => 'IPS, Inc.',
'usage' => '{parse striping="someKey" classes="row1, row2"}',
'options' => array( 'classes' ) );
}
}
@@ -1,86 +1,86 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template Pluging: Template Include
* Last Updated: $Date: 2011-09-26 10:20:55 -0400 (Mon, 26 Sep 2011) $
* </pre>
*
* @author $Author: mmecham $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @version $Rev: 9547 $
*/
/**
* Main loader class
*/
class tp_template extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
if( $options['group'] == 'editors' && ipsRegistry::isClassLoaded( 'class_localization' ) )
{
ipsRegistry::getClass('class_localization')->loadLanguageFile( array( 'public_editors' ), 'core' );
}
$return = '';
$_group = str_replace( 'skin_', '', $options['group'] );
$_group = str_replace( '{current_app}', "'.\$this->registry->getCurrentApplication().'", $_group );
$_params = $options['params'];
$return = "( method_exists( \$this->registry->getClass('output')->getTemplate('" . $_group . "'), '{$data}' ) ? \$this->registry->getClass('output')->getTemplate('" . $_group . "')->".$data."(".$_params.") : '' )";
return '" . ' . $return . ' . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'template',
'author' => 'IPS, Inc.',
'usage' => '{parse template="myTemplate" group="global" params="$data, $moreData"}',
'options' => array( 'group', 'params' ) );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template Pluging: Template Include
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @version $Rev: 10914 $
*/
/**
* Main loader class
*/
class tp_template extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
if( $options['group'] == 'editors' && ipsRegistry::isClassLoaded( 'class_localization' ) )
{
ipsRegistry::getClass('class_localization')->loadLanguageFile( array( 'public_editors' ), 'core' );
}
$return = '';
$_group = str_replace( 'skin_', '', $options['group'] );
$_group = str_replace( '{current_app}', "'.\$this->registry->getCurrentApplication().'", $_group );
$_params = $options['params'];
$return = "( method_exists( \$this->registry->getClass('output')->getTemplate('" . $_group . "'), '{$data}' ) ? \$this->registry->getClass('output')->getTemplate('" . $_group . "')->".$data."(".$_params.") : '' )";
return '" . ' . $return . ' . "';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'template',
'author' => 'IPS, Inc.',
'usage' => '{parse template="myTemplate" group="global" params="$data, $moreData"}',
'options' => array( 'group', 'params' ) );
}
}
+132 -132
View File
@@ -1,133 +1,133 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template Pluging: URL
* Last Updated: $Date: 2011-05-27 12:31:36 -0400 (Fri, 27 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @version $Rev: 8912 $
*/
/**
* Main loader class
*/
class tp_url extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
$return = '';
$base = str_replace( '"', '\\"', $options['base'] );
$seotitle = isset( $options['seotitle'] ) ? str_replace( '"', '\\"', $options['seotitle'] ) : '';
$template = isset( $options['template'] ) ? str_replace( '"', '\\"', $options['template'] ) : '';
$options['httpauth'] = isset( $options['httpauth'] ) ? $options['httpauth'] : '';
//$data = $this->_cleanData( $data );
$return = '$this->registry->getClass(\'output\')->formatUrl( $this->registry->getClass(\'output\')->buildUrl( "' . $data . '", "' . $base . '",\'' . $options['httpauth'] . '\' ), "' . $seotitle . '", "' . $template . '" )';
return '" . ' . $return . ' . "';
}
/**
* Clean the data passed to this plugin
*
* @access protected
* @param string Query string params
* @return string Query string params (singular keys)
* @see http://community.invisionpower.com/tracker/issue-20122-hard-coded-query-strings-in-members-list/
* @deprecated
*/
protected function _cleanData( $data )
{
$_return = str_replace( '&amp;', '&', $data );
$_pairs = array();
$_existing = explode( '&', $_return );
if( count( $_existing ) AND is_array( $_existing ) )
{
foreach( $_existing as $kvp )
{
list( $key, $value ) = explode( '=', $kvp );
if( $key AND $value )
{
if( strpos( $key, '[' ) === false OR strpos( $key, '[]' ) !== false )
{
$_pairs[ $key ] = $key . '=' . $value;
}
else
{
preg_match( "/^(.+?)\[(.+?)\]$/", $key, $matches );
$_pairs[ $matches[1] . $matches[2] ] = $key . '=' . $value;
}
}
else
{
$_pairs[] = $kvp;
}
}
return implode( '&amp;', $_pairs );
}
else
{
return $data;
}
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'url',
'author' => 'IPS, Inc.',
'usage' => '{parse url="this=that" base="public"}',
'options' => array( 'base', 'seotitle', 'template', 'httpauth' ) );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template Pluging: URL
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @version $Rev: 10914 $
*/
/**
* Main loader class
*/
class tp_url extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
* @access public
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
$return = '';
$base = str_replace( '"', '\\"', $options['base'] );
$seotitle = isset( $options['seotitle'] ) ? str_replace( '"', '\\"', $options['seotitle'] ) : '';
$template = isset( $options['template'] ) ? str_replace( '"', '\\"', $options['template'] ) : '';
$options['httpauth'] = isset( $options['httpauth'] ) ? $options['httpauth'] : '';
//$data = $this->_cleanData( $data );
$return = '$this->registry->getClass(\'output\')->formatUrl( $this->registry->getClass(\'output\')->buildUrl( "' . $data . '", "' . $base . '",\'' . $options['httpauth'] . '\' ), "' . $seotitle . '", "' . $template . '" )';
return '" . ' . $return . ' . "';
}
/**
* Clean the data passed to this plugin
*
* @access protected
* @param string Query string params
* @return string Query string params (singular keys)
* @see http://community.invisionpower.com/tracker/issue-20122-hard-coded-query-strings-in-members-list/
* @deprecated
*/
protected function _cleanData( $data )
{
$_return = str_replace( '&amp;', '&', $data );
$_pairs = array();
$_existing = explode( '&', $_return );
if( count( $_existing ) AND is_array( $_existing ) )
{
foreach( $_existing as $kvp )
{
list( $key, $value ) = explode( '=', $kvp );
if( $key AND $value )
{
if( strpos( $key, '[' ) === false OR strpos( $key, '[]' ) !== false )
{
$_pairs[ $key ] = $key . '=' . $value;
}
else
{
preg_match( "/^(.+?)\[(.+?)\]$/", $key, $matches );
$_pairs[ $matches[1] . $matches[2] ] = $key . '=' . $value;
}
}
else
{
$_pairs[] = $kvp;
}
}
return implode( '&amp;', $_pairs );
}
else
{
return $data;
}
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
//-----------------------------------------
// Return the data, it's that simple...
//-----------------------------------------
return array( 'name' => 'url',
'author' => 'IPS, Inc.',
'usage' => '{parse url="this=that" base="public"}',
'options' => array( 'base', 'seotitle', 'template', 'httpauth' ) );
}
}
@@ -1,97 +1,97 @@
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.3
* Template plugin: Set and retrieve template variables
* Last Updated: $Date: 2011-05-05 07:03:47 -0400 (Thu, 05 May 2011) $
* </pre>
*
* @author $Author: ips_terabyte $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license This is NULLED!
* @package IP.Board
* @link http://hatynka.in
* @since 6/24/2008
* @version $Revision: 8644 $
*/
/**
* Main loader class
*/
class tp_variable extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
*
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
$phpCode = '';
//-----------------------------------------
// Just want the tag?
//-----------------------------------------
if ( ! count( $options ) )
{
return '" . $this->templateVars["'.$data.'"] . "';
}
if ( isset($options['default']) )
{
$phpCode .= "\n" . '$this->templateVars[\'' . $data . '\'] = "' . str_replace( '"', '\\"', $options['default'] ) . '";';
$phpCode .= "\n" . '$this->__default__templateVars[\'' . $data . '\'] = "' . str_replace( '"', '\\"', $options['default'] ) . '";';
}
if ( !empty($options['oncondition'])AND isset( $options['value'] ) )
{
$phpCode .= "\nif ( {$options['oncondition']} )\n{\n\t".'$this->templateVars[\'' . $data . '\'] = "' . str_replace( '"', '\\"', $options['value'] ) . '";' . "\n}";
$phpCode .= "\nelse {" . '$this->templateVars[\'' . $data . '\'] = $this->__default__templateVars[\'' . $data . '\']; }';
}
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return ( $phpCode ) ? "<php>" . $phpCode . "</php>" : '';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
return array( 'name' => 'variable',
'author' => 'IPS, Inc.',
'usage' => '{parse variable="testKey" default="foo" oncondition="$data == \'new\'" value="bar"}',
'options' => array( 'default', 'oncondition', 'value' ) );
}
<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.3.4
* Template plugin: Set and retrieve template variables
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
* </pre>
*
* @author $Author: bfarber $
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
* @license http://www.invisionpower.com/company/standards.php#license
* @package IP.Board
* @link http://www.invisionpower.com
* @since 6/24/2008
* @version $Revision: 10914 $
*/
/**
* Main loader class
*/
class tp_variable extends output implements interfaceTemplatePlugins
{
/**
* Prevent our main destructor being called by this class
*
* @access public
* @return @e void
*/
public function __destruct()
{
}
/**
* Run the plug-in
*
*
* @author Matt Mecham
* @param string The initial data from the tag
* @param array Array of options
* @return string Processed HTML
*/
public function runPlugin( $data, $options )
{
//-----------------------------------------
// INIT
//-----------------------------------------
$phpCode = '';
//-----------------------------------------
// Just want the tag?
//-----------------------------------------
if ( ! count( $options ) )
{
return '" . $this->templateVars["'.$data.'"] . "';
}
if ( isset($options['default']) )
{
$phpCode .= "\n" . '$this->templateVars[\'' . $data . '\'] = "' . str_replace( '"', '\\"', $options['default'] ) . '";';
$phpCode .= "\n" . '$this->__default__templateVars[\'' . $data . '\'] = "' . str_replace( '"', '\\"', $options['default'] ) . '";';
}
if ( !empty($options['oncondition'])AND isset( $options['value'] ) )
{
$phpCode .= "\nif ( {$options['oncondition']} )\n{\n\t".'$this->templateVars[\'' . $data . '\'] = "' . str_replace( '"', '\\"', $options['value'] ) . '";' . "\n}";
$phpCode .= "\nelse {" . '$this->templateVars[\'' . $data . '\'] = $this->__default__templateVars[\'' . $data . '\']; }';
}
//-----------------------------------------
// Process the tag and return the data
//-----------------------------------------
return ( $phpCode ) ? "<php>" . $phpCode . "</php>" : '';
}
/**
* Return information about this modifier.
*
* It MUST contain an array of available options in 'options'. If there are no allowed options, then use an empty array.
* Failure to keep this up to date will most likely break your template tag.
*
* @access public
* @author Matt Mecham
* @return array
*/
public function getPluginInfo()
{
return array( 'name' => 'variable',
'author' => 'IPS, Inc.',
'usage' => '{parse variable="testKey" default="foo" oncondition="$data == \'new\'" value="bar"}',
'options' => array( 'default', 'oncondition', 'value' ) );
}
}