View Full Version : CSS usage question
swatdesigns
05-16-2006, 02:20 PM
Since I have never really worked with php until now I am not sure how to set up my html pages with css. If the header has refrence to the css, do the other html files that get called into a page need to have refrence,or just the header? How does that work?
_Aerospace_Eng_
05-16-2006, 03:32 PM
What you want is to use is php includes. These are files that are used on all of the pages. Tutorial here http://www.joe2torials.com/view_tutorial.php?view=3
This is the basic setup for my site's pages.
<?php
include("includes/mimetype.php");
set_header();
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<?php include ("includes/stylejs.php"); ?>
<title>PRDesignz - Designing for the Future - Home</title>
</head>
<body>
<div id="container">
<?php include ("includes/header.php"); ?>
<div id="left-col">
<?php include ("includes/navigation.php"); ?>
<br />
<?php include ("includes/poll.php"); ?>
</div>
<div id="mid-col">
<?php include ("includes/homecontent.php"); ?>
</div>
<?php include ("includes/footer.php"); ?>
</div>
</body>
</html>
inside of stylejs.php is this
<meta http-equiv="Content-Type" content="application/xhtml+xml;charset=utf-8" />
<meta http-equiv="Imagetoolbar" content="no" />
<link rel="stylesheet" href="css/style.css" type="text/css" />
<script type="text/javascript" src="javascript/global.js"></script>
swatdesigns
05-16-2006, 03:49 PM
Awsome, this is just what I needed! You have saved the day!:thumbsup:
vBulletin® v3.8.2, Copyright ©2000-2012, Jelsoft Enterprises Ltd.