## org.apache.portals.bridges.struts.taglib
Class ImgTag

    java.lang.Object
      javax.servlet.jsp.tagext.TagSupport
          javax.servlet.jsp.tagext.BodyTagSupport
              org.apache.struts.taglib.html.BaseHandlerTag
                  org.apache.struts.taglib.html.ImgTag
                      org.apache.portals.bridges.struts.taglib.ImgTag

All Implemented Interfaces:
  javax.servlet.jsp.tagext.BodyTag, javax.servlet.jsp.tagext.IterationTag, Serializable, javax.servlet.jsp.tagext.Tag

public class ImgTag
extends org.apache.struts.taglib.html.ImgTag

Supports the Struts html:img tag to be used within a Portlet context allowing relative img src paths.

Version:
  $Id: ImgTag.java 517068 2007-03-12 01:44:37Z ate $
Author:
  Ate Douma
See Also:
  Serialized Form

Field Summary

Fields inherited from class org.apache.struts.taglib.html.ImgTag
`action, align, border, contextRelative, height, hspace, imageName, ismap, lowsrc, messages, module, name, page, pageKey, paramId, paramName, paramProperty, paramScope, property, scope, src, srcKey, useLocalEncoding, usemap, vspace, width`

Fields inherited from class org.apache.struts.taglib.html.BaseHandlerTag
`accesskey, defaultLocale, doDisabled, doReadonly, indexed, tabindex`

Fields inherited from class javax.servlet.jsp.tagext.BodyTagSupport
`bodyContent`

Fields inherited from class javax.servlet.jsp.tagext.TagSupport
`id, pageContext`

Fields inherited from interface javax.servlet.jsp.tagext.BodyTag
`EVAL_BODY_BUFFERED, EVAL_BODY_TAG`

Fields inherited from interface javax.servlet.jsp.tagext.IterationTag
`EVAL_BODY_AGAIN`

Fields inherited from interface javax.servlet.jsp.tagext.Tag
`EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE`

Constructor Summary
`ImgTag()`

Method Summary
`int` `doEndTag()` Allow a relative img src path to be used within a PortletRequest context.

Methods inherited from class org.apache.struts.taglib.html.ImgTag

`doStartTag, getAction, getAlign, getBorder, getContextRelative, getHeight, getHspace, getImageName, getIsmap, getLowsrc, getModule, getName, getPage, getPageKey, getParamId, getParamName, getParamProperty, getParamScope, getProperty, getScope, getSrc, getSrcKey, getUsemap, getVspace, getWidth, isContextRelativeSet, isUseLocalEncoding, release, setAction, setAlign, setBorder, setContextRelative, setHeight, setHspace, setImageName, setIsmap, setLowsrc, setModule, setName, setPage, setPageKey, setParamId, setParamName, setParamProperty, setParamScope, setProperty, setScope, setSrc, setSrcKey, setUseLocalEncoding, setUsemap, setVspace, setWidth, src, url`

Methods inherited from class org.apache.struts.taglib.html.BaseHandlerTag

`doErrorsExist, getAccesskey, getAlt, getAltKey, getBundle, getDisabled, getElementClose, getErrorKey, getErrorStyle, getErrorStyleClass, getErrorStyleId, getIndexed, getIndexValue, getLocale, getOnblur, getOnchange, getOnclick, getOndblclick, getOnfocus, getOnkeydown, getOnkeypress, getOnkeyup, getOnmousedown, getOnmousemove, getOnmouseout, getOnmouseover, getOnmouseup, getOnselect, getReadonly, getStyle, getStyleClass, getStyleId, getTabindex, getTitle, getTitleKey, isXhtml, lookupProperty, message, prepareAttribute, prepareEventHandlers, prepareFocusEvents, prepareIndex, prepareKeyEvents, prepareMouseEvents, prepareName, prepareOtherAttributes, prepareStyles, prepareTextEvents, setAccesskey, setAlt, setAltKey, setBundle, setDisabled, setErrorKey, setErrorStyle, setErrorStyleClass, setErrorStyleId, setIndexed, setLocale, setOnblur, setOnchange, setOnclick, setOndblclick, setOnfocus, setOnkeydown, setOnkeypress, setOnkeyup, setOnmousedown, setOnmousemove, setOnmouseout, setOnmouseover, setOnmouseup, setOnselect, setReadonly, setStyle, setStyleClass, setStyleId, setTabindex, setTitle, setTitleKey`

Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport
`doAfterBody, doInitBody, getBodyContent, getPreviousOut, setBodyContent`

Methods inherited from class javax.servlet.jsp.tagext.TagSupport
`findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setParent, setValue`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface javax.servlet.jsp.tagext.Tag
`getParent, setPageContext, setParent`

Constructor Detail

### ImgTag

    public ImgTag()

Method Detail

### doEndTag

    public int doEndTag()
                 throws javax.servlet.jsp.JspException

  Allow a relative img src path to be used within a PortletRequest context.

  Temporarily modifies the `ImgTag.src` attribute value (if defined and if within the context of a `PortletRequest`).
  A relative src path is changed to a context relative path using the current request uri.

  Returns:
    `Tag.EVAL_PAGE`
  Throws:
    `javax.servlet.jsp.JspException`

Copyright © 2005-2007 Apache Software Foundation. All Rights Reserved.