Merge branch 'master' of github.com:s9y/Serendipity
Conflicts: docs/NEWS
This commit is contained in:
commit
da58de906e
@ -1,4 +1,7 @@
|
||||
===== Smarty-3.1.13 =====
|
||||
24.01.2013
|
||||
- bugfix wrong tag type in smarty_internal_templatecompilerbase.php could cause wrong plugin search order (Forum Topic 24028)
|
||||
|
||||
===== Smarty-3.1.13 =====
|
||||
13.01.2013
|
||||
- enhancement allow to disable exception message escaping by SmartyException::$escape = false; (Issue #130)
|
||||
|
||||
|
@ -331,7 +331,7 @@ abstract class Smarty_Internal_TemplateCompilerBase {
|
||||
}
|
||||
// check plugins from plugins folder
|
||||
foreach ($this->smarty->plugin_search_order as $plugin_type) {
|
||||
if ($plugin_type == Smarty::PLUGIN_BLOCK && $this->smarty->loadPlugin('smarty_compiler_' . $tag) && (!isset($this->smarty->security_policy) || $this->smarty->security_policy->isTrustedTag($tag, $this))) {
|
||||
if ($plugin_type == Smarty::PLUGIN_COMPILER && $this->smarty->loadPlugin('smarty_compiler_' . $tag) && (!isset($this->smarty->security_policy) || $this->smarty->security_policy->isTrustedTag($tag, $this))) {
|
||||
$plugin = 'smarty_compiler_' . $tag;
|
||||
if (is_callable($plugin)) {
|
||||
// convert arguments format for old compiler plugins
|
||||
|
@ -9,11 +9,11 @@ Version 1.7 ()
|
||||
* rc2: Alter entries.tpl to add the line:
|
||||
{assign var="entry" value=$entry scope="parent"}
|
||||
for proper propagation of $entry to sub-templates.
|
||||
|
||||
|
||||
* rc2: Alter error reporting to only fail when 'debug' mode is enabled,
|
||||
so that "normal" blog installations will not fail on specific
|
||||
E_STRICT warnings that are not important.
|
||||
|
||||
|
||||
* Allow entryproperties plugin to define defaults for custom fields
|
||||
|
||||
* Onyx, Net_URL classes: Remove PHP4 style constructor due to
|
||||
|
@ -160,6 +160,17 @@ $tasks = array(array('version' => '0.5.1',
|
||||
If after installation you get uncircumventable errors, you can make sure to set <strong>$serendipity[\'product\'] = true;</strong> in your <strong>serendipity_config_local.inc.php</strong> file. This should lower error reporting to a way that will not interfere with incompatible problem. But this is no solution in the long run, you need to update your plugins.
|
||||
Also, the serendipity_event_browsercompatibility plugin has been removed, because it\'s functionality was no longer required. You should uninstall that plugin if you are currently using it.</p>'),
|
||||
|
||||
array('version' => '1.7-rc2',
|
||||
'type' => 'TEMPLATE_NOTICE',
|
||||
'function' => '',
|
||||
'title' => '<b>TEMPLATE_NOTICE:</b> The template file "entries.tpl" needs a specific assignment',
|
||||
'desc' => 'To transport the $entry variable to sub-templates like comments.tpl and trackbacks.tpl.
|
||||
All internal and spartacus templates have been updated, so make sure you are using a recent version of your blog\'s template.
|
||||
If you have your own custom template, be sure within your {foreach from=$dategroup.entries item="entry"} loop has this line after it:
|
||||
<strong>{assign var="entry" value=$entry scope="parent"}</strong>'),
|
||||
|
||||
|
||||
|
||||
);
|
||||
|
||||
/* Fetch SQL files which needs to be run */
|
||||
|
@ -81,7 +81,8 @@ if (!function_exists('errorToExceptionHandler')) {
|
||||
function errorToExceptionHandler($errNo, $errStr, $errFile = '', $errLine = NULL, $errContext = array()) {
|
||||
global $serendipity;
|
||||
|
||||
$rep = ini_get('error_reporting');
|
||||
$rep = ini_get('error_reporting');
|
||||
$args = func_get_args();
|
||||
|
||||
// respect user has set php error_reporting to not display any errors at all
|
||||
if (!($rep & $errStr)) { return false; }
|
||||
@ -89,36 +90,35 @@ if (!function_exists('errorToExceptionHandler')) {
|
||||
if ($rep == 0) { return false; }
|
||||
// if not using Serendipity testing and user or ISP has set PHPs display_errors to show no errors at all, respect
|
||||
if ($serendipity['production'] === true && ini_get('display_errors') == 0) { return false; }
|
||||
// Several plugins might not adapt to proper style. This should not completely kill our execution.
|
||||
if ($serendipity['production'] !== 'debug' && preg_match('@Declaration.*should be compatible with@i', $args[1])) {
|
||||
#if (!headers_sent()) echo "<strong>Compatibility warning:</strong> Please upgrade file old '{$args[2]}', it contains incompatible signatures.<br/>Details: {$args[1]}<br/>";
|
||||
return false;
|
||||
}
|
||||
// any other errors go here - throw errors as exception
|
||||
if ($serendipity['production'] === 'debug') {
|
||||
|
||||
// We don't want the notices
|
||||
|
||||
// We don't want the notices - but everything else !
|
||||
$e = new Exception;
|
||||
echo '<p> == FULL DEBUG ERROR MODE == </p>';
|
||||
echo '<pre>';
|
||||
// trying to be as detailled as possible
|
||||
if(function_exists('debug_backtrace')) {
|
||||
if (function_exists('debug_backtrace')) {
|
||||
print_r(debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS)); // whether or not to populate the "object" index >= PHP 5.3.6
|
||||
} else {
|
||||
print_r($e);
|
||||
}
|
||||
throw new ErrorException($errStr); // tracepath = all, if not ini_set('display_errors', 0);
|
||||
echo '</pre>'; // if throw new ... endtag is not set, it still looks better and browsers don't care
|
||||
echo '</pre>'; // if using throw new ... this ending tag will not be send and displayed, but it still looks better and browsers don't really care
|
||||
}
|
||||
if ($serendipity['production'] !== true) {
|
||||
$args = func_get_args();
|
||||
|
||||
// Several plugins might not adapt to proper style. This should not completely kill our execution.
|
||||
if ($serendipity['production'] !== 'debug' && preg_match('@Declaration.*should be compatible with@i', $args[1])) {
|
||||
#if (!headers_sent()) echo "<strong>Compatibility warning:</strong> Please upgrade file old '{$args[2]}', it contains incompatible signatures.<br/>Details: {$args[1]}<br/>";
|
||||
return false;
|
||||
}
|
||||
$e = new Exception;
|
||||
if ($serendipity['production'] === false) {
|
||||
echo '<p> == TESTING ERROR MODE == </p>';
|
||||
echo '<pre>';
|
||||
print_r($args);
|
||||
print_r($e);
|
||||
//print_r($args); // do this in strong test environments only, as containing sensible data! Better use debug!
|
||||
throw new ErrorException("Serendipity error: " . $errStr); // tracepath = all;
|
||||
echo '</pre>'; // if throw new ... endtag is not set, it still looks better and browsers don't care
|
||||
} else {
|
||||
echo '</pre>'; // if using throw new ... this ending tag will not be send and displayed, but it still looks better and browsers don't really care
|
||||
}
|
||||
if ($serendipity['production'] === true) {
|
||||
// ToDo: enhance for more special serendipity error needs
|
||||
$str = '<p> == SERENDIPITY ERROR == </p>';
|
||||
$str .= '<p>Please correct:</p>';
|
||||
|
@ -1,4 +1,5 @@
|
||||
<?php // (experimental) serendipity_smarty_class.inc.php 2012-01-03 14:11 Ian
|
||||
<?php
|
||||
// serendipity_smarty_class.inc.php 2013-01-24 Ian
|
||||
|
||||
// define secure_dir and trusted_dirs for Serendipity_Smarty_Security_Policy class.
|
||||
@define('S9Y_TEMPLATE_FALLBACK', $serendipity['serendipityPath'] . $serendipity['templatePath'] . 'default');
|
||||
@ -191,7 +192,7 @@ class Serendipity_Smarty extends Smarty
|
||||
$cache_modified_check only works if you're using display() - it won't do anything on fetch().
|
||||
It won't do anything if you have non-caching plugins or {insert} tags, either.
|
||||
|
||||
We're working on making this more intelligent for 3.2, but… work with what you've got in 3.1 first.
|
||||
We're working on making this more intelligent for 3.2, but<EFBFBD> work with what you've got in 3.1 first.
|
||||
*/
|
||||
|
||||
// some documentary from the smarty forum
|
||||
@ -228,7 +229,7 @@ class Serendipity_Smarty extends Smarty
|
||||
|
||||
you can do $force_cache = true; to make the current page re-render to cache. This actually allows you to work with a very high
|
||||
cache_lifetime and poll a secondary modified time from somewhere. You could then implement the serve-stale-until-updated caching approach.
|
||||
I'll blog about this… probably around christmas
|
||||
I'll blog about this<EFBFBD> probably around christmas
|
||||
*/
|
||||
|
||||
// set the cache_lifetime for index.tpl to 5 minutes
|
||||
@ -311,6 +312,8 @@ class Serendipity_Smarty extends Smarty
|
||||
// set smarty error reporting. General error_reporting is set in serendipity/serendipity_config.inc.php
|
||||
$this->error_reporting = E_ALL & ~(E_NOTICE|E_STRICT);
|
||||
|
||||
// we use our own error_handler and get in conflicts with smarty?
|
||||
// $this->muteExpectedErrors();
|
||||
}
|
||||
|
||||
/*
|
||||
@ -367,6 +370,17 @@ class Serendipity_Smarty extends Smarty
|
||||
$this->assignByRef($tpl_var, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns an array containing template variables- BC mode Smarty 2 -> 3
|
||||
*
|
||||
* @param string $name
|
||||
* @return array
|
||||
*/
|
||||
public function get_template_vars($name=null)
|
||||
{
|
||||
return $this->getTemplateVars($name);
|
||||
}
|
||||
|
||||
public static function test()
|
||||
{
|
||||
var_dump(get_called_class());
|
||||
|
@ -1,4 +1,5 @@
|
||||
<?php # $Id: serendipity_event_karma.php 2778 2011-09-23 12:32:28Z garvinhicking $
|
||||
<?php # $Id:$
|
||||
// serendipity_event_karma.php 2778 2011-09-23 12:32:28Z garvinhicking $
|
||||
|
||||
@serendipity_plugin_api::load_language(dirname(__FILE__));
|
||||
|
||||
@ -43,7 +44,7 @@ class serendipity_event_karma extends serendipity_event
|
||||
$propbag->add('description', PLUGIN_KARMA_BLAHBLAH);
|
||||
$propbag->add('stackable', false);
|
||||
$propbag->add('author', 'Garvin Hicking, Grischa Brockhaus, Judebert, Gregor Voeltz');
|
||||
$propbag->add('version', '2.7');
|
||||
$propbag->add('version', '2.8');
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '0.8',
|
||||
'smarty' => '2.6.7',
|
||||
@ -756,7 +757,8 @@ function vote(karmaVote,karmaId) {
|
||||
|
||||
// Hook for ajax calls
|
||||
case 'external_plugin':
|
||||
$uri_parts = explode('?', str_replace('&', '&', $eventData));
|
||||
$theUri = (string)str_replace('&', '&', $eventData);
|
||||
$uri_parts = explode('?', $theUri);
|
||||
|
||||
// Try to get request parameters from eventData name
|
||||
if (!empty($uri_parts[1])) {
|
||||
|
@ -28,7 +28,7 @@ class serendipity_event_spartacus extends serendipity_event
|
||||
$propbag->add('description', PLUGIN_EVENT_SPARTACUS_DESC);
|
||||
$propbag->add('stackable', false);
|
||||
$propbag->add('author', 'Garvin Hicking');
|
||||
$propbag->add('version', '2.27');
|
||||
$propbag->add('version', '2.29');
|
||||
$propbag->add('requirements', array(
|
||||
'serendipity' => '0.9',
|
||||
'smarty' => '2.6.7',
|
||||
@ -916,12 +916,15 @@ class serendipity_event_spartacus extends serendipity_event
|
||||
|
||||
$this->checkArray($tree);
|
||||
|
||||
foreach($tree[0]['children'] AS $idx => $subtree) {
|
||||
foreach($tree[0]['children'] AS $subtree) {
|
||||
if ($subtree['tag'] != 'package') {
|
||||
continue;
|
||||
}
|
||||
|
||||
foreach($subtree['children'] AS $child => $childtree) {
|
||||
foreach($subtree['children'] AS $childtree) {
|
||||
if (!is_array($childtree) || !isset($childtree['tag'])) {
|
||||
continue;
|
||||
}
|
||||
if ($sub == 'templates' && $childtree['tag'] == 'template' && $childtree['value'] == $plugin_to_install) {
|
||||
$found = true;
|
||||
} elseif ($sub == 'plugins' && $childtree['tag'] == 'name' && $childtree['value'] == $plugin_to_install) {
|
||||
@ -932,12 +935,18 @@ class serendipity_event_spartacus extends serendipity_event
|
||||
continue;
|
||||
}
|
||||
|
||||
foreach($childtree['children'] AS $child2 => $childtree2) {
|
||||
foreach($childtree['children'] AS $childtree2) {
|
||||
if (!is_array($childtree2) || !isset($childtree2['tag'])) {
|
||||
continue;
|
||||
}
|
||||
if ($childtree2['tag'] != 'serendipityFilelist') {
|
||||
continue;
|
||||
}
|
||||
|
||||
foreach($childtree2['children'] AS $idx => $_files) {
|
||||
foreach($childtree2['children'] AS $_files) {
|
||||
if (!is_array($_files) || !isset($_files['tag'])) {
|
||||
continue;
|
||||
}
|
||||
if ($_files['tag'] == 'file' && !empty($_files['value'])) {
|
||||
$files[] = $_files['value'];
|
||||
}
|
||||
@ -969,6 +978,7 @@ class serendipity_event_spartacus extends serendipity_event
|
||||
foreach($files AS $file) {
|
||||
$url = $mirror . '/' . $sfloc . '/' . $gitloc . $file . '?revision=1.9999';
|
||||
$target = $pdir . $file;
|
||||
$target = $this->fixUrl($target);
|
||||
$this->rmkdir($pdir . $plugin_to_install,$sub);
|
||||
$this->fileperm($pdir . $plugin_to_install, true);
|
||||
$this->fetchfile($url, $target);
|
||||
|
@ -93,6 +93,7 @@ $template_config = array(
|
||||
)
|
||||
);
|
||||
|
||||
$template_config_groups = NULL;
|
||||
$template_global_config = array('navigation' => true);
|
||||
$template_loaded_config = serendipity_loadThemeOptions($template_config, $serendipity['smarty_vars']['template_option'], true);
|
||||
serendipity_loadGlobalThemeOptions($template_config, $template_loaded_config, $template_global_config);
|
||||
|
@ -1,6 +1,7 @@
|
||||
{serendipity_hookPlugin hook="entries_header" addData="$entry_id"}
|
||||
{foreach from=$entries item="dategroup"}
|
||||
{foreach from=$dategroup.entries item="entry"}
|
||||
{assign var="entry" value=$entry scope="parent"}
|
||||
<article id="post_{$entry.id}" class="clearfix serendipity_entry{if $dategroup.is_sticky} sticky{/if}">
|
||||
<header class="clearfix">
|
||||
<h2><a href="{$entry.link}">{$entry.title}</a></h2>
|
||||
|
@ -1,4 +1,4 @@
|
||||
Name: 2k11
|
||||
Author: Matthias Mees, Veit Lehmann
|
||||
Date: 2013-01-13
|
||||
Date: 2013-02-03
|
||||
Require Serendipity: 1.6
|
||||
|
@ -26,7 +26,7 @@ function serendipity_plugin_api_event_hook($event, &$bag, &$eventData, $addData
|
||||
}
|
||||
|
||||
|
||||
if ($serendipity['GET']['adminModule'] == 'templates') {
|
||||
if ($serendipity['GET']['adminModule'] == 'templates' || $serendipity['POST']['adminModule'] == 'templates') {
|
||||
$css_files = glob(dirname(__FILE__) . '/*_style.css');
|
||||
foreach($css_files AS $css_file) {
|
||||
$css_file = str_replace('_style.css', '', basename($css_file));
|
||||
|
@ -12,6 +12,7 @@
|
||||
{/if}
|
||||
|
||||
{foreach from=$dategroup.entries item="entry"}
|
||||
{assign var="entry" value=$entry scope="parent"}
|
||||
<h4 class="entry-title serendipity_title"><a href="{$entry.link}" rel="bookmark">{$entry.title}</a></h4>
|
||||
|
||||
<div class="serendipity_entry serendipity_entry_author_{$entry.author|@makeFilename} {if $entry.is_entry_owner}serendipity_entry_author_self{/if}">
|
||||
|
@ -1,4 +1,4 @@
|
||||
Name: Bulletproof v1.4 (s9y-bulletproof.com)
|
||||
Author: Bulletproof development team
|
||||
Date: 2009-06-05
|
||||
Date: 2013-01-23
|
||||
Require Serendipity: 1.2
|
||||
|
@ -2,6 +2,7 @@
|
||||
{serendipity_hookPlugin hook="entries_header" addData="$entry_id"}
|
||||
{foreach from=$entries item="dategroup"}
|
||||
{foreach from=$dategroup.entries item="entry"}
|
||||
{assign var="entry" value=$entry scope="parent"}
|
||||
|
||||
<div class="serendipity_Entry_Date">
|
||||
{if $dategroup.is_sticky}
|
||||
|
@ -6,6 +6,7 @@
|
||||
|
||||
|
||||
{foreach from=$dategroup.entries item="entry"}
|
||||
{assign var="entry" value=$entry scope="parent"}
|
||||
<h4 class="serendipity_title"><a href="{$entry.link}">{$entry.title}</a></h4>
|
||||
{if $dategroup.is_sticky}
|
||||
<h3 class="serendipity_date">{$CONST.STICKY_POSTINGS}</h3>
|
||||
|
@ -3,6 +3,7 @@
|
||||
|
||||
{foreach from=$entries item="dategroup"}
|
||||
{foreach from=$dategroup.entries item="entry"}
|
||||
{assign var="entry" value=$entry scope="parent"}
|
||||
|
||||
<div class="serendipity_Entry_Date">
|
||||
<div class="serendipity_Entry_Header">
|
||||
|
@ -10,6 +10,7 @@
|
||||
{/if}
|
||||
|
||||
{foreach from=$dategroup.entries item="entry"}
|
||||
{assign var="entry" value=$entry scope="parent"}
|
||||
<h4 class="serendipity_title"><a href="{$entry.link}">{$entry.title}</a></h4>
|
||||
|
||||
<div class="serendipity_entry serendipity_entry_author_{$entry.author|@makeFilename} {if $entry.is_entry_owner}serendipity_entry_author_self{/if}">
|
||||
|
@ -11,4 +11,6 @@ if (file_exists($probelang)) {
|
||||
include dirname(__FILE__) . '/lang_en.inc.php';
|
||||
}
|
||||
|
||||
$template_config_groups = NULL;
|
||||
|
||||
?>
|
@ -3,6 +3,7 @@
|
||||
|
||||
{foreach from=$entries item="dategroup"}
|
||||
{foreach from=$dategroup.entries item="entry"}
|
||||
{assign var="entry" value=$entry scope="parent"}
|
||||
<div class="post">
|
||||
<h2 id="post-{$entry.id}"><a href="{$entry.link}">{$entry.title}</a></h2>
|
||||
{if !$is_single_entry}<div class="small">{$entry.timestamp|@formatTime:DATE_FORMAT_ENTRY}</div>{/if}
|
||||
|
@ -1,3 +1,3 @@
|
||||
Name: Kubrick 1.2.6 port
|
||||
Author: Tom Sommer
|
||||
Date: 12/8-2004
|
||||
Date: 2013-02-03
|
||||
|
@ -8,6 +8,7 @@
|
||||
{/if}
|
||||
|
||||
{foreach from=$dategroup.entries item="entry"}
|
||||
{assign var="entry" value=$entry scope="parent"}
|
||||
<div class="post">
|
||||
<h3 class="storytitle" id="post-{$entry.id}"><a href="{$entry.link}" rel="bookmark" title="Permanent Link: {$entry.title}">{$entry.title}</a></h3>
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user