2014-04-25 86 views
0

表标签内的Html标题标签问题。问题在于对齐。表标签内部的HTML标题标签的浏览器问题

<html:form action="myAction"> 

<table border=0 id="main_table" width="100%"> 
     <tr> 
      <td> 
      <table id="t1" width="100%"> 
       <caption align= "left" id="t1_c"> 
        <b><bean:message key="schedule.automatic"/></b> 
       </caption> 
      <tr> 
       <td> 
        <label> 
         <input type=radio name="gather_group" value='NEVER'  onclick="selectRadio(this.value)"> 
          <bean:message key="myconsole.schedule.never"/> 
        </label> 
       </td> 
      </tr> 
      </table> 
      </td> 
      <table id="t2" width="100%"> 
       <caption align="left" id="t2_c"> 
       <b><bean:message key="schedule.whenToGather"/></b> 
       </caption> 
       <tr id="t2_r1"> 
       <td><bean:message key="schedule.hourOfDay"/></td> 
       </tr> 
      </table> 
     </tr> 

我认为标题标签具有不同的浏览器运行时的问题。 使用bean:message属性显示的文本在IE8及更高版本中完美显示,但在firefox版本-28.0中,chrome,safari ..文本位置被移位。

任何帮助表示赞赏。

注:我不使用HTML5

回答

0

我已经得到了修复本身,使用内嵌样式属性这样。 。

<caption align= "left" id="t1_c" style="caption-side: top; width: auto; text-align: left;"> 

感谢所有。

1

第二嵌套表不内TD标签:

<table border=0 id="main_table" width="100%"> 
    <tr> 
     <td> 
     <table id="t1" width="100%"> 
      <caption align= "left" id="t1_c"> 
       <b><bean:message key="schedule.automatic"/></b> 
      </caption> 
     <tr> 
      <td> 
       <label> 
        <input type=radio name="gather_group" value='NEVER'  onclick="selectRadio(this.value)"> 
         <bean:message key="myconsole.schedule.never"/> 
       </label> 
      </td> 
     </tr> 
     </table> 
     </td> 
     <td> <!-- Missing td tag --> 
     <table id="t2" width="100%"> 
      <caption align="left" id="t2_c"> 
      <b><bean:message key="schedule.whenToGather"/></b> 
      </caption> 
      <tr id="t2_r1"> 
      <td><bean:message key="schedule.hourOfDay"/></td> 
      </tr> 
     </table> 
     </td> <!-- Missing td closing tag --> 
    </tr> 
+0

我已经向您展示了小代码片段..但我仍然会检查这一点..因为此代码在IE中完美工作。如果这是td标签的问题,那么它也不应该在IE上工作。 – vermaraj