jakarta-ecs-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rdon...@apache.org
Subject cvs commit: jakarta-ecs/src/java/org/apache/ecs/html Script.java
Date Fri, 02 May 2003 09:54:59 GMT
rdonkin     2003/05/02 02:54:59

  Modified:    src/java/org/apache/ecs/html Script.java
  Log:
  Changed script so that the body is not outputted when the src attribute is set. Fix submitted
by James C. McMaster.
  
  Revision  Changes    Path
  1.6       +11 -7     jakarta-ecs/src/java/org/apache/ecs/html/Script.java
  
  Index: Script.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ecs/src/java/org/apache/ecs/html/Script.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- Script.java	27 Apr 2003 09:03:51 -0000	1.5
  +++ Script.java	2 May 2003 09:54:59 -0000	1.6
  @@ -269,9 +269,11 @@
       {
           StringBuffer out = new StringBuffer();
           out.append(super.createStartTag());
  -        out.append("\n");
  -        out.append("<!--");
  -        out.append("\n");
  +        if (!(hasAttribute("src"))) {
  +            out.append("\n");
  +            out.append("<!--");
  +            out.append("\n");
  +        }
           return(out.toString());
       }
       /**
  @@ -283,9 +285,11 @@
       public String createEndTag()
       {
           StringBuffer out = new StringBuffer();
  -        out.append("\n");
  -        out.append("// -->");
  -        out.append("\n");
  +        if (!(hasAttribute("src"))) {
  +            out.append("\n");
  +            out.append("// -->");
  +            out.append("\n");
  +        }
           out.append(super.createEndTag());
           return(out.toString());
       }
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: ecs-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: ecs-dev-help@jakarta.apache.org


Mime
View raw message