struts-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oleg V Alexeev <go...@penza.net>
Subject Image tag handler
Date Sat, 11 Nov 2000 12:45:35 GMT
Hello struts-dev,

This is a tag to process image form tag, such as -

  <input type="image" src="images/sample.gif" alt="SampleImageSubmit">

to make image buttons in form.

Tag handler is inherited from SubmitTag.

Sample use -

  <struts:image path="images/" src="vnt.logon" isKey="true">
   <struts:message key="label.login"/>
  </struts:image>

  Properties -
    required
     src - file name for image, can be treated as key to retrieve
           string from message bundle if non null value for property
           isKey specified
    optional
     path - prefix for source string
     isKey - switcher, if not null then src property would be treated
             as key to retrieve file name from message bundle.
     locale - same as in message tag
     bundle - same as in message tag
     value - alt text for image
     and all another script and style properties from BaseHandlerTag

  If tag is not empty then body will be treated as value property.

 Strings to add to tag library definition -
 
  <tag>
    <name>image</name>
    <tagclass>org.apache.struts.taglib.form.ImageTag</tagclass>
    <attribute>
      <name>locale</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>bundle</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>accessKey</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onBlur</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onChange</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onClick</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onDblClick</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onFocus</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onKeyDown</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onKeyPress</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onKeyUp</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onMouseDown</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onMouseMove</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onMouseOut</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onMouseOver</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>onMouseUp</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>src</name>
      <required>true</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>style</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>styleClass</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>tabIndex</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>value</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>path</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
      <name>isKey</name>
      <required>false</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
  </tag>
 

-- 
Best regards,
 Oleg                          mailto:gonza@penza.net
Mime
View raw message