This is done with bog-standard use of XSLT template rules:
<xsl:template match="missing_words_q">
<p><xsl:apply-templates/></p>
</xsl:template>
<xsl:template match="blank">
<input type="text" name="{.}"/>
</xsl:template>
Michael Kay
http://www.saxonica.com/
Author, XSLT Programmer's Reference and XPath 2.0 Programmer's Reference