changed code generation for target attribute in xlink tags, in an attempt to

fix a HTML-generation problem with Electric Minds' "Posts" pages
This commit is contained in:
Eric J. Bowersox 2004-04-16 03:40:10 +00:00
parent adca4f5d91
commit 2a0b87bc84
2 changed files with 16 additions and 1 deletions

View File

@ -33,7 +33,7 @@ public class UtilTargetTag extends VeniceBodyTagSupport
UtilXLinkTag xlink = (UtilXLinkTag)findAncestorWithClass(this,UtilXLinkTag.class);
if (xlink!=null)
{ // set the link data
xlink.setTarget(getBodyContent().getString().trim());
xlink.setTarget2(getBodyContent().getString().trim());
return SKIP_BODY;
} // end if

View File

@ -45,6 +45,7 @@ public class UtilXLinkTag extends VeniceBodyTagSupport
private String target = null;
private String text = null;
private String title = null;
private boolean target_external = false;
/*--------------------------------------------------------------------------------
* Overrides from class BodyTagSupport
@ -105,6 +106,9 @@ public class UtilXLinkTag extends VeniceBodyTagSupport
type = -1;
text = null;
title = null;
if (target_external)
target = null;
target_external = false;
return EVAL_PAGE;
} // end doEndTag
@ -158,4 +162,15 @@ public class UtilXLinkTag extends VeniceBodyTagSupport
} // end setTitle
final void setTarget2(String s)
{
if (target==null)
{ // set target via external tag
target = s;
target_external = true;
} // end if
} // end setTarget2
} // end class UtilXLinkTag