Forums / Setup & design / Problem overriding template filtering by class_identifier

"Please Note:
  • At the specific request of Ibexa we are changing this projects name to "Exponential" or "Exponential (CMS)" effective as of August, 11th 2025.
  • This project is not associated with the original eZ Publish software or its original developer, eZ Systems or Ibexa".

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 Exponential 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