2

I want to load a custom .phtml file on product page. I just did this:

Inside view.phtml I added this line:

<?php echo $this->getChildHtml('short_specificaties'); ?>

In local.xml I added this line inside <reference name="product.info"> :

<block type="core/template" name="short_specificaties" as="short_specificaties" template="catalog/product/view/shortspecs.phtml"/>

And inside the shortspecs.phtml I added this code:

<?php
    $_helper = $this->helper('catalog/output');
    $_product = $this->getProduct();
    $theme = $this->helper('ultimo');
    $helperSnippets = $this->helper('ultimo/rsnippets');
?>

<?php $yourCatIds = array(235);
$productCats = $_product->getAvailableInCategories();

if (count(array_intersect($yourCatIds,$productCats))) {
    echo '<li class="test even">' . $_product->getAttributeText('i_display_diagonal_944_1') . '</li>';
    echo '<li class="test even">' . $_product->getAttributeText('i_processor_family_2196_1') . '</li>';
    echo '<li class="test even">' . $_product->getAttributeText('i_internal_memory_11381_1') . '</li>';
    echo '<li class="test even">' . $_product->getAttributeText('i_total_storage_capac_3318_1') . '</li>';
}
?>

But that breaks down the page. What am I doing wrong?

1 Answer 1

1

Jelle,there issue with block type.As you call product view class functions.So,it block type should be type="catalog/product_view" from type="core/template"

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.