Click to See Complete Forum and Search --> : [RESOLVED] Install issue


toddpthayer
04-24-2007, 02:40 PM
Good Morning,

I'm restarting programming after 15 years or so. I've downloaded Apache 2.2.4 and php 5.2.1 and successfully (sort of) installed them. I've reinstalled numerous times using different install tips with no success. I'm sure it's a minor in the httpd.conf or php.ini, but I'm having trouble finding it.

I'm having trouble with php embedded in html - the screen is just blank.
I created a file phpinfo().php
<?php phpinfo(); ?>
and it works fine from localhost/phpinfo.php and as a link, but doesn't display when embedded like so in index.htm.
<html>
<body>
<h1>
It works!
</h1>

<?php phpinfo(); ?>

</body>
</html>

I'm sure it's right in front of me, but I'm missing it

Any help is appreciated,

Todd

laserlight
04-24-2007, 03:02 PM
Well, if you followed the instructions given by the PHP Manual, you probably installed PHP such that it works with files that have a .php extension. As such, your .htm files are treated as plain HTML.

You could modify your configuration, but it is probably easier (and more portable) to just use a .php extension instead, e.g. "index.php".

toddpthayer
04-24-2007, 03:11 PM
Thanks,

My background is in database programming - not HTML. I haven't gotten deep enough to know the ramifications of passing .php rather than .htm(l) file type through the system

Todd