CheckSvgContent trigger

The CheckSvgContent trigger validates that Scalable Vector Graphics (SVG) images do not contain external links.

When enabled, this trigger is executed just before the Release command is applied to an image. If the image has a mime-type of svg, this trigger checks whether the image contains a link to an external reference (that is, whether the image contains a reference of type //@xlink:href). If the image includes an external reference, an error message is displayed and the Release action is cancelled.

To enable this trigger, add a trigger to the triggers.xml file as described in Enable triggers, using the following values:

apply-to

Release

class

com.ixiasoft.cms.triggers.CheckSvgContent

objtype

image

schedule

before

Example

<trigger apply-to="Release" class="com.ixiasoft.cms.triggers.CheckSvgContent" name="CheckSVGContent" objtype="image" schedule="before">
</trigger>