{Summary}Summary text.{Details}Detailed description{Etc}.....
Here are two ways to overcome this.
1) To get a description like:
Summary
Summary text.
Details
Detailed description
Etc
.....
We need to replace the { and } with newlines via the following.
In your New Products and Best Sellers layouts replace
Code: Select all
<actinic:variable name="ProductDescription" />
Code: Select all
<actinic:block php="true">
$pd = <<<ENDOFCODE
<actinic:variable name="ProductDescription" />
ENDOFCODE;
$pd = str_replace('{', '<br/><b>', $pd); // replace all { with <br/> and make bold
$pd = str_replace('}', '<br/></b>', $pd); // replace all } with <br/> and end bold
echo $pd;
</actinic:block>
Summary text.
Detailed description
.....
We replace
Code: Select all
<actinic:variable name="ProductDescription" />
Code: Select all
<actinic:block php="true">
$pd = <<<ENDOFCODE
<actinic:variable name="ProductDescription" />
ENDOFCODE;
$pd = preg_replace('/{.*?}/', '<br/>', $pd); // replace all {...} with <br/>
echo $pd;
</actinic:block>
We replace
Code: Select all
<actinic:variable name="ProductDescription" />
Code: Select all
<actinic:block php="true" >
$sShort = "";
$nCount = 0;
$sOriginal = <<<ENDOFCODE
<actinic:variable name="ProductDescription" />
ENDOFCODE;
$sOriginal = preg_replace('/{.*?}/', '', $sOriginal); // remove all {...}
foreach(explode(" ", $sOriginal) as $sWord)
{
if ($nCount > 10)
{
$sShort .= "...";
break;
}
$sShort .= $sWord . " ";
$nCount++;
}
echo $sShort;
</actinic:block>
ENDOFCODE;
must not be indented in any way or you will get PHP errors.