Vergleich inc/class_templates.php - 1.2.2 - 1.2.14

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 3Zeile 3
 * MyBB 1.2
* Copyright � 2006 MyBB Group, All Rights Reserved
*

 * MyBB 1.2
* Copyright � 2006 MyBB Group, All Rights Reserved
*

 * Website: http://www.mybboard.com
* License: http://www.mybboard.com/eula.html

 * Website: http://www.mybboard.net
* License: http://www.mybboard.net/eula.html

 *

 *

 * $Id: class_templates.php 1978 2006-07-16 23:26:20Z Tikitiki $

 * $Id: class_templates.php 3278 2007-08-23 02:23:28Z Tikitiki $

 */

class templates

 */

class templates

Zeile 64Zeile 64
	 */
function get($title, $eslashes=1, $htmlcomments=1)
{

	 */
function get($title, $eslashes=1, $htmlcomments=1)
{

		global $db, $theme, $PHP_SELF, $mybb;

		global $db, $theme, $mybb;

		if(!isset($this->cache[$title]))
{
$query = $db->query("

		if(!isset($this->cache[$title]))
{
$query = $db->query("

Zeile 73Zeile 73
				WHERE title='$title'
AND sid IN ('-2','-1','".$theme['templateset']."')
ORDER BY sid DESC

				WHERE title='$title'
AND sid IN ('-2','-1','".$theme['templateset']."')
ORDER BY sid DESC

				LIMIT 0, 1

				LIMIT 1

			");
$gettemplate = $db->fetch_array($query);
if($mybb->debug)

			");
$gettemplate = $db->fetch_array($query);
if($mybb->debug)

Zeile 83Zeile 83
			$this->cache[$title] = $gettemplate['template'];
}
$template = $this->cache[$title];

			$this->cache[$title] = $gettemplate['template'];
}
$template = $this->cache[$title];

		if($htmlcomments && $mybb->settings['tplhtmlcomments'] == "yes")



if($htmlcomments)

		{

		{

			$template = "<!-- start: $title -->\n$template\n<!-- end: $title -->";








			if($mybb->settings['tplhtmlcomments'] == "yes")
{
$template = "<!-- start: $title -->\n$template\n<!-- end: $title -->";
}
else
{
$template = "\n$template\n";
}

		}

		}

 
		

		if($eslashes)
{
$template = str_replace("\\'", "'", $db->escape_string($template));

		if($eslashes)
{
$template = str_replace("\\'", "'", $db->escape_string($template));