Our site www.viart.com site is operated by latest Viart Shop 5 with default Clear design
Topic Information
anstrem
anstrem
I need write in html block like this:
 
<?php if (ABTest::instance()->getTestValue('ab_rronoff') === 'rron'): ?>
<div data-retailrocket-markup-block="59d283e7c7d011c3b4d39ab7" ></div>
<?php else: ?>
<div data-retailrocket-markup-block="59d28259c7d01027cc0e9bc0" ></div>
<?php endif; ?>
 
But when I look at the source of the html page in browser I found only:
<div data-retailrocket-markup-block="59d283e7c7d011c3b4d39ab7" ></div>
<div data-retailrocket-markup-block="59d28259c7d01027cc0e9bc0" ></div>
 
I assume that when the parser processes html, then it deletes the rows with php
Can this be prevented in some way?
 
logan
logan
You'll have to make a custom block_xxxx.php file and a template block to match. Or just edit the ones viart comes with for the block in question. PHP code can only run in Product Pages and only under certain conditions set in your configuration. You can't run code in a custom block on back end because it gets filtered and sanitized.