Closed (duplicate)
Project:
Views (for Drupal 7)
Version:
6.x-2.2
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
5 Jan 2009 at 00:12 UTC
Updated:
10 Feb 2009 at 16:38 UTC
I'd like to define a custom template for one of my views, but when I clicked "Rescan template files" it didn't didn't find the file. I realised I'm using a separate admin theme, and so put the file in the admin theme folder & it found it!
This means that when Views rescans for template files, it only looks in the folder of the currently displayed template. I would think best practice would be to rescan the default theme, rather than the current admin theme!
Comments
Comment #1
amanda267 commentedSame experience here - I think this is a critical views bug - currently using the latest 6.x-2.2 version of views
Comment #2
tonycaine commentedI had the same experience here Also using 6.x-2.2 version of views and using drupal 6.4
Upgraded to drupal6.8 after seeing '#333060 by neclimdul, merlinofchaos, dvessel: child themes did not inherit patterns correctly, so more specific template files are not detected' because was having issues with a sub theme of zen.
This (for me) has fixed this issue. That is, while using 'pushbutton' as admin theme and using a child of Zen and the templates from that child are now used. eg. '\sites\all\themes\zen\blackie\views-view-field--podcasts--title.tpl.php'.
THANKS.
However, in the edit page for the view, the rescan does not show these templates if i don't have them in the pushbutton dir.
Comment #3
IncrediblyKenzi commentedExperiencing the same.
A quick workaround is to select the appropriate theme to configure in the "administrative theme" panel, then edit your view, then switch it back.
Hope this helps someone.
Comment #4
akalsey commentedA workaround is to re-scan the theme files in a different way. Go to your themes admin page (admin/build/themes) and hit Save Configuration at the bottom. Even if you haven't changed the config, it will rebuild the theme registry and your changes will be picked up in all themes.
Comment #5
semireg commentedThis has wasted 10 hours of my life.
Comment #6
febbraro commentedsubscribe
Comment #7
blackdog commentedThis is a duplicate of #330956: Views UI won't find template files.