anchor.diff:                  && term_source_code.compareTo("null") != 0
                   && hmap.containsKey(term_source)) {
                   term_browser_formalname = (String) hmap.get(term_source);
  +                
  +                System.out.println(term_browser_formalname);
  +                
               }
   
               String rowColor = (n%2 == 0) ? "dataRowDark" : "dataRowLight";
  +            
  +	    boolean licenseAgreementAccepted = false;
  +	    String formal_name = null;
  +	    boolean isLicensed = DataUtils.checkIsLicensed(term_source);
  +	    String cs_name = Constants.CODING_SCHEME_NAME;
  +	    String view_in_source_hierarchy_label = "View In Source Hierarchy";
  +	    if (term_source != null) {
  +	        view_in_source_hierarchy_label = "View In " + term_source + " Hierarchy";
  +	    }
  +	    if (term_source != null && isLicensed ) {
  +	        formal_name = MetadataUtils.getSABFormalName(term_source);
  +	        licenseAgreementAccepted = licenseBean.licenseAgreementAccepted(formal_name);
  +	    }
  +	
  +	    boolean source_hierarchy_available = false;
  +	    if (available_hierarchies != null && available_hierarchies.indexOf("|" + term_source + "|") != -1) {
  +	         source_hierarchy_available = true;
  +	    }
  +	    
  +	    if (!isLicensed) {
  +	        licenseAgreementAccepted = true;
  +	    }
  +      
           %>
               <tr class="<%=rowColor%>">
                 <td class="dataCellText" width=675><%=term_name%></td>
                 <td class="dataCellText" width=100><%=term_source%></td>
                 <td class="dataCellText" width=100><%=term_type%></td>
   
  -              <%
  -              
  -              if (term_browser_formalname == null) {
  -              %>
  -              <td class="dataCellText" width=125><%=term_source_code%></td>
  -              <%
  -              } else {
  -              %>
  -
  -                  <td class="dataCellText" width=100>
  -
   <%
  -boolean licenseAgreementAccepted = false;
  -String formal_name = null;
  -boolean isLicensed = DataUtils.checkIsLicensed(term_source);
  -String cs_name = Constants.CODING_SCHEME_NAME;
  -String view_in_source_hierarchy_label = "View In Source Hierarchy";
  -if (term_source != null) {
  -    view_in_source_hierarchy_label = "View In " + term_source + " Hierarchy";
  -}
  -
  -if (term_source != null && isLicensed ) {
  -     formal_name = MetadataUtils.getSABFormalName(term_source);
  -     licenseAgreementAccepted = licenseBean.licenseAgreementAccepted(formal_name);
  -     if (licenseAgreementAccepted) {
  -%>     
  -	  <a href="#" onclick="javascript:window.open('<%=nciterm_browser_url%>/ncitbrowser/pages/concept_details.jsf?dictionary=<%=term_browser_formalname%>&code=<%=term_source_code%>',
  -	  '_blank','top=100, left=100, height=740, width=780, status=no, menubar=no, resizable=yes, scrollbars=yes, toolbar=no, location=no, directories=no');">
  -	      <%=term_source_code%>
  -	  </a>  
  -	  
  +               // source code 
  +		if (term_browser_formalname == null) {
  +%>
  +
  +			  <td class="dataCellText" width=125><%=term_source_code%></td>
   <%
  -	      if (available_hierarchies != null && available_hierarchies.indexOf("|" + term_source + "|") != -1) {
  +		} else {
  +		      if (!licenseAgreementAccepted) {
  +		      
   %>		      
  -		      <a class="icon_blue" href="#" onclick="javascript:window.open('<%=request.getContextPath() %>/pages/source_hierarchy.jsf?dictionary=<%=cs_name%>&code=<%=id%>&sab=<%=term_source%>&type=hierarchy', '_blank','top=100, left=100, height=740, width=680, status=no, menubar=no, resizable=yes, scrollbars=yes, toolbar=no, location=no, directories=no');">
  -		      <img src="<%=basePath%>/images/visualize.gif" width="16px" height="16px" alt="View In Source Hierarchy" border="0"/>
  -		      </a>
  -<%		      
  -	      }
  +	                  <td>
  +			  <a href="#" onclick="javascript:window.open('<%= request.getContextPath() %>/pages/accept_license.jsf?dictionary=<%=formal_name%>&code=<%=term_source_code%>',
  +			  '_blank','top=100, left=100, height=740, width=780, status=no, menubar=no, resizable=yes, scrollbars=yes, toolbar=no, location=no, directories=no');">
  +			      <%=term_source_code%>
  +			  </a>
  +			  </td>
  +<%			  
  +	              } else {
   %>	  
  -	  
  -<%     
  -     } else {
  -%> 
  -
  -	  <a href="#" onclick="javascript:window.open('<%= request.getContextPath() %>/pages/accept_license.jsf?dictionary=<%=formal_name%>&code=<%=term_source_code%>',
  -	  '_blank','top=100, left=100, height=740, width=780, status=no, menubar=no, resizable=yes, scrollbars=yes, toolbar=no, location=no, directories=no');">
  -	      <%=term_source_code%>
  -	  </a>  
  -
  -<%
  -	      if (available_hierarchies != null && available_hierarchies.indexOf("|" + term_source + "|") != -1) {
  +                          <td>
  +			  <a href="#" onclick="javascript:window.open('<%=nciterm_browser_url%>/ncitbrowser/pages/concept_details.jsf?dictionary=<%=term_browser_formalname%>&code=<%=term_source_code%>',
  +			  '_blank','top=100, left=100, height=740, width=780, status=no, menubar=no, resizable=yes, scrollbars=yes, toolbar=no, location=no, directories=no');">
  +			      <%=term_source_code%>
  +			  </a> 
  +			  </td>
  +			  
  +<%			  
  +	    	      }
  +		}
  +               // tree 
  +		if (source_hierarchy_available) {
  +		      if (!licenseAgreementAccepted) {
   %>		      
  -		      <a class="icon_blue" href="#" onclick="javascript:window.open('<%=request.getContextPath() %>/pages/accept_license.jsf?dictionary=<%=formal_name%>&code=<%=id%>&sab=<%=term_source%>&type=hierarchy', '_blank','top=100, left=100, height=740, width=680, status=no, menubar=no, resizable=yes, scrollbars=yes, toolbar=no, location=no, directories=no');">
  -		      <img src="<%=basePath%>/images/visualize.gif" width="16px" height="16px" title="<%=view_in_source_hierarchy_label%>" alt="<%=view_in_source_hierarchy_label%>" border="0"/>
  -		      </a>
  -<%		      
  -	      }
  -%>	      
  -          
  -<%          
  -     }
  -} else {
  -
  -%>
  -                  <a href="#" onclick="javascript:window.open('<%=nciterm_browser_url%>/ncitbrowser/pages/concept_details.jsf?dictionary=<%=term_browser_formalname%>&code=<%=term_source_code%>',
  -                  '_blank','top=100, left=100, height=740, width=780, status=no, menubar=no, resizable=yes, scrollbars=yes, toolbar=no, location=no, directories=no');">
  -                      <%=term_source_code%>
  -                  </a>
  -                  
  -<%                  
  -	      if (available_hierarchies != null && available_hierarchies.indexOf("|" + term_source + "|") != -1) {
  -%>		      
  +                              <td>
  +			      <a class="icon_blue" href="#" onclick="javascript:window.open('<%=request.getContextPath() %>/pages/accept_license.jsf?dictionary=<%=formal_name%>&code=<%=id%>&sab=<%=term_source%>&type=hierarchy', '_blank','top=100, left=100, height=740, width=680, status=no, menubar=no, resizable=yes, scrollbars=yes, toolbar=no, location=no, directories=no');">
  +			      <img src="<%=basePath%>/images/visualize.gif" width="16px" height="16px" title="<%=view_in_source_hierarchy_label%>" alt="<%=view_in_source_hierarchy_label%>" border="0"/>
  +			      </a>
  +			      </td>
  +<%			  
  +	              } else {
  +%>	              
  +	                      <td>
   		      <a class="icon_blue" href="#" onclick="javascript:window.open('<%=request.getContextPath() %>/pages/source_hierarchy.jsf?dictionary=<%=cs_name%>&code=<%=id%>&sab=<%=term_source%>&type=hierarchy', '_blank','top=100, left=100, height=740, width=680, status=no, menubar=no, resizable=yes, scrollbars=yes, toolbar=no, location=no, directories=no');">
   		      <img src="<%=basePath%>/images/visualize.gif" width="16px" height="16px" alt="<%=view_in_source_hierarchy_label%>" title="<%=view_in_source_hierarchy_label%>" border="0"/>
   		      </a>
  -<%		      
  -	      }    
  -%>	      
  +			      </td>
  +<%                  
  +	    	      }
  +		} else {
  +%>		
  +		      <td>&nbsp;</td>
  +<%		
  +		}
  + 
  +%>
                     
  -<% 
  -} 
  -%>
  -
  -                  </td>
  -              <%
  -              }
  -              %>
   
               </tr>
           <%
  
positive.code:   HashMap hmap = MetadataUtils.getSAB2FormalNameHashMap();
    String entry_type_syn = type;
    String available_hierarchies = NCImBrowserProperties.getSourceHierarchies();
  
    String nciterm_browser_url = NCImBrowserProperties.getTermBrowserURL();
    String secured_vocabularies = NCImBrowserProperties.getSecuredVocabularies();
  
negative.code:           //    request.getSession().setAttribute("synonyms", synonyms);
            //}
            synonyms = new DataUtils().sortSynonyms(synonyms, sort_by);
            
            
            for (int n=0; n<synonyms.size(); n++)
            {
              String s = (String) synonyms.elementAt(n);
  