[Hippo-cms7-user] Overwriting node in /hippo:namespaces/hippo problem

Shane Smith s.smith at onehippo.com
Sun Nov 15 23:21:45 CET 2009

you need to delete the node before you can add it,
in your hippo extension file add this to the part that is reading in your
custom resource xml file.

<sv:property sv:name="hippo:contentdelete" sv:type="String">

But it's probably better to leave the default as is en extend it with your
own resource type.


On Sun, Nov 15, 2009 at 8:57 PM, Joffrey <jlambregs at iprofs.nl> wrote:

> Hi all,
> Due to the fact that the resource type does not recognize pdf files by
> default we added this to the node in the console by defining
> <sv:property sv:name="types" sv:type="String">
> <sv:value>png=image/png,jpeg=image/jpeg,jpg=image/jpeg,gif=image/gif,pdf=application
>        /pdf,doc=application/msword,xls=application/vnd.ms-excel</sv:value>
> </sv:property>
> This works fine and now we are able to upload pdf, word and excel files.
> To avoid having to define this property via the console every time we make
> a
> new build I exported the resource node and added this resource.xml file to
> the content project. Also did I add this node to the hippoecm-extension.xml
> just as I did for the hst-virtualhosts.xml.
> When I start the cms I notice that the original "resource" node is still in
> place and not overwritten by the one I define via the xml file. Strange
> thing however is that if I change the name to resource2 a second resource
> node is added to namespace with the correct properties.
> Also changing the sequence number (as first, somewhere in the middle, as
> last) doesn't help. Can anyone tell me what I need to do to overwrite the
> original node with the one I want to add. Or is the hippo:resource node
> sort
> of writeprotected? And why does this same approach work for the
> hst-virtualhosts which is also just a node?
> Below the section I added to the hippoecm-extension file.
> Thanks in advance,
> Joffrey
>        <sv:node sv:name="resource">
>                <sv:property sv:name="jcr:primaryType" sv:type="Name">
>                        <sv:value>hippo:initializeitem</sv:value>
>                </sv:property>
>                <sv:property sv:name="hippo:sequence" sv:type="Double">
>                        <sv:value>10000</sv:value>
>                </sv:property>
>                <sv:property sv:name="hippo:contentresource"
> sv:type="String">
>                        <sv:value>resource.xml</sv:value>
>                </sv:property>
>                <sv:property sv:name="hippo:contentroot" sv:type="String">
>                        <sv:value>/hippo:namespaces/hippo</sv:value>
>                </sv:property>
>        </sv:node>
> --
> View this message in context:
> http://n2.nabble.com/Overwriting-node-in-hippo-namespaces-hippo-problem-tp4008764p4008764.html
> Sent from the Hippo CMS 7 mailing list archive at Nabble.com.
> _______________________________________________
> Hippo-cms7-user mailing list and forums
> http://www.onehippo.org/cms7/support/community.html
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.onehippo.org/pipermail/hippo-cms7-user/attachments/20091115/b1e46265/attachment.htm>

More information about the Hippo-cms7-user mailing list