<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <HTML ><HEAD ><TITLE >DOMElement->getAttribute()</TITLE ><META NAME="GENERATOR" CONTENT="Modular DocBook HTML Stylesheet Version 1.79"><LINK REL="HOME" TITLE="Manual do PHP" HREF="index.html"><LINK REL="UP" TITLE="DOM Functions" HREF="ref.dom.html"><LINK REL="PREVIOUS" TITLE="DOMElement->__construct()" HREF="function.dom-domelement-construct.html"><LINK REL="NEXT" TITLE="DOMElement->getAttributeNode()" HREF="function.dom-domelement-getattributenode.html"><META HTTP-EQUIV="Content-type" CONTENT="text/html; charset=UTF-8"></HEAD ><BODY CLASS="refentry" BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000FF" VLINK="#840084" ALINK="#0000FF" ><DIV CLASS="NAVHEADER" ><TABLE SUMMARY="Header navigation table" WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" ><TR ><TH COLSPAN="3" ALIGN="center" >Manual do PHP</TH ></TR ><TR ><TD WIDTH="10%" ALIGN="left" VALIGN="bottom" ><A HREF="function.dom-domelement-construct.html" ACCESSKEY="P" >Anterior</A ></TD ><TD WIDTH="80%" ALIGN="center" VALIGN="bottom" ></TD ><TD WIDTH="10%" ALIGN="right" VALIGN="bottom" ><A HREF="function.dom-domelement-getattributenode.html" ACCESSKEY="N" >Próxima</A ></TD ></TR ></TABLE ><HR ALIGN="LEFT" WIDTH="100%"></DIV ><H1 ><A NAME="function.dom-domelement-getattribute" ></A >DOMElement->getAttribute()</H1 ><DIV CLASS="refnamediv" ><A NAME="AEN37203" ></A ><P > (no version information, might be only in CVS)</P >DOMElement->getAttribute() -- Returns value of attribute</DIV ><DIV CLASS="refsect1" ><A NAME="AEN37206" ></A ><H2 >Descrição</H2 >class <B CLASS="classname" >DOMElement</B > { <BR ></BR >string <B CLASS="methodname" >getAttribute</B > ( string name )<BR ></BR >}<P > Gets the value of the attribute with name <CODE CLASS="parameter" >name</CODE > for the current node. </P ></DIV ><DIV CLASS="refsect1" ><A NAME="AEN37219" ></A ><H2 >Parâmetros</H2 ><P > <P ></P ><DIV CLASS="variablelist" ><DL ><DT ><CODE CLASS="parameter" >name</CODE ></DT ><DD ><P > The name of the attribute. </P ></DD ></DL ></DIV > </P ></DIV ><DIV CLASS="refsect1" ><A NAME="AEN37228" ></A ><H2 >Valores de retornado</H2 ><P > The value of the attribute, or an empty string if no attribute with the given <CODE CLASS="parameter" >name</CODE > is found. </P ></DIV ><DIV CLASS="refsect1" ><A NAME="AEN37232" ></A ><H2 >Veja também</H2 ><P > <P ></P ><TABLE BORDER="0" ><TBODY ><TR ><TD ><A HREF="function.dom-domelement-hasattribute.html" >DOMElement->hasAttribute()</A ></TD ></TR ><TR ><TD ><A HREF="function.dom-domelement-setattribute.html" >DOMElement->setAttribute()</A ></TD ></TR ><TR ><TD ><A HREF="function.dom-domelement-removeattribute.html" >DOMElement->removeAttribute()</A ></TD ></TR ></TBODY ></TABLE ><P ></P > </P ></DIV ><DIV CLASS="NAVFOOTER" ><HR ALIGN="LEFT" WIDTH="100%"><TABLE SUMMARY="Footer navigation table" WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" ><TR ><TD WIDTH="33%" ALIGN="left" VALIGN="top" ><A HREF="function.dom-domelement-construct.html" ACCESSKEY="P" >Anterior</A ></TD ><TD WIDTH="34%" ALIGN="center" VALIGN="top" ><A HREF="index.html" ACCESSKEY="H" >Principal</A ></TD ><TD WIDTH="33%" ALIGN="right" VALIGN="top" ><A HREF="function.dom-domelement-getattributenode.html" ACCESSKEY="N" >Próxima</A ></TD ></TR ><TR ><TD WIDTH="33%" ALIGN="left" VALIGN="top" >DOMElement->__construct()</TD ><TD WIDTH="34%" ALIGN="center" VALIGN="top" ><A HREF="ref.dom.html" ACCESSKEY="U" >Acima</A ></TD ><TD WIDTH="33%" ALIGN="right" VALIGN="top" >DOMElement->getAttributeNode()</TD ></TR ></TABLE ></DIV ></BODY ></HTML >