Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Template Questions /

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

Templates not found in theme - cache flushing issue?


Go to End


2 Posts   1725 Views

Avatar
justin_t_brown

Community Member, 22 Posts

23 August 2015 at 11:14am

Edited: 23/08/2015 11:19am

Any new templates I include are not being recognized. In the error message below, CallToActionFF1.ss definitely exists under templates/includes. The only way to have Silverstripe recognize new templates is to manually delete cache files (specificallly in templatemanifest). I've tried flush=all, flush=1 and dev/build but none work.

Here is the portion of the template which points to the include:

<% include PageHeaderHero %>
<% include NewsUpdate %>
<% include CallToActionFF1 %>
<% include CallToActionFF2 %>

Here is my error message:

User Warning] None of these templates can be found in theme 'flip-theme': CallToActionFF1.ss
GET /
Line 786 in /Users/justinbrown/web/flip/framework/view/SSViewer.php
Source
777 
778 		if(!$this->chosenTemplates) {
779 			$templateList = (is_array($templateList)) ? $templateList : array($templateList);
780 
781 			user_error(
782 				"None of these templates can be found in theme '"
783 				. Config::inst()->get('SSViewer', 'theme') . "': "
784 				. implode(".ss, ", $templateList) . ".ss", 
785 				E_USER_WARNING
786 
			);
787 		}
788 	}
789 
790 	/**
791 	 * Set the template parser that will be used in template generation
792 	 * @param \TemplateParser $parser

I feel like my issue is similar to: http://www.silverstripe.org/community/forums/general-questions/show/25555

Avatar
justin_t_brown

Community Member, 22 Posts

23 August 2015 at 1:49pm

Figured it out. I updated from SilverStripe 3.1.8 to 3.1.9 which fixes a bug (01989aa) where template manifests weren't flushing on some environments.