Nikodemz Posted November 2, 2006 Share Posted November 2, 2006 I'll preface this by saying I'm no coder. I'm a systems admin who's been charged with getting a website to work properly and I'm learning the ins and outs of configuring PHP as I go. This may be a server config problem or a code problem so I thought I'd start by posting here. Current config of server: (things are generally working just fine)PHP 5IIS 6.0Windows Server 2003PHP seems to be parsing .php files perfectly so I think the basic configuration of the server is setup correctly. The problem I'm running into involves parsing an .html page. The following code preceeds the header of index page of this particular website.<?php// include the header file which sets up all the connections etc needed for// each page.include_once('includes/header.php');// get the front page info and put it into an array$res = $db-query( 'SELECT * FROM frontpage' );$fp = array();while ( $row = mysql_fetch_array( $res ) ) { $fp[$row['section']] = nl2br( $row['content'] );}?>When I few the source of the page from a browser this code shows up, indicating that it hasn't been executed. That makes sense since by default I don't have PHP parsing .html pages. However, when I change that and make it so PHP does parse .html pages I get a blank page. I've created a test .html page that includes a one line PHP script that simply echos some text back. That page works just fine. So I have to assume that PHP is parsing .html pages correctly.Is there something that this code is doing that requires additional tweaking of my php.ini? That's about all I can think of at this point. Unfortunately, I'm a novice when it comes to coding so I really can't tell what this snippet of code is trying to.My hope is that I've supplied enough information for someone to at least point me in the right direction. I can certianly supply more information if necessary. Thanks in advance for any assistance. Quote Link to comment https://forums.phpfreaks.com/topic/25978-php-parsing-html-pages-problem/ Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.