Index: branches/5.2.x/core/units/helpers/template_helper.php =================================================================== diff -u -N -r14244 -r14628 --- branches/5.2.x/core/units/helpers/template_helper.php (.../template_helper.php) (revision 14244) +++ branches/5.2.x/core/units/helpers/template_helper.php (.../template_helper.php) (revision 14628) @@ -1,6 +1,6 @@ Application->TemplatesCache->TemplateExists($t)) { $cms_handler =& $this->Application->recallObject('st_EventHandler'); - /* @var $cms_handler StructureEventHandler */ + /* @var $cms_handler CategoriesEventHandler */ $t = ltrim($cms_handler->GetDesignTemplate($t), '/'); } @@ -173,8 +173,9 @@ // 1. get location of movable areas $mask = ''; $start_pos = 0; - $elements = Array (); + $elements = $area = Array (); $areas = $this->_getDivPairs($data, 'movable-area'); + foreach ($areas as $area_index => $area) { // 1.1. get locations of all movable elements inside given area $area_content = substr($area['data'], $area['open_len'], -$area['close_len']);