PHP Includes Not Working

 
Post new topic   Reply to topic    Aprelium Forum Index -> PHP
View previous topic :: View next topic  
Author Message
mg66
-


Joined: 15 Aug 2004
Posts: 85
Location: USA, Illinois

PostPosted: Sun Mar 27, 2005 4:19 pm    Post subject: PHP Includes Not Working Reply with quote

I just installed PHP 5.x on my test server to play around with PHP. I cant even get the basic includes working.

I setup php using Trustpunk's tutorial and have checked my X2 config and seems ok. I am using the following code on my index.php to include a header and footer ...

<!--#include file="/includes/bghi-header.htm" -->
<!--#include file="/includes/bghi-footer.htm" -->

Any ideas?
_________________
mg66

http://sv650.metromain.net
http://photography.metromain.net
http://weather.metromain.net
http://www.metromain.net
http://www.bghi.us


Abyss Web Server X2
Back to top View user's profile Send private message Visit poster's website
Glitch2082
-


Joined: 02 Dec 2004
Posts: 194

PostPosted: Sun Mar 27, 2005 4:26 pm    Post subject: Reply with quote

Well your using the wrong tags :D

<? include("header.php"); ?>
<? include("footer.php"); ?>
_________________
int main() {
cout << "Im Pro Apache";
cin.get();
}
Back to top View user's profile Send private message Send e-mail
mg66
-


Joined: 15 Aug 2004
Posts: 85
Location: USA, Illinois

PostPosted: Sun Mar 27, 2005 4:35 pm    Post subject: Reply with quote

So icant use htm extensions. They have to be .php
_________________
mg66

http://sv650.metromain.net
http://photography.metromain.net
http://weather.metromain.net
http://www.metromain.net
http://www.bghi.us


Abyss Web Server X2
Back to top View user's profile Send private message Visit poster's website
Glitch2082
-


Joined: 02 Dec 2004
Posts: 194

PostPosted: Sun Mar 27, 2005 4:41 pm    Post subject: Reply with quote

The include can be anything, I could use;
include("hi.GlitchRulesTheWorld");

THe include can also be...
include "filename.ext";
_________________
int main() {
cout << "Im Pro Apache";
cin.get();
}
Back to top View user's profile Send private message Send e-mail
mg66
-


Joined: 15 Aug 2004
Posts: 85
Location: USA, Illinois

PostPosted: Sun Mar 27, 2005 4:45 pm    Post subject: Reply with quote

Working now. Thanx for the help.
_________________
mg66

http://sv650.metromain.net
http://photography.metromain.net
http://weather.metromain.net
http://www.metromain.net
http://www.bghi.us


Abyss Web Server X2
Back to top View user's profile Send private message Visit poster's website
Glitch2082
-


Joined: 02 Dec 2004
Posts: 194

PostPosted: Sun Mar 27, 2005 4:46 pm    Post subject: Reply with quote

No problem.
_________________
int main() {
cout << "Im Pro Apache";
cin.get();
}
Back to top View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic    Aprelium Forum Index -> PHP All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB phpBB Group