Wolfgang Wopperer wrote:
> I followed John's advice to make tags global instead of fiddling with 
> behavior inheritance, but I ran into the following problem:
> 
> I define my tags in a class that looks like this:
> 
> class Behavior::Base
>   define_tags do
>   ...
>   end
> end
> 
> Everything is fine as long as the page on which I use the tags has no 
> behavior. But when I assign Sean Cribbs' Commentable behavior to the 
> page, I get a "undefined tag" message when visiting it.
> 
> Any idea what goes wrong here? The Commentable behavior extends 
> Behavior::Base, so if I in turn extend that one, pages with the 
> Commentable behavior should profit from it, or am I missing something?

I think this is a problem with which plugin is being loaded first. The 
way the define_tags code works if you inherit from Behavior::Base and 
then define tags on Behavior::Base the subclass won't get the new tags.

The fix would be to make sure that your code is required before the 
commentable behavior.

--
John Long
http://wisheartdesign.com
_______________________________________________
Radiant mailing list
Post:   [email protected]
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant

Reply via email to