在我的 TST 和 PRD 环境之间,我在 SharePoint 2007 上遇到了一些“奇怪”的差异。我正在自定义列表的 EditForm,我注意到我在 TST 上创建的新表单正确显示如下:
这是我想要的风格。但是,当我在 PRD 上执行完全相同的操作时,这就是我得到的结果,请注意额外的表单字段标签和围绕相同两个字段的包装器:
(生成的 html 文件的)来源也不同:
Correctly displayed:
<tr><td width="190px" valign="top" class="ms-formlabel"><H3 class="ms-standardheader"><nobr>Profit Centre<span class="ms-formvalidation"> *</span></nobr></H3></td>
<td width="400px" valign="top" class="ms-formbody"><span dir="none">
<input name="ctl00$m$g_193d5406_ba72_454b_b14c_87873ba714d6$ff5_1$ctl00$ctl00$TextField" type="text" value="ALL" maxlength="255" id="ctl00_m_g_193d5406_ba72_454b_b14c_87873ba714d6_ff5_1_ctl00_ctl00_TextField" title="Profit Centre" class="ms-long" /><br>
</span></td></tr>
<tr><td width="190px" valign="top" class="ms-formlabel"><H3 class="ms-standardheader"><nobr>Status<span class="ms-formvalidation"> *</span></nobr></H3></td>
<td width="400px" valign="top" class="ms-formbody"><span dir="none"><select name="ctl00$m$g_193d5406_ba72_454b_b14c_87873ba714d6$ff6_1$ctl00$DropDownChoice" id="ctl00_m_g_193d5406_ba72_454b_b14c_87873ba714d6_ff6_1_ctl00_DropDownChoice" title="Status" class="ms-RadioText">
<option selected="selected" value="Not Yet Reconciled">Not Yet Reconciled</option>
<option value="Reconciled">Reconciled</option>
<option value="Reviewed">Reviewed</option>
<option value="Rejected by Reviewer">Rejected by Reviewer</option>
<option value="Approved">Approved</option>
<option value="Rejected by Approver">Rejected by Approver</option>
</select><br></span></td></tr>
===========================================================
Annoying wrapper displayed:
<tr><td width="190px" valign="top" class="ms-formlabel"><H3 class="ms-standardheader"><nobr>Profit Centre<span class="ms-formvalidation"> *</span></nobr></H3></td>
<td width="400px" valign="top" class="ms-formbody">
<div align="left" class="ms-formfieldcontainer">
<div class="ms-formfieldlabelcontainer" nowrap="nowrap">
<span class="ms-formfieldlabel" nowrap="nowrap">Profit Centre</span></div>
<div class="ms-formfieldvaluecontainer">
<span dir="none">
<input name="ctl00$m$g_7716bb24_9fc9_4e72_a2c6_bec888418014$ff6_1$ctl00$ctl00$TextField" type="text" value="ALL" maxlength="255" id="ctl00_m_g_7716bb24_9fc9_4e72_a2c6_bec888418014_ff6_1_ctl00_ctl00_TextField" title="Profit Centre" class="ms-long" /><br>
</span></div></div></td></tr>
<tr><td width="190px" valign="top" class="ms-formlabel"><H3 class="ms-standardheader"><nobr>Status<span class="ms-formvalidation"> *</span></nobr></H3></td>
<td width="400px" valign="top" class="ms-formbody">
<div align="left" class="ms-formfieldcontainer">
<div class="ms-formfieldlabelcontainer" nowrap="nowrap">
<span class="ms-formfieldlabel" nowrap="nowrap">Status</span></div><div class="ms-formfieldvaluecontainer">
<span dir="none">
<select name="ctl00$m$g_7716bb24_9fc9_4e72_a2c6_bec888418014$ff7_1$ctl00$DropDownChoice" id="ctl00_m_g_7716bb24_9fc9_4e72_a2c6_bec888418014_ff7_1_ctl00_DropDownChoice" title="Status" class="ms-RadioText">
<option value="Not Yet Reconciled">Not Yet Reconciled</option>
<option selected="selected" value="Reconciled">Reconciled</option>
<option value="Reviewed">Reviewed</option>
<option value="Rejected by Reviewer">Rejected by Reviewer</option>
<option value="Approved">Approved</option>
<option value="Rejected by Approver">Rejected by Approver</option>
</select><br></span></div></div></td></tr>
如何删除额外的字段容器和相关字段标签?为什么它在这两个 SP2007 环境中表现不同?
非常感谢您的提示和回答。提前致谢。