Problem overriding template filtering by class_identifier

Author Message

Toni Vila

Wednesday 24 May 2006 9:55:18 am

Hi i’m running ez 3.6.x,

I want to use tipafriend functionality but using different template depending on object class.
I’ve been created an override for template tipafriendmail.tpl:

[tipafriend_news]
Source=content/tipafriend_mail.tpl
MatchFile= tipafriend_mail_news.tpl
Subdir=templates
Match[class_identifier]=news

And it works.
The problem is when I try to add override filters by class:

[tipafriend_news]
Source=content/tipafriendmail.tpl
MatchFile= tipafriend_mail_news.tpl
Subdir=templates
Match[class_identifier]=news

It doesn’t use template tipafriend_mail_news in design/<i>mysite</i>/override/templates/tipafriendmail.tpl and uses template in design/standard/templates/content/tipafriendmail.tpl

Anyone found a problem like this?

Many thanks in advance.

Łukasz Serwatka

Thursday 25 May 2006 11:26:19 pm

Toni, hello and welcome to the eZ publish Community!

Unfortunately override base on class match will not work with this module. Script fetches data from tipafriend_mail.tpl and uses it in the mail body. When user access tipafirend module, system does not know which class or section is used so match will fail. You can use general override rule without matches.

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.