It returns the name of a SimpleXML element
Example
<?php
$xml = simplexml_load_file(‘test.xml’);
echo $xml->getName() ;
?>
Output
web
XML
<?xml version=”1.0″ encoding=”ISO-8859-1″?>
<web xmlns:b=”http://www.phpcodez.com/”>
<server ver=”5″>Apache</server>
<lan>PHP</lan>
<client>Javascript</client>
</web>