<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:template match="ACTIONS">
	<table cellpadding="0" cellspacing="0" border="0">
		<tr>
			<xsl:apply-templates select="CONTENT/ACTION"/>
		</tr>
	</table>
</xsl:template>

<xsl:template match="ACTION[@TYPE='edit']">
	<xsl:call-template name="ACTION"/>
</xsl:template>

<xsl:template match="ACTION[@TYPE='delete']">
	<xsl:call-template name="ACTION"/>
</xsl:template>

<xsl:template match="ACTION[@TYPE='create']">
	<xsl:call-template name="ACTION"/>
</xsl:template>

<xsl:template name="ACTION" match="ACTION">
	<td class="message_action">
		<a class="edit_delete_page" href="{ADDRESS}">
			<xsl:apply-templates select="ONCLICK"/>
			<xsl:apply-templates select="TARGET"/>
			<xsl:value-of select="TITLE"/>
		</a>
	</td>
</xsl:template>

<xsl:template match="ACTION/ONCLICK">
	<xsl:attribute name="onclick">
		<xsl:value-of select="."/>
	</xsl:attribute>
</xsl:template>

<xsl:template match="ACTION/TARGET">
	<xsl:attribute name="target">
		<xsl:value-of select="."/>
	</xsl:attribute>
</xsl:template>

</xsl:stylesheet>