Specifying a "Template identifier" on a node inserted into a panel region does not generate the theme template suggestion mentioned in the description under the field.

For example, I've added a node to a panel layout with a Template identifier of "support". I then created a tpl file in my theme at
/templates/node/node-panel-support.tpl.php. (there is also a node.tpl.php in the same location).

Cleared the cache and reloaded the page. The result is that the node is still rendered using the node.tpl.php template rather than the node-panel-support.tpl.php template.

I've done a little digging through the code and the module is adding the template suggestion to $vars['template_files'], but this in turn is not loading the matching tpl file in the theme.

I tried using a preprocess function in my template.php to copy the $vars['template_files'] into $vars['theme_hook_suggestions'], but that also did not cause the correct template to load.

Comments

tluzat’s picture

I can confirm that on 7.x-3.x-dev and 7.x-3.0-alpha3: node.tpl.php is being used, but node-panel-from.tpl.php is ignored and does not show up in Theme developer (I guess it should). Just to make sure: For the identifier I used "from" (not node-panel-from.tpl.php), I cleared the theme registry and tried with and without a node.tpl.php (is that still necessary in D7?).

AlexeyB’s picture

subscribing!

the same problem

merlinofchaos’s picture

This is almost certainly a CTools issue, not Panels.

merlinofchaos’s picture

Project: Panels » Chaos Tool Suite (ctools)
Version: 7.x-3.x-dev » 7.x-1.x-dev
Component: Panel pages » Code
merlinofchaos’s picture

Status: Active » Fixed

Checked in a fix. Note that for consistency with D7, the dashes were turned into two dashes. i.e, node--panel--IDENTIFIER to help avoid confusion with other suggestions.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.