October 19th, 2000, 01:36 PM
Win2k server, IIS5, php4
1. I have php script that will show when the page has been last modified. How do I link it on my home page. The link that I am using now does not work. Here is the link:
<? include("updatepage.php"); ?>
2. I have a php forum. When I link it this way <a href="xxxxx/index.php"> it brings up the source code. When I link it this way <a href="xxxxxx/"> it brings up the dir. When I link it this way <a href="http://xxx/xxxxx/index.php"> it works. How do I get it to work with this linking <a href="xxxxxx/index.php">
October 20th, 2000, 09:05 AM
Frankly, for a lastmod date, you'd probably find it much easier to just use:
<?php echo date("l, d F Y: H.i.s", getlastmod()); ?>
Place that at the bottom of the page..
Low Cost Hosting and Web Development.
October 20th, 2000, 10:56 AM
is .php a valid extension for your servers config? that sounds like IIS doesnt know what to do with a .php file and shows it as plain text.
October 20th, 2000, 11:30 AM
<BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">quote:</font><HR>Originally posted by spiggy:
is .php a valid extension for your servers config? that sounds like IIS doesnt know what to do with a .php file and shows it as plain text.[/quote]
I think IIS knows how to handle php because when I give it the full path it works. I followed these steps to in php.
Installation Notes for IIS 4.0 and 5.0
- Install the DLLs as mentioned above.
- If you wish to change any defaults, copy either the php.ini-dist or
php.ini-optimized files into your Windows directory, and rename it to
'php.ini'. You can then modify any of the directives inside it.
- Start the Microsoft Management Console (may appear as
'Internet Services Manager', either in your Windows NT 4.0 Option Pack
branch or the Control Panel->Administrative Tools under Windows 2000).
- Right click on your Web server node (will most probably appear as 'Default
Web Server'), and select 'Properties'.
- If you don't want to perform HTTP Authentication using PHP, you can (and
should) skip this step. Under 'ISAPI Filters', add a new ISAPI filter.
Use 'PHP' as the filter name, and supply a path to the php4isapi.dll that
is included in the distribution.
- Under 'Home Directory', click on the 'Configuration' button. Add a new
entry to the Application Mappings; Use the path the php4isapi.dll as the
Executable, supply .php as the extension, leave 'Method exclusions', blank,
and check the Script engine checkbox.
- Stop IIS completely (you would have to stop the IIS Administration service
for that - stopping it through the Management Console isn't good enough;
You can do it by typing 'net stop iisadmin' on a command prompt).
- Start IIS again (you can do it by typing 'net start w3svc' on a command
- Put a .php file under your Web server's document root and check if it works!
If these is wrong or I missed something, let me know. Thanks