0

我有一个容器 Div,在其中我有许多表,当我调用下拉菜单时,这些表不尊重 div 容器的大小。我无法弄清楚这一点,如果我显示下拉过滤器要阻止的类,它会尊重 div。如果我内联显示它会忽略它!并溢出容器。请帮忙!

<table cellspacing="0" cellpadding="1" border="0">
                <tr>               



<!--START: catFilter_Filter-->
                  <td class="item1"  style="border-right:1px solid #ccc;" >
                  <select name="catFilter" id="Select1" onchange="setCatFilter(this.value, document.frmsortby, false);">
                  <option value="">[catFilterName]</option>
                    <!--START: catFilter_Filter_Item--> 
                    <option value="[catFilterId]-*-[catFilterName]-*-[catFilterChildId]-*-[catFilterChildName]-*-[catid]-*-">[catFilterChildName] ([numItems])</option> 
                    <!--END: catFilter_Filter_Item--> 
                    </select></td>
                  <!--END: catFilter_Filter-->
                </tr>
              </table>
        <input type="hidden" name="hdnCatFilter" id="hdnCatFilter" value="[catFilter]" />
        <script type="text/javascript">
            function setCatFilter(strFilter, objForm, removeSubsequent)
            {
                if (removeSubsequent)
                {
                    //alert(strFilter);
                    objForm.hdnCatFilter.value = strFilter;
                }
                else
                {
                    objForm.hdnCatFilter.value = objForm.hdnCatFilter.value + '@' + strFilter;
                }
                //alert(objForm.hdnCatFilter.value);
                objForm.submit();
            }
            function removeCatFilter()
            {
                var objForm = document.frmsortby;
                objForm.hdnCatFilter.value = "";
                objForm.submit();
            }
        </script></td>
    </tr>
4

1 回答 1

0

<input>在包含和<script>标签之前,您的表已关闭。你有一个流氓</td></tr>。移动</table>到最后</tr>

于 2013-08-27T05:32:29.180 回答