diff --git a/engine/classes/Engine.class.php b/engine/classes/Engine.class.php index be9a45d3..bf680a1b 100644 --- a/engine/classes/Engine.class.php +++ b/engine/classes/Engine.class.php @@ -947,7 +947,9 @@ class Engine extends Object { if($aInfo[Engine::CI_INHERIT]){ $sInheritClass = $aInfo[Engine::CI_INHERIT]; $sParentClass = Engine::getInstance()->Plugin_GetParentInherit($sInheritClass); - class_alias($sParentClass,$sClassName); + if(!class_alias($sParentClass,$sClassName)){ + dump("(autoload $sParentClass) Can not load CLASS-file"); + } }elseif($aInfo[Engine::CI_CLASSPATH]){ require_once $aInfo[Engine::CI_CLASSPATH]; }elseif(!class_exists($sClassName)){ diff --git a/engine/include/function.php b/engine/include/function.php index 52945ecc..97814bc8 100644 --- a/engine/include/function.php +++ b/engine/include/function.php @@ -128,19 +128,16 @@ function func_generator($iLength=10) { /** * htmlspecialchars умеющая обрабатывать массивы * - * @param unknown_type $data + * @param mixed $data + * @param int %walkIndex - represents the key/index of the array being recursively htmlspecialchars'ed + * @return void */ -function func_htmlspecialchars(&$data) { - if (is_array($data)) { - foreach ($data as $sKey => $value) { - if (is_array($value)) { - func_htmlspecialchars($data[$sKey]); - } else { - $data[$sKey]=htmlspecialchars($value); - } - } - } else { - $data=htmlspecialchars($data); +function func_htmlspecialchars(&$data, $walkIndex = null) +{ + if(is_string($data)){ + $data = htmlspecialchars($data); + }elseif(is_array($data)){ + array_walk($data, __FUNCTION__); } } @@ -402,7 +399,11 @@ if (!function_exists('array_intersect_key')) { if (!function_exists('class_alias')) { function class_alias($original, $alias) { + if(!class_exists($original)){ + return false; + } eval('abstract class ' . $alias . ' extends ' . $original . ' {}'); + return true; } } diff --git a/engine/lib/external/jquery/markitup/skins/simple/style.css b/engine/lib/external/jquery/markitup/skins/simple/style.css index f2641c91..d1fa3f49 100644 --- a/engine/lib/external/jquery/markitup/skins/simple/style.css +++ b/engine/lib/external/jquery/markitup/skins/simple/style.css @@ -42,7 +42,12 @@ border-left: 1px solid #c0cad5; border-right: 1px solid #c0cad5; } -.markItUpHeader ul { overflow: visible; zoom: 1; } +.markItUpHeader ul { + overflow: visible; + zoom: 1; + display: inline-block; + *display: inline; /* ie <= 7 */ +} .markItUpHeader ul li { list-style: none; float: left; position: relative; margin-right: 6px; } .markItUpHeader ul li: hover > ul{ display: block; } .markItUpHeader ul .markItUpDropMenu { diff --git a/engine/lib/internal/template/js/main.js b/engine/lib/internal/template/js/main.js index d65eb333..b35253f7 100644 --- a/engine/lib/internal/template/js/main.js +++ b/engine/lib/internal/template/js/main.js @@ -1,5 +1,11 @@ Function.prototype.bind = function(context) { var fn = this; + if(jQuery.type(fn) != 'function'){ + throw new TypeError('Function.prototype.bind: call on non-function'); + }; + if(jQuery.type(context) == 'null'){ + throw new TypeError('Function.prototype.bind: cant be bound to null'); + }; return function() { return fn.apply(context, arguments); }; @@ -8,7 +14,7 @@ String.prototype.tr = function(a,p) { var k; var p = typeof(p)=='string' ? p : ''; var s = this; - $.each(a,function(k){ + jQuery.each(a,function(k){ var tk = p?p.split('/'):[]; tk[tk.length] = k; var tp = tk.join('/'); @@ -25,8 +31,8 @@ String.prototype.tr = function(a,p) { var ls = ls || {}; /** -* Управление всплывающими сообщениями -*/ + * Управление всплывающими сообщениями + */ ls.msg = (function ($) { /** * Опции @@ -425,7 +431,7 @@ ls = (function ($) { * Лог сообщений */ this.log = function() { - if (window.console && window.console.log) { + if (!$.browser.msie && window.console && window.console.log) { Function.prototype.bind.call(console.log, console).apply(console, arguments); } else { //alert(msg); diff --git a/plugins/page/templates/skin/developer-jquery/actions/ActionPage/add.tpl b/plugins/page/templates/skin/developer-jquery/actions/ActionPage/add.tpl index 89afba36..7cdd0081 100644 --- a/plugins/page/templates/skin/developer-jquery/actions/ActionPage/add.tpl +++ b/plugins/page/templates/skin/developer-jquery/actions/ActionPage/add.tpl @@ -7,67 +7,69 @@ {literal} {/literal} - + {else} {include file='window_load_img.tpl' sToLoad='page_text'} {/if} - - + +
{hook run='plugin_page_form_add_begin'} - - + +


- - -


-

- - -


-

- - + + +


+

+ + +


+

+ +

- +


{$aLang.page_create_seo_keywords_notice}

@@ -75,22 +77,22 @@


{$aLang.page_create_seo_description_notice}

- +


{$aLang.page_create_sort_notice}

- +

- +

- + {hook run='plugin_page_form_add_end'} -

+

- +
\ No newline at end of file diff --git a/plugins/page/templates/skin/new-jquery/actions/ActionPage/add.tpl b/plugins/page/templates/skin/new-jquery/actions/ActionPage/add.tpl index 89afba36..7cdd0081 100644 --- a/plugins/page/templates/skin/new-jquery/actions/ActionPage/add.tpl +++ b/plugins/page/templates/skin/new-jquery/actions/ActionPage/add.tpl @@ -7,67 +7,69 @@ {literal} {/literal} - + {else} {include file='window_load_img.tpl' sToLoad='page_text'} {/if} - - + +
{hook run='plugin_page_form_add_begin'} - - + +


- - -


-

- - -


-

- - + + +


+

+ + +


+

+ +

- +


{$aLang.page_create_seo_keywords_notice}

@@ -75,22 +77,22 @@


{$aLang.page_create_seo_description_notice}

- +


{$aLang.page_create_sort_notice}

- +

- +

- + {hook run='plugin_page_form_add_end'} -

+

- +
\ No newline at end of file diff --git a/templates/skin/developer-jquery/actions/ActionPhotoset/add.tpl b/templates/skin/developer-jquery/actions/ActionPhotoset/add.tpl index 70d524cb..70682d83 100644 --- a/templates/skin/developer-jquery/actions/ActionPhotoset/add.tpl +++ b/templates/skin/developer-jquery/actions/ActionPhotoset/add.tpl @@ -6,35 +6,37 @@ @@ -44,7 +46,7 @@ tinyMCE.init({ @@ -68,38 +70,38 @@ tinyMCE.init({ {else}

{$aLang.topic_photoset_edit}

{/if} -
-

-
-

+ +

+
+

+ + + + + +

+
- - - - -

- - {hook run='add_topic_photoset_begin'}
{hook run='form_add_topic_photoset_begin'} - - - + + +


- + - +



{$aLang.topic_create_title_notice} @@ -109,42 +111,42 @@ tinyMCE.init({

- +

{$aLang.topic_photoset_upload_title}

- +
{$aLang.topic_photoset_upload_rules|ls_lang:"SIZE%%`$oConfig->get('module.topic.photoset.photo_max_size')`":"COUNT%%`$oConfig->get('module.topic.photoset.count_photos_max')`"}
{$aLang.topic_photoset_upload_choose}
- - + +



{$aLang.topic_create_tags_notice}

@@ -152,7 +154,7 @@ tinyMCE.init({


{$aLang.topic_create_forbid_comment_notice}

- + {if $oUserCurrent->isAdministrator()}


@@ -160,7 +162,7 @@ tinyMCE.init({ {/if} {hook run='form_add_topic_photoset_end'} - +

  diff --git a/templates/skin/developer-jquery/actions/ActionTopic/add.tpl b/templates/skin/developer-jquery/actions/ActionTopic/add.tpl index 77fd5f63..185df61d 100644 --- a/templates/skin/developer-jquery/actions/ActionTopic/add.tpl +++ b/templates/skin/developer-jquery/actions/ActionTopic/add.tpl @@ -5,34 +5,36 @@ @@ -42,7 +44,7 @@ tinyMCE.init({ @@ -78,8 +80,8 @@ tinyMCE.init({ jQuery(document).ready(function($){ ls.blog.loadInfo($('#blog_id').val()); }); - - + +



{$aLang.topic_create_title_notice}

diff --git a/templates/skin/developer-jquery/comment_tree.tpl b/templates/skin/developer-jquery/comment_tree.tpl index 81a1ffb9..600b9c3f 100644 --- a/templates/skin/developer-jquery/comment_tree.tpl +++ b/templates/skin/developer-jquery/comment_tree.tpl @@ -6,38 +6,38 @@ {/if} - - + +

{$aLang.comment_title} ({$iCountComment})

- - + +
{assign var="nesting" value="-1"} {foreach from=$aComments item=oComment name=rublist} {assign var="cmtlevel" value=$oComment->getLevel()} - + {if $cmtlevel>$oConfig->GetValue('module.comment.max_tree')} {assign var="cmtlevel" value=$oConfig->GetValue('module.comment.max_tree')} {/if} - - {if $nesting < $cmtlevel} - {elseif $nesting > $cmtlevel} + + {if $nesting < $cmtlevel} + {elseif $nesting > $cmtlevel} {section name=closelist1 loop=$nesting-$cmtlevel+1}
{/section} {elseif not $smarty.foreach.rublist.first} {/if} - +
- - {include file='comment.tpl'} + + {include file='comment.tpl'} {assign var="nesting" value=$cmtlevel} {if $smarty.foreach.rublist.last} - {section name=closelist2 loop=$nesting+1}
{/section} + {section name=closelist2 loop=$nesting+1}{/section} {/if} {/foreach} - - + + {include file='comment_paging.tpl' aPagingCmt=$aPagingCmt} {if $bAllowNewComment} @@ -45,58 +45,60 @@ {else} {if $oUserCurrent}

{$sNoticeCommentAdd}

- -
- {if $oConfig->GetValue('view.tinymce')} - - {literal} - - {/literal} - {/if} +
+ {if $oConfig->GetValue('view.tinymce')} + + {literal} + + + {/literal} + {/if} {if $oUserCurrent} - - {/if} + + {/if} {hook run='form_add_comment_begin'} @@ -110,6 +112,6 @@ {else} {$aLang.comment_unregistered} {/if} -{/if} +{/if} diff --git a/templates/skin/developer-jquery/css/forms.css b/templates/skin/developer-jquery/css/forms.css index 64ff51dc..8e21f9b8 100644 --- a/templates/skin/developer-jquery/css/forms.css +++ b/templates/skin/developer-jquery/css/forms.css @@ -9,4 +9,4 @@ .markItUp { width: 100%; } .markItUpEditor { width: 100%; -moz-box-sizing: border-box; box-sizing: border-box; } -.markItUpHeader { width: 100%; -moz-box-sizing: border-box; box-sizing: border-box; height: 28px; } \ No newline at end of file +.markItUpHeader { width: 100%; -moz-box-sizing: border-box; box-sizing: border-box; } \ No newline at end of file diff --git a/templates/skin/new-jquery/actions/ActionBlog/add.tpl b/templates/skin/new-jquery/actions/ActionBlog/add.tpl index 24ea99ce..b544ddc7 100644 --- a/templates/skin/new-jquery/actions/ActionBlog/add.tpl +++ b/templates/skin/new-jquery/actions/ActionBlog/add.tpl @@ -17,34 +17,36 @@ diff --git a/templates/skin/new-jquery/actions/ActionPhotoset/add.tpl b/templates/skin/new-jquery/actions/ActionPhotoset/add.tpl index 27d500f8..e8858639 100644 --- a/templates/skin/new-jquery/actions/ActionPhotoset/add.tpl +++ b/templates/skin/new-jquery/actions/ActionPhotoset/add.tpl @@ -5,7 +5,8 @@ {else} diff --git a/templates/skin/new-jquery/actions/ActionTalk/add.tpl b/templates/skin/new-jquery/actions/ActionTalk/add.tpl index 20f8c798..c21070d4 100644 --- a/templates/skin/new-jquery/actions/ActionTalk/add.tpl +++ b/templates/skin/new-jquery/actions/ActionTalk/add.tpl @@ -4,7 +4,8 @@ {else} {include file='window_load_img.tpl' sToLoad='talk_text'} diff --git a/templates/skin/new-jquery/actions/ActionTopic/add.tpl b/templates/skin/new-jquery/actions/ActionTopic/add.tpl index c66e6939..f9ff73da 100644 --- a/templates/skin/new-jquery/actions/ActionTopic/add.tpl +++ b/templates/skin/new-jquery/actions/ActionTopic/add.tpl @@ -5,7 +5,8 @@ {else} {include file='window_load_img.tpl' sToLoad='topic_text'} diff --git a/templates/skin/new-jquery/comment_tree.tpl b/templates/skin/new-jquery/comment_tree.tpl index 40893345..1a7a37ec 100644 --- a/templates/skin/new-jquery/comment_tree.tpl +++ b/templates/skin/new-jquery/comment_tree.tpl @@ -57,6 +57,7 @@ {literal} {/literal} {else} diff --git a/templates/skin/new-jquery/css/forms.css b/templates/skin/new-jquery/css/forms.css index 686a365e..b8002bde 100644 --- a/templates/skin/new-jquery/css/forms.css +++ b/templates/skin/new-jquery/css/forms.css @@ -11,7 +11,7 @@ .markItUp { width: 100%; } .markItUpEditor { width: 100%; -moz-box-sizing: border-box; box-sizing: border-box; } -.markItUpHeader { width: 100%; -moz-box-sizing: border-box; box-sizing: border-box; height: 28px; } +.markItUpHeader { width: 100%; -moz-box-sizing: border-box; box-sizing: border-box; } .button { background: rgb(254,254,254);