HTMLElement.getAttribute

Help
2007-05-29
2013-04-26
  • httpunit_newb
    httpunit_newb
    2007-05-29

    How can one retrieve the attributes for an HTMLElement if one is using CSS?

     
    • Wolfgang Fahl
      Wolfgang Fahl
      2008-03-30

      with getAttribute() ... it's not public at this time but some accessors are exposed e.g.

          public String getID() {
              return getAttribute( "id" );
          }

          public String getClassName() {
              return getAttribute( "class" );
          }

          public String getTitle() {
              return getAttribute( "title" );
          }

      Please participate in the developer mailinglist to discuss your issue in more detail