PHP. Could someone help me?

Krueger81

Diamond Member
Feb 4, 2000
4,196
3
81
Hello,

i am trying to play around with PHP and I am having a hard time even getting the basics down.

I have four files here that I am trying to ty together. I'd be willing to e-mail them out to people to see if there is an erro in the code.

I mean these are basic files with a header a footer and an index page.

Let me know if you guys can help me.

Thanks
Phil
 

Krueger81

Diamond Member
Feb 4, 2000
4,196
3
81
index.php File

<?php include("header.php"); ?>
<?php include("main.php"); ?>
<?php include("footer.php"); ?>


main.php File

Computers United - Central IL Lan Party

Coming soon....



header.php file

<html>
<head>
<title> Computers United - Central IL Lan Party</title>
</head>
<body>
Computers United - Central IL Lan Party



footer.php file

</body>
</html>


Thanks
Phil

 

kt

Diamond Member
Apr 1, 2000
6,032
1,348
136
It doesn't work that way. The files you include are treated as PHP code.
 

jonmullen

Platinum Member
Jun 17, 2002
2,517
0
0
Originally posted by: kt
It doesn't work that way. The files you include are treated as PHP code.

only if they have the php tags or if you eval() the files...but since you are basically just using php to tie the pages to geather...you might consider just using SSI if your server supports it, which it should if it has php support. secondly what errors are you getting that is causing you script to "not work"