Css Problem in php Seite

sbmiles21

Grünschnabel
Hallo zusammen,
stehe vor einem Problem, habe schon alles ausprobiert , aber es klappt nicht;(*
Problem: Die in der css datei definierten formatierungen klappen nicht. Habe z.b <h1> definiert, wird aber nicht umgesetzt;(



Ich habe eine index.php, welche einen content div ladet

Die Index:
HTML:
<!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">

<head>
		<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
		<title>
		</title>
		<style type="text/css">
		 <!--
		 @import url(style.css);
		
		 -->
		 </style>
		<script type="text/javascript">
		function oeffnefenster (url) {
		   fenster = window.open(url, "Photo", "width=600,height=400,status=yes,scrollbars=yes,resizable=no");
		   fenster.focus();
		}
		</script>


</head>

<body>
.........................
	<div id="content">
		<?php
		$pages_dir='pages';
		
		if (!empty($_GET['p'])){
			
			$pages=scandir($pages_dir,0); 
			unset($pages[0],$pages[1]);
			
			
			$p=$_GET['p'];
			if (in_array($p.'.inc.php',$pages)){
				include ($pages_dir.'/'.$p.'.inc.php');
			
			} else{
			echo 'Page not found';
			}
			}else{
			include($pages_dir.'/home.inc.php');
			}
		?>
	
	</div>
.................

</body>
</html>

Die CSS Datei, welche extern liegt:
Code:
		body {
		font-family: Arial;
		font-size: 100%;
		text-align: center;
		margin-right: 0px;
		margin-left: 0px;
		background-color: #999999;
		}
		
		div#header 
		{  
		width: 1000px;
		height: 180px;
		background-color: white;
		margin:auto;
		}
		
		div#menue
		{  
		width: 1000px;
		height: 25px;
		background-color: white;
		margin:auto;
		}
		
		a.menuewords 
		{  
		margin-bottom:auto; text-align:center; width:16ex; font-weight: bold; 
        border-style:ridge; border-width:0px; padding:5px; text-decoration:none; 
		}
		a.menuewords:link    { color:blue; background-color:transparent; }
		a.menuewords:visited { color:green; background-color:transparent; }
		a.menuewords:hover   { color:white; background-color:#00f; }
		a.menuewords:active  { color:#ff0; background-color:#a03; }

		div#content 
		{  
		width: 1000px;
		height: auto;
		background-color: #008000;
		margin:auto;
		.a1 {font-size: 50pt; color: #ff00ff; font-family: courier}
		}
		div#footer 
		{  
		width: 1000px;
		height: 50px;
		background-color: white;
		margin:auto;
		}
		
		textarea#detail
		{
		resize:none;
		width:300px;
		}
		input
		{
		resize:none;
		width:300px;
		}
		<!--Überschrift1 seiten-->
		h1 { 
		font-size:20pt;
     	color:#FF0000;
     	font-style:italic;
     	border-bottom:solid thin black; 
		}
		<!--Text seiten-->


Die php/html Datei welche in den div tag geladen wird:
HTML:
<h1>TEST </h1>


............


Egal was ich an h1 ändere, er übernimmt immer die Formatierung, welche ich für body festgelegt habe. Auch ohne body css formatierung ändert sich nichts ;(*

Hat jemand einen Tip?

Gruss
 
Zuletzt bearbeitet:
Du darfst in der CSS-Datei keine HTML-Kommentare wie

HTML:
        <!--Überschrift1 seiten-->

einfügen. Es gibt für CSS einen eigenen Kommentar-Syntax.
 

Neue Beiträge

Zurück