Forum Moderators: phranque

Message Too Old, No Replies

Could you help me with SSI?

         

Rightz

11:01 am on May 1, 2006 (gmt 0)

10+ Year Member



Hi,
I've been trying to get my head around SSI.

I haven't got a host yet as I am not ready to put my site online but want to make my site easier as I'm putting it together.

I understand I need the <!--#include virtual="menu.html" --> tag in. Am I right in assuming that is the only code I need?

With the menu.html do I simply put the page like so:

<html>etc
<body>
menu code
</body></html>?

Will it literally just take the menu table code?

Also the host I'm looking into says to use SSI i need to change the pages to https. How do I do this... simply save it as such?

One final thing - can I change https pages to show http using htaccess or whatever without it altering how the page works with my host?

I'd really appreciate any advice.

Thanks

coopster

11:14 am on May 1, 2006 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



First, the Apache docs are a must read:

[httpd.apache.org...]

That page along with the included module links, especially mod_include, will become very handy as you setup and understand SSI. Yes, you are correct in that you will simply use SSI to include that piece of code that is common on each of your pages, such as the menu. So, you take the *menu* part of your code out of each site document that currently has it and replace it with your SSI directive --

<!--#include virtual="/menu.html" -->

Of course, you will need to create a new document named 'menu.html' and paste the menu code piece in their. SSI just puts together the pieces of the puzzle.

Oh yes, one more thing. Your host probably said to change the extension, not the protocol. So instead of
https://example.com/mypage.html, they want you to use http://example.com/mypage.shtml

More reading on the extension details here:
[webmasterworld.com...]
[webmasterworld.com...]

Rightz

11:19 am on May 1, 2006 (gmt 0)

10+ Year Member



Brilliant - I'll get reading! Out of curiosity do shtml pages rank the same as http page is SE?

coho75

11:49 am on May 1, 2006 (gmt 0)

10+ Year Member



do shtml pages rank the same as http page is SE

SHTML is a file extension while HTTP is a protocol used for sending a webpage over the Internet.

If your questions was "can dynamic pages rank as well as static pages?", then the answer is yes.

Rightz

12:17 pm on May 1, 2006 (gmt 0)

10+ Year Member



sorry yes i meant html not http in the above question. But thanks