greenrd     01/02/07 05:50:19

  Modified:    .        changes.xml
               src/org/apache/cocoon/processor LinkEncodingProcessor.java
  Log:
  encode frames in framesets
  
  Revision  Changes    Path
  1.206     +4 -1      xml-cocoon/changes.xml
  
  Index: changes.xml
  ===================================================================
  RCS file: /home/cvs/xml-cocoon/changes.xml,v
  retrieving revision 1.205
  retrieving revision 1.206
  diff -u -r1.205 -r1.206
  --- changes.xml       2001/02/05 18:41:47     1.205
  +++ changes.xml       2001/02/07 13:50:19     1.206
  @@ -4,7 +4,7 @@
   
   <!--
     History of Cocoon changes   
  -  $Id: changes.xml,v 1.205 2001/02/05 18:41:47 greenrd Exp $ 
  +  $Id: changes.xml,v 1.206 2001/02/07 13:50:19 greenrd Exp $ 
   -->
   
   <changes title="History of Changes">
  @@ -18,6 +18,9 @@
     </devs>
   
    <release version="@version@" date="@date@">
  +  <action dev="RDG" type="update">
  +   LinkEncodingProcessor now encodes frames in framesets as well.
  +  </action>
     <action dev="RDG" type="fix">
      Fixed Utils.getLocationResource to use parent ClassLoader instead of 
System ClassLoader, but
      fallback to System if resource not found.
  
  
  
  1.8       +6 -4      
xml-cocoon/src/org/apache/cocoon/processor/LinkEncodingProcessor.java
  
  Index: LinkEncodingProcessor.java
  ===================================================================
  RCS file: 
/home/cvs/xml-cocoon/src/org/apache/cocoon/processor/LinkEncodingProcessor.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- LinkEncodingProcessor.java        2000/12/16 15:15:31     1.7
  +++ LinkEncodingProcessor.java        2001/02/07 13:50:19     1.8
  @@ -1,4 +1,4 @@
  -/*-- $Id: LinkEncodingProcessor.java,v 1.7 2000/12/16 15:15:31 greenrd Exp $ 
--
  +/*-- $Id: LinkEncodingProcessor.java,v 1.8 2001/02/07 13:50:19 greenrd Exp $ 
--
   
    ============================================================================
                      The Apache Software License, Version 1.1
  @@ -66,7 +66,7 @@
    * Xalan-specific features in your stylesheet.
    *
    * @author <a href="mailto:[EMAIL PROTECTED]">Robin Green</a>
  - * @version $Revision: 1.7 $ $Date: 2000/12/16 15:15:31 $
  + * @version $Revision: 1.8 $ $Date: 2001/02/07 13:50:19 $
    */
   
   public class LinkEncodingProcessor implements Processor, Status {
  @@ -122,14 +122,16 @@
                Attr attr = (Attr) x;
                String name = attr.getName ();
                if (!name.equalsIgnoreCase ("href") 
  -                 && !name.equalsIgnoreCase ("action")) {
  +                 && !name.equalsIgnoreCase ("action")
  +                 && !(name.equalsIgnoreCase ("src") 
  +                      && attr.getOwnerElement ().getTagName 
().equalsIgnoreCase ("frame"))) {
                  return false;
                }
                String href = attr.getValue ();
                try {
                    URL full = new URL (requestBase, href);
                    String hrefHost = full.getHost ();
  -                 // Allow for not-fully--qualified domain names in hrefs
  +                 // Allow for not-fully-qualified domain names in hrefs
                    return (hrefHost.indexOf ('.') == -1) 
                        ? (hostName + '.').startsWith (hrefHost + '.')
                        : hostName.equals (hrefHost);
  
  
  

Reply via email to