Click to See Complete Forum and Search --> : Server Side Include - syntax for Windows


electricdev
02-21-2010, 07:43 AM
Shtml is enabled on the server and in IIS manager, but my shtml files aren't processing the include files.

What is the correct syntax? Apparently my files are good for Apache.

tracknut
02-21-2010, 09:15 AM
Should be:

<!--#include file="includes/nav.html" -->


Dave

electricdev
02-22-2010, 12:42 AM
Thanks. What is the difference between
<!--#include file="includes/nav.html" --> and
<!--#include virtual="includes/nav.html" -->?

Fang
03-01-2010, 03:04 AM
In your case nothing.
Use file if the document is in the same directory as the calling document and virtual if the document is in another directory.
<!--#include file="/includes/nav.html" --> # not permitted
<!--#include virtual="/includes/nav.html" --> # OK, relative to the root
http://httpd.apache.org/docs/1.3/howto/ssi.html#includingastandardfooter