« Previous Next »

Thread: SSI w/ IIS 5.1 doesn't work - same as chanshuk, that soln doesn't fit

Last post 07-10-2009 5:14 PM by hullspeed. 6 replies.

Average Rating Rate It (5)

RSS

Page 1 of 1 (7 items)

Sort Posts:

  • 07-09-2009, 1:48 PM

    SSI w/ IIS 5.1 doesn't work - same as chanshuk, that soln doesn't fit

    I must be missing something obvious, but I don't know what it is.  'testInclude.html' and 'test.shtml' are in c:/Inetpub/wwwroot.  testInclude (from 'view source') looks like this:

    <html>
    <head>
    <title>Test</title>
    </head>
    <body>
    SSI include directive follows this line. <br />
    <!-- #include file="test.shtml" -->
    <!-- #include virtual="test.shtml" -->
    <br />SSI include directive preceeds this line.
    </body>
    </html>
    Since this is from 'view source', the include directives should not appear but (a) they do and (b) of course the page does not display the included text. 
    'test.shtml' contains a single line of text:
    this text is in 'test.shtml' 
    In the IIS 'control panel' Properties for  all web sites, .shtm and .shtml are mapped to ssinc.dll in 'system32' and it exists.
    what am i missing??? 
  • 07-09-2009, 2:30 PM In reply to

    Re: SSI w/ IIS 5.1 doesn't work - same as chanshuk, that soln doesn't fit

    I must admit I don't really understand what your problem is. What error you are gertting,etc?

    But the include lines are commented out in the html is that your intention?

  • 07-09-2009, 3:58 PM In reply to

    Re: SSI w/ IIS 5.1 doesn't work - same as chanshuk, that soln doesn't fit

     I'm trying to use #include to include the text contained in 'test.shtml' in 'testInclude.html'.  "View Source" (and the rendered page) should look like


    SSI include directive follows this line. <br />
    this text is in 'test.shtml'
    <br />SSI include directive preceeds this line.

     As I read http://msdn.microsoft.com/en-us/library/ms525940.aspx, the #include directive must be in a comment:

    Syntax

    <!-- #include PathType=FileName-->

    More generally (ie, not MS) see for example http://www.htmlgoodies.com/beyond/webmaster/article.php/3473341

     

     

  • 07-10-2009, 10:09 AM In reply to

    • tomkmvp
    • Top 10 Contributor
    • Joined on 03-20-2003, 10:27 AM
    • Central NJ
    • Posts 6,079
    • IIS MVPs

    Re: SSI w/ IIS 5.1 doesn't work - same as chanshuk, that soln doesn't fit

  • 07-10-2009, 12:17 PM In reply to

    Re: SSI w/ IIS 5.1 doesn't work - same as chanshuk, that soln doesn't fit

     I want to insert the contents of a file (test.shtml) into a web page (testInclude.html). 

     

    Sorry about the lack of clarity. From numerous articles on the web, this looked pretty straightforward.

  • 07-10-2009, 4:07 PM In reply to

    • tomkmvp
    • Top 10 Contributor
    • Joined on 03-20-2003, 10:27 AM
    • Central NJ
    • Posts 6,079
    • IIS MVPs

    Re: SSI w/ IIS 5.1 doesn't work - same as chanshuk, that soln doesn't fit

    Right ... but why are you using shtml?

    Shouldn't testInclude.html be testInclude.shtml if you want it be processed as SSI?

  • 07-10-2009, 5:14 PM In reply to

    Re: SSI w/ IIS 5.1 doesn't work - same as chanshuk, that soln doesn't fit

     Aha.  I think i said at the start I thought I was missing the obvious.  Thank you. 

Page 1 of 1 (7 items)