在我的网站上,我有一个联系页面,其中包含一个 PHP 文件。(php 文件是一个联系人公式)奇怪的是,这包含导致顶部导航、页眉和页脚切换了一下。PHP 文件不包含任何 CSS 样式更改。我真的无法弄清楚为什么会这样,也许你有一个想法。
这是我的代码:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><!-- InstanceBegin template="/Templates/template_EU.dwt" codeOutsideHTMLIsLocked="false" -->
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- InstanceBeginEditable name="doctitle" -->
<title>LoL StreamGallery</title>
<!-- InstanceEndEditable -->
<link rel="stylesheet" type="text/css" href="Templates/stylesheet.css">
<link href="SpryAssets/SpryMenuBarHorizontal.css" rel="stylesheet" type="text/css" />
<script src="SpryAssets/SpryMenuBar.js" type="text/javascript"></script>
<script type="text/javascript">
function MM_swapImgRestore() { //v3.0
var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_preloadImages() { //v3.0
var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
function MM_findObj(n, d) { //v4.01
var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}
function MM_swapImage() { //v3.0
var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
</script>
<!-- InstanceBeginEditable name="head" -->
<!-- InstanceEndEditable -->
</head>
<body onload="MM_preloadImages('Images/List/diverse/home_mo.png','Images/List/diverse/requestStream_mo.png','Images/List/diverse/AboutContact_mo.png','Images/List/diverse/Lol_mo.png','Images/List/diverse/fb_mo.png','Images/List/diverse/tw_mo.png')">
<!-- grüner Overhead -->
<div id="overhead">
<div id="overheadText">
<!-- Home -->
<a href="index.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Home','','Images/List/diverse/home_mo.png',1)"><img src="Images/List/diverse/home.png" alt="Home" name="Home" width="55" height="30" border="0" id="Home" /></a>
<!-- Request Streams -->
<a href="RequestStream.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('RequestStream','','Images/List/diverse/requestStream_mo.png',1)"><img src="Images/List/diverse/requestStream.png" alt= "RequestStream" name="RequestStream" width="113" height="30" border="0" id="RequestStream" /></a>
<!-- About&Contact -->
<a href="AboutContact.php" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('AboutContact','','Images/List/diverse/AboutContact_mo.png',1)"><img src="Images/List/diverse/AboutContact.png" alt="About&Contact" name="AboutContact" width="113" height="30" border="0" id="AboutContact" /></a>
<!-- Play LoL -->
<a href="http://www.leagueoflegends.com" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Lol','','Images/List/diverse/Lol_mo.png',1)"><img src="Images/List/diverse/Lol.png" alt="Play LeagueofLegends" name="Lol" width="160" height="30" border="0" id="Lol" /></a>
<!-- Rechtsbündig -->
<span style="float:right">
<!-- Facebook -->
<a href="https://www.facebook.com/Lolstreamgallery" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('FB','','Images/List/diverse/fb_mo.png',1)"><img src="Images/List/diverse/fb.png" alt="Facebook" name="FB" width="31" height="30" border="0" id="FB" /></a>
<!-- Twitter -->
<a href="https://twitter.com/LStreamGallery" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Twitter','','Images/List/diverse/tw_mo.png',1)"><img src="Images/List/diverse/tw.png" alt="Twitter" name="Twitter" width="31" height="30" border="0" id="Twitter" /></a>
</span>
</div>
</div>
<!-- website Wrapper -->
<div id="website">
<!-- Header -->
<div id="header">
<p>
<a href="index.html"><img src="Images/logo.png"/></a>
</p>
</div>
<!-- Main Wrapper -->
<div id="main">
<!-- Anzeige für Streams -->
<div id="content">
<!-- InstanceBeginEditable name="Streamcode" -->
<p><h1>About us:</h1></p>
Lol StreamGallery was launched in early 2013 from Jakob Abfalter with the help and ideas of Bernhard Abfalter, Michael Langhammer, Martin Langhammer, Anton Schendel.
The website belongs to and was programmed by Jakob Abfalter.
<p><h1>Media owner:</h1></p>
<span class="close">
<p><b>Jakob Abfalter</b></p>
<p>Uferweg 4</p>
<p>3341 Ybbsitz</p>
<p>Austria</p>
<p>JakobAbfalter@gmail.com</p>
</span>
<p><h1>Get in touch with us:</h1></p>
<span class="close">
<p>Follow us on <a href="https://www.facebook.com/Lolstreamgallery">Facebook</a></p>
<p>Follow us on <a href="https://twitter.com/LStreamGallery">Twitter</a></p>
<p>Send us a mail:</p>
</span>
<?php
include("html-contact-form-captcha/html-contact-form.php");
?>
<!-- InstanceEndEditable -->
</div>
<!-- Menüleiste -->
<div id="right">
<ul id="MenuBar1" class="MenuBarHorizontal">
<li><a href="Asia.php" target="sideframe">Asia</a></li>
<li><a href="NA.php" target="sideframe">NA</a></li>
<li><a href="EU.php" target="sideframe">EU</a></li>
</ul>
<iframe src="EU.php" width="212px" height="980px" name="sideframe" frameborder="0"></iframe>
</div>
</div>
<!-- Main Wrapper Ende -->
</div>
<!-- Website Wrapper Ende -->
<!-- Fußzeile -->
<div id="footer">
Copyright 2013 © LolStreamGallery - <a href="TermsofUse.html">Terms of Use</a>
</div>
<script type="text/javascript">
var MenuBar1 = new Spry.Widget.MenuBar("MenuBar1", {imgDown:"SpryAssets/SpryMenuBarDownHover.gif", imgRight:"SpryAssets/SpryMenuBarRightHover.gif"});
</script>
</body>
<!-- InstanceEnd --></html>
我还发现,PHP Include 会导致页脚中的链接变粗。希望你们中的一些人有一个想法,我该如何解决这个问题。
编辑:问题已解决 - php 文件包含一些我过度阅读的 CSS,这导致了问题。