Package com.dotcms.repackage.org.jsoup.nodes

Examples of com.dotcms.repackage.org.jsoup.nodes.Element.attr()


  private static void getParseContainer(Document templateBody){
    Elements divHiddenParseContainer = templateBody.getElementsByAttributeValue(STYLE_ATTRIBUTE, STYLE_DISPLAY_NONE);
    for(Element singleDiv : divHiddenParseContainer){
      if(!singleDiv.attr(ID_ATTRIBUTE).equals("metatagToAdd")){
        Element parent = singleDiv.parent();
        if(!parent.attr(ID_ATTRIBUTE).equals("metatagToAdd")){
          String html = singleDiv.html();
          singleDiv.remove();
          parent.append(html);
        }
      }
View Full Code Here


    header.append(headCode);
  }

  private static String getPageWithValue(Document templateDrawedBody){
    Element globalContainer = templateDrawedBody.getElementsByAttributeValue(NAME_ATTRIBUTE, MAIN_DIV_NAME_VALUE).get(0);
    return globalContainer.attr(ID_ATTRIBUTE);
  }

  private static String getLayout(Document templateDrawedBody){
    Elements layouts = templateDrawedBody.getElementsByAttributeValue(ID_ATTRIBUTE, SIDEBAR_ID);
    if(null!=layouts && layouts.size()>0){
View Full Code Here

        Elements splitBodies = templateDrawedBody.select( DIV_TAG + "[" + ID_ATTRIBUTE + "~=" + getRegexForSelectBody() );
        for ( int i = 0; i < splitBodies.size(); i++ ) {

            Element splitBody = splitBodies.get( i );
            // gets the identifier of the body div
            String idHtml = splitBody.attr( ID_ATTRIBUTE );
            String id = idHtml.substring( idHtml.indexOf( SPLIT_BODY_ID_PREFIX ) + SPLIT_BODY_ID_PREFIX.length() );
            String layoutType = splitBody.child( 0 ).attr( ID_ATTRIBUTE );

            //Create a template row
            TemplateLayoutRow rowLayout = new TemplateLayoutRow();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.