I am a beginner in drupal theming, I want to create a special template for my product display custom page drupal 7(page--product-display.tpl.php) I use this php code to render the field but it did't work!

<?php print render($content['product:field_physical_image']); ?>

by the way, I have a type of product called 'product' and also have a custom content type called 'product-display'. Should I add some hook things in template.php file that I don't know?? Thank you.

  • I change the page--product-display.tpl.php fileName to node--product-display.tpl.php and It's work. – RamiN Feb 24 at 7:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.