-2

在我的网站上,首页的页脚比其余页面的页脚略窄,并且每边留有大约 30 个像素的空白边距。我正在通过 Worpress 工作。有没有其他人看到这个问题?

<?php get_header(); ?>  
<!-- ADVERTISEMENT-->
<div style="height:150px; width:250px; background-color:#0072bc; float: right; margin-right:5%;"><p style="color:white; font-size:2em; text-align:center; line-height: 75px;">Advertisement Placeholder</p></div>


<div style="border-radius:5px;background-color:orange;text-align:center; width:650px;height:50px;margin-bottom:10px;"><p style="color:white;font:bold;font-size:3em;line-height:50px;">STEP 1 to finding The Right Car</p></div>
<table style="width: 600px; border:3px solid black">
<thead>
<tr>
<th style="text-align: center; font-size: 20; padding: 6px; background-color: #0072bc; color: white;" colspan="2">Begin with info that will be applied to all cars</th>
</tr>
</thead>
<tbody>
<tr>
<td>How many <b> miles </b> do you drive each year?</td>
<td><form action="step2" method="post"><input type="text" maxlength="5" name="miles" value="10000"></td>
</tr>
<tr>
<td>What is your local <b> gas price</b>?</td>
<td><input type="text" maxlength="4" name="GasPrice" value="3.75" /></td>
</tr>
<tr>
<td>How many <b> years </b> are you planning to use the car?</td>
<td><input type="text" maxlength="2" name="years" value="7" /></td>
</tr>
<tr>
<td>How much do you value <b> safety </b> on a scale of 0-10? (0=low, 5=Average 10=A lot)</td>
<td><input type="text" maxlength="2" name="safety" value="5" /></td>
</tr>
<tr>
<td>How much do you value the <b> condition</b> of a car on a scale of 0-10? (0=low, 5=Average 10=A lot)</td>
<td><input type="text" maxlength="2" name="valuecondition" value="5" /></td>
</tr>
<tr>
<td>What is your <b> tax rate </b> (Will soon ask for ZIP CODE)?</td>
<td><input type="text" maxlength="5" name="TaxRate" value="7.50" /></td>
</tr>
</tbody>
</table>



<div style="border:2px solid black;border-radius:10px; width:450px;float:left;height:70px;"><p style="width:450px;height:20px; color:black;">How many cars do you currently have to compare?</p>

<input type="radio" name="NumberOfCars" value="0" /> 0 Cars <input type="radio" name="NumberOfCars" value="1" /> 1 Car <input type="radio" name="NumberOfCars" value="2" /> 2 Cars <input type="radio" name="NumberOfCars" value="3" /> 3 Cars    <input type="radio" name="NumberOfCars" value="4" /> 4 Cars    <input type="radio" name="NumberOfCars" value="5" checked/> 5 Cars</div>


<br>
<!--SUBMIT BUTTON-->
<div style="clear: both; width: 112px; height: 29px; float:left; margin-left:275px;padding-top:7px;padding-bottom:10px;"><p style="text-align: center;"><input id="submitbutton" style="width: 112px; height: 29px; background-color: #0072bc; color: white;" type="submit" size="1" value="To The Cars!" /></p></div></form>

<?php get_footer(); ?>


<div class="clear"></div>
<!--Start Footer-->
<div class="footer-wrapper">
    <div class="footer">
        <div class="container_24">
            <div class="grid_24">
                <?php
                /* A sidebar in the footer? Yep. You can can customize
                 * your footer with four columns of widgets.
                 */
                get_sidebar('footer');
                ?>

            </div>
            <div class="clear"></div>
        </div>
        <div class="footersep"></div>
        <div class="clear"></div>
        <div class="footer-bottom-wrapper">
            <div class="footer-bottom">
                <div class="container_24">
                    <div class="grid_24">
                        <div class="copyrightinfo">
                            <div class="grid_12 alpha">
                            <p class="blogdes">  <span class="blog-desc">               
                                    <?php echo get_bloginfo('title'); ?>
                                    -
                                    <?php echo get_bloginfo('description'); ?>
                                </span></p>
                            </div>
                           <!-- <div class="grid_12 omega">
                            <?php if (infoway_get_option('infoway_footertext') != '') { ?>
                                <p class="copyright"><?php echo infoway_get_option('infoway_footertext'); ?> </p>
                            <?php } else { ?>
                                <p class="copyright"> <?php _e('<a href="http://www.inkthemes.com">Infoway Theme</a> powered by <a href="http://www.wordpress.org">WordPress</a>','infoway'); ?></p>
                            <?php } ?>
                                </div>-->
                        </div>
                    </div>
                    <div class="clear"></div>
                </div>
            </div>
        </div>
    </div>
</div>
</div>
</div>
<!-- container -->
<?php wp_footer(); ?>
</body>
</html>
4

1 回答 1

1

似乎有几个关闭的 div 丢失了 - 可能是由于从您的内容中引入了新的 div(或者在编辑 front-page.php 文件时)

(具体来说,body_wrapperwrapperdiv 似乎最终没有被正确关闭,除其他问题外)

建议您从“空白”或新鲜的内容开始,然后再次添加内容,因为它有点难以诊断。

如果您有时间,最好避免使用内联样式(http://www.nomensa.com/blog/2011/inline-styles-and-why-they-are-considered-harmful-for-accessibility/)和只需从您的基本 HTML 开始。

p/s:Infoway,您当前使用的主题是 1.6.x 版本,因此可能值得使用更新版本的主题文件,因为您的主题文件似乎是 1.1.x?

于 2013-09-26T23:41:46.717 回答