im getting following errors:
Warning: DOMDocument::load() [domdocument.load]: Opening and ending tag mismatch: property line 6 and xsl:for-each in /home/students/accounts/s4909321/cos80021/www/htdocs/Assignment3/apartment.xsl, line: 25 in/home/students/accounts/s4909321/cos80021/www/htdocs/Assignment3/transform1.php on line 9 Warning: DOMDocument::load() [domdocument.load]: Opening and ending tag mismatch: for-each line 5 and property in /home/students/accounts/s4909321/cos80021/www/htdocs/Assignment3/apartment.xsl, line: 26 in/home/students/accounts/s4909321/cos80021/www/htdocs/Assignment3/transform1.php on line 9 Warning: XSLTProcessor::importStylesheet() [xsltprocessor.importstylesheet]: compilation error in /home/students/accounts/s4909321/cos80021/www/htdocs/Assignment3/transform1.php on line 14 Warning: XSLTProcessor::importStylesheet() [xsltprocessor.importstylesheet]: xsltParseStylesheetProcess : empty stylesheet in /home/students/accounts/s4909321/cos80021/www/htdocs/Assignment3/transform1.php on line 14 Warning: XSLTProcessor::transformToXml() [xsltprocessor.transformtoxml]: No stylesheet associated to this object in /home/students/accounts/s4909321/cos80021/www/htdocs/Assignment3/transform1.php on line 16 Fatal error: Call to a member function saveXML() on a non-object in /home/students/accounts/s4909321/cos80021/www/htdocs/Assignment3/transform1.php on line 18
the xslt file is as following:
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml" indent="yes"/>
<xsl:template match="/">
<rentalProperties>
<xsl:for-each select="//property[numberofBedrooms>=2]">
<property>
<xsl:attribute name="contact"><xsl:value-of select='@contact'/></xsl:attribute>
<xsl:value-of select="type"/>
<xsl:value-of select="price"/>
<address>
<xsl:value-of select="concat(address/streetNo,' ',address/street,', ',address/suburb,', ',address/state,', Australia')"/>
</address>
<numberofBedrooms>
<xsl:value-of select="numberofBedrooms" />
</numberofBedrooms>
<numberofBathrooms>
<xsl:value-of select="numberofBathrooms" />
</numberofBathrooms>
<garage>
<xsl:value-of select="garage" />
</garage>
<description>
<xsl:value-of select="description" />
</description>
</xsl:for-each>
</property>
</rentalProperties>
</xsl:template>
</xsl:stylesheet>
Can somebody help me out ?
transform1.php
rental.xml