//fix correction norm in AdminProducts

This commit is contained in:
lLefevre
2011-09-28 08:26:46 +00:00
parent 2a8336d032
commit a88d5e86ef
3 changed files with 201 additions and 245 deletions
+3 -3
View File
@@ -359,10 +359,10 @@ class ProductControllerCore extends FrontController
$reg = '/{img-([0-9]+)-(left|right)-([a-z]+)}/';
while (preg_match($reg, $desc, $matches))
{
$linkImg = $this->context->link->getImageLink($this->product->link_rewrite, $this->product->id.'-'.$matches[1], $matches[3]);
$link_lmg = $this->context->link->getImageLink($this->product->link_rewrite, $this->product->id.'-'.$matches[1], $matches[3]);
$class = $matches[2] == 'left' ? 'class="imageFloatLeft"' : 'class="imageFloatRight"';
$htmlImg = '<img src="'.$linkImg.'" alt="" '.$class.'/>';
$desc = str_replace($matches[0], $htmlImg, $desc);
$html_img = '<img src="'.$link_lmg.'" alt="" '.$class.'/>';
$desc = str_replace($matches[0], $html_img, $desc);
}
return $desc;
}