Reputation: 135
I've currently got a fairly straight forward product page with the following format:
Product name:
Description Attribute 1 Attribute 2 etc
Now I want it to be Product name - Description on the same line then listed below Attribute 1, Attribute 2 etc
Now I've found the view.html file and then dug a little deeper to find attributes.html however as the page is dynamically generated I can't seem to figure out how to achieve this without renaming all of my products?
Has anyone had this issue before?
Thanks, Dan
Upvotes: 0
Views: 491
Reputation: 10772
In app/design/frontend/[Package]/[Theme]/templates/catalog/product/view.phtml
, the Product Title is called using something like this:
<?php echo $_helper->productAttribute($_product, $_product->getName(), 'name') ?>
Your short description is called using something like this:
<?php echo $_helper->productAttribute($_product, nl2br($_product->getShortDescription()), 'short_description') ?>
If you're wanting to combine the Description with the Product Name, you can do this:
<?php echo $_helper->productAttribute($_product, $_product->getName(), 'name') ?> <?php echo $_helper->productAttribute($_product, nl2br($_product->getDescription()), 'description') ?>
It's essentially the Name and Description outputted onto a single line in the template file.
Upvotes: 1