Php CMS表单未按照css正确显示
我使用的是CMS系统,它有一个生成表单的模板,带有预定义的CSS 正在使用的CSS文件是 我目前使用的表格是:Php CMS表单未按照css正确显示,php,html,css,Php,Html,Css,我使用的是CMS系统,它有一个生成表单的模板,带有预定义的CSS 正在使用的CSS文件是 我目前使用的表格是: <div class="bodyline"> <?php $theform->startForm($pageTitle)?> <div id="rightSideDiv"> <fieldset> <legend><label for="report">
<div class="bodyline">
<?php $theform->startForm($pageTitle)?>
<div id="rightSideDiv">
<fieldset>
<legend><label for="report">Report</label></legend>
<p>
<?php $theform->showField("towel")?>
</p>
</fieldset>
</div>
<div id="leftSideDiv">
<fieldset>
<legend><label for="name">Info</label></legend>
<p class="big"><?php $theform->showField("firstname"); ?></p>
<p class="big"><?php $theform->showField("lastname"); ?></p>
<p class="big"><?php $theform->showField("country"); ?></p>
<p class="big"><?php $theform->showField("passport"); ?></p>
<p class="big"><?php $theform->showField("email"); ?></p>
<p class="big"><?php $theform->showField("roomnumber"); ?></p>
<p class="big"><?php $theform->showField("hostel"); ?></p>
<p class="big"><?php $theform->showField("checkin"); ?></p>
<p class="big"><?php $theform->showField("checkout"); ?></p>
<p class="big"><?php $theform->showField("locker"); ?></p>
<p class="big"><?php $theform->showField("towel"); ?></p>
<p class="big"><?php $theform->showField("tabno"); ?></p>
</fieldset>
</div>
</div>
报告
信息
理论上,这应该在左边显示一个方框,在右边显示一个方框。相反,rightSideDiv显示在leftSideDiv的上方或下方,占据表单的整个宽度
生成的HTML是
<form action="/1/phpbms/modules/micro%20hospitality/guests_addedit.php?id=1" method="post" name="record" onsubmit="return validateForm(this);"><div id="dontSubmit"><input value=" " onclick="return false;" type="submit"></div> <div id="topButtons"><div class="saveCancels"><input accesskey="s" title="Save (alt+s)" id="saveButton1" name="command" value="save" class="Buttons" type="submit"><input id="cancelButton1" name="command" value="cancel" class="Buttons" onclick="this.form.cancelclick.value=true;" accesskey="x" title="(access key+x)" type="submit"></div></div>
<h1 id="h1Title"><span>Guests</span></h1>
<div id="rightSideDiv">
<fieldset>
<legend><label for="report">Report</label></legend>
<p>
<input id="towel" name="towel" value="1" class="radiochecks" type="checkbox"> <label id="towelLabel" for="towel">Towel</label> </p>
</fieldset>
</div>
<div id="leftSideDiv">
<fieldset>
<legend><label for="name">Info</label></legend>
<p class="big"><label for="firstname" class="important">First Name</label><br><input id="firstname" name="firstname" value="Jason" size="32" maxlength="64" class="important" type="text"></p>
</fieldset>
</div>
</form>
客人
报告
毛巾
信息
名字
现在,包含的表单工作正常,我不知道为什么
适用于以下页面的包含表单代码:
<div class="bodyline">
<?php $theform->startForm($pageTitle)?>
<div id="rightSideDiv">
<fieldset>
<legend><label for="importance">importance / privacy</label></legend>
<p>
<?php $theform->showField("importance")?>
<?php $theform->showField("private")?>
</p>
</fieldset>
</div>
<div id="leftSideDiv">
<fieldset>
<legend><label for="content">memo</label></legend>
<p id="timeStampP">
<button id="timeStampButton" type="button" class="graphicButtons buttonTimeStamp" accesskey="t" title="Add time stamp to memo (Access Key - t)">time stamp</button>
</p>
<p>
<textarea name="content" cols="45" rows="23" id="content"><?php echo htmlQuotes($therecord["content"])?></textarea>
<input id = "username" type="hidden" value="<?php echo formatVariable(trim($_SESSION["userinfo"]["firstname"]." ".$_SESSION["userinfo"]["lastname"]))?>" />
</p>
</fieldset>
</div>
</div>
重要性/隐私
备忘录
时间戳
leftSideDiv没有浮动。在css中重新定义或将其设置为内联样式:
float:left
它还需要附加一个宽度,这取决于容器的宽度。这可能有助于:
您是否使用Firebug查看过该页面?为什么一个页面可以正常工作,尽管leftSideDiv没有浮动,而另一个页面没有浮动?如果他们在这方面是平等的,原因不是别的吗?你有一个在线版本,我们可以看看吗?嗨,阿什利,我不能提供没有用户名和密码不幸。如果你愿意,我可以通过你的网站私下给你?
float:left