Reputation: 455
I'm trying to make an addon both Plone 4 and Plone 5 compatible. The problem I'm running into is the profiles/default XML.
Plone 5: I have a registry.xml for registering CSS Plone 4: I have a cssregistry.xml for registering CSS
I was hoping Plone 4 would ignore the registry.xml but it picked it up and then crashes during the install in Plone 4. Is there a solution to this?
Upvotes: 3
Views: 142
Reputation: 455
What you said works great when you add:
xmlns:zcml="http://namespaces.zope.org/zcml"
To the top configuration. Just a note for any future people who need this.
Upvotes: 0
Reputation: 7727
You can have multiple profiles pointing to different profile directories (they are defined in configure.zcml
), and the Plone docs have examples of how to conditionally evaluate ZCML:
<include zcml:condition="have plone-4" package=".package" />
<include zcml:condition="not-have plone-4" package=".otherpackage" />
There's also a straight "evaluate content if condition is met" by having zcml:condition
on a configure.
Upvotes: 6