Wednesday, June 25, 2014

Check box value retrieve Syntax declare way in jsp page



<span>
      <s:if test='%{institutes.science_group == "1"}'>
         <input name="scienceGroupMore1" id="scienceGroupMore1" onFocus="this.style.backgroundColor='#ffff66';" onBlur="this.style.backgroundColor='#d4e3e5';" type="checkbox" value="1" checked>Science
         </s:if>
         <s:else>
         <input name="scienceGroupMore1" id="scienceGroupMore1" onFocus="this.style.backgroundColor='#ffff66';" onBlur="this.style.backgroundColor='#d4e3e5';" type="checkbox" value="1" >Science
         </s:else> 
      </span>
   
   
   
    <span>
      <s:if test='%{institutes.arts_group == "2"}'>
         <input name="humanitiesGroupMore1" id="humanitiesGroupMore1" onFocus="this.style.backgroundColor='#ffff66';" onBlur="this.style.backgroundColor='#d4e3e5';" type="checkbox" value="2" checked>Humanities
         </s:if>
         <s:else>
         <input name="humanitiesGroupMore1" id="humanitiesGroupMore1" onFocus="this.style.backgroundColor='#ffff66';" onBlur="this.style.backgroundColor='#d4e3e5';" type="checkbox" value="2" >Humanities
         </s:else>
    </span>
   
   
    <span>
     <s:if test='%{institutes.commerce_group == "3"}'>
         <input name="businessGroupMore1" id="businessGroupMore1" onFocus="this.style.backgroundColor='#ffff66';" onBlur="this.style.backgroundColor='#d4e3e5';" type="checkbox" value="3" checked>Business   
         </s:if>
         <s:else>
         <input name="businessGroupMore1" id="businessGroupMore1" onFocus="this.style.backgroundColor='#ffff66';" onBlur="this.style.backgroundColor='#d4e3e5';" type="checkbox" value="3" >Business   
         </s:else>    
    </span>
    </td>

No comments:

Post a Comment