The Mother Board

Motherboards.org forums. Free tech support, motherboard ID, and more.
It is currently Fri Sep 21, 2018 5:48 pm

All times are UTC - 8 hours




Post new topic Reply to topic  [ 19 posts ]  Go to page Previous  1, 2
Author Message
 Post subject:
PostPosted: Tue Dec 14, 2004 8:58 am 
Offline
Drunken Master

Joined: Tue Jan 18, 2000 1:01 am
Posts: 8854
Location: Fresno
Toby B. wrote:
The extension is .html


you need to tell php to parse .html files or change the ext to .php

As it stands now it is treating your php code as text. It is not parsing the html file as php code.

so what I would do is save a copy as .php now. Add the quotes to the includes and then run it. See what happens.

_________________
Not everything that can be counted counts, and not everything that counts can be counted - Albert Einstien


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Dec 14, 2004 9:12 am 
Offline
Lead Mobo-fu Master
Lead Mobo-fu Master

Joined: Sun Dec 16, 2001 1:01 am
Posts: 14301
Location: Maine
hmm, as index.html the php code will not show as it is supposed to. But as index.php it works.....

Is there a trick to getting php to work in .html files?

_________________
Compaq-Fu Master
Ctechinfo funding drive information


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Dec 14, 2004 9:51 am 
Offline
Drunken Master

Joined: Tue Jan 18, 2000 1:01 am
Posts: 8854
Location: Fresno
Toby B. wrote:
hmm, as index.html the php code will not show as it is supposed to. But as index.php it works.....

Is there a trick to getting php to work in .html files?


yes you have to add a handler in your php.ini file or in an htaccess file.

looks like this.

AddHandler application/x-httpd-php .html

_________________
Not everything that can be counted counts, and not everything that counts can be counted - Albert Einstien


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Dec 14, 2004 6:14 pm 
Offline
Lead Mobo-fu Master
Lead Mobo-fu Master

Joined: Sun Dec 16, 2001 1:01 am
Posts: 14301
Location: Maine
MoboCop wrote:
Toby B. wrote:
hmm, as index.html the php code will not show as it is supposed to. But as index.php it works.....

Is there a trick to getting php to work in .html files?


yes you have to add a handler in your php.ini file or in an htaccess file.

looks like this.

AddHandler application/x-httpd-php .html
IIRC the php.ini file is part of the server software which I have no access to (i am on a shared server not a dedicated server.)...

for an htaccess file I would just create a .htaccess file and upload it to main/root directory???

_________________
Compaq-Fu Master
Ctechinfo funding drive information


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Dec 14, 2004 9:05 pm 
Offline
Drunken Master

Joined: Tue Jan 18, 2000 1:01 am
Posts: 8854
Location: Fresno
Toby B. wrote:
MoboCop wrote:
Toby B. wrote:
hmm, as index.html the php code will not show as it is supposed to. But as index.php it works.....

Is there a trick to getting php to work in .html files?


yes you have to add a handler in your php.ini file or in an htaccess file.

looks like this.

AddHandler application/x-httpd-php .html
IIRC the php.ini file is part of the server software which I have no access to (i am on a shared server not a dedicated server.)...

for an htaccess file I would just create a .htaccess file and upload it to main/root directory???


I believe so. I dont mess with htaccess files so your best bet is google it real quick for some examples. SHould be plentiful.

_________________
Not everything that can be counted counts, and not everything that counts can be counted - Albert Einstien


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sat Jan 08, 2005 1:50 am 
Offline
Lead Mobo-fu Master
Lead Mobo-fu Master

Joined: Sun Dec 16, 2001 1:01 am
Posts: 14301
Location: Maine
Well I haven't figured out the issue on my "live" server but I got some headway on my test server. BUT I have run into a slight problem....

Unexpected T_VARIABLE on line 3:

Code:
<?php
include ('includes/header.inc')
$meta_title = "Index";
?>
<table border="0" cellpadding="5" cellspacing="0" width="100%" bgcolor="#000000">
<TR>
<td width="125" align="left" valign="top" bgcolor="#8b0000">
<table border="0" cellpadding="5" cellspacing="0" align="center" valign="top" width="98%"><tr><td>
<center><a href="http://www.qksrv.net/click-1542161-5835141" target="_blank" onmouseover="window.status='http://www.crucial.com/index.asp';return true;" onmouseout="window.status=' ';return true;">
<img src="http://www.qksrv.net/image-1542161-5835141" width="125" height="600" alt="Memory from Crucial.com" border="0"></a></center></td></tr></table>
</td>
<td width="700" align="left" valign="top" bgcolor="#FFFFFF"><table border="0" cellpadding="5" cellspacing="0" width="100%">
   <TR>
<td>

<H1>Index</H1>
<hr/>

<div class="contentheader"><b>Welcome to <i>Ctechinfo</i></b></div>

<table valign="top" style="border: 0px solid black; border-collapse: collapse; margin: 5; background color: transparent; float: left; width: 100%;">
<TR><TD>
      <p align="left">         This site is a colaborative effort between several people from from 3 different countries, and 2 continents. The idea of creating a site devoted to Compaq motherboard and system information was first tossed around approximately 3 years ago. Hardware Junkie started us off with 10 boards and we cotinued on a path that far exceeded any expectations. With the addition of HP info we now have detailed information on roughly 300 motherboards and that number keeps growing on a regular basis. If you cannot find what you need here, feel free to drop by <a href="./forum/index.php">our forum</a>.</p>

       <p align="left">         The ultimate plan for this site is to develop an indepth, detailed support site that provides accurate information. Some of the information we have collected is not even availible at any other site on the net.
       </p><br/>
<br/>
<br/>
       <p align="center"><img src="./images/formfctr.jpg" ALT="Presario PC's"></p>
<br/>
   </TD></TR></table>
</td></tr>
</table>
</td><td valign="top" align="right" width="125" bgcolor="#8b0000"><table border="0" cellpadding="5" cellspacing="0" align="center" valign="top" width="100%"><tr><td><center><a href="http://www.qksrv.net/click-1542161-8286434" target="_blank" onmouseover="window.status='http://www.lunarpages.com';return true;" onmouseout="window.status=' ';return true;">
<img src="http://www.qksrv.net/image-1542161-8286434" width="125" height="600" alt="500MB of storage for $7.95 a month!" border="0"></a></center>


</td>
</tr>
</table>
</body>
</HTML>

_________________
Compaq-Fu Master
Ctechinfo funding drive information


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sat Jan 08, 2005 3:07 am 
Offline
Lead Mobo-fu Master
Lead Mobo-fu Master

Joined: Sun Dec 16, 2001 1:01 am
Posts: 14301
Location: Maine
I got it figured out...

Code:
<?php
$meta_title = "Index";
include ('includes/header.inc')
?>

_________________
Compaq-Fu Master
Ctechinfo funding drive information


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sat Jan 08, 2005 11:07 am 
Offline
Drunken Master

Joined: Tue Jan 18, 2000 1:01 am
Posts: 8854
Location: Fresno
Toby B. wrote:
I got it figured out...

Code:
<?php
$meta_title = "Index";
include ('includes/header.inc')
?>


cool.

_________________
Not everything that can be counted counts, and not everything that counts can be counted - Albert Einstien


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sat Jan 08, 2005 6:32 pm 
Offline
Lead Mobo-fu Master
Lead Mobo-fu Master

Joined: Sun Dec 16, 2001 1:01 am
Posts: 14301
Location: Maine
Yes very cool! Somehow I managed to reverse the $meta_title and the include... :oops:

Now on to setting up an array for naming the pages.. :wink:

_________________
Compaq-Fu Master
Ctechinfo funding drive information


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 19 posts ]  Go to page Previous  1, 2

All times are UTC - 8 hours


Who is online

Users browsing this forum: No registered users and 1 guest


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 post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group