Forum Moderators: phranque

Message Too Old, No Replies

Using virtual include for another site (on the same server)

Is it possible?

         

cschults

11:27 pm on Oct 6, 2006 (gmt 0)

10+ Year Member



I have a website (www.example.org) and a blog (sample.example.org), which are both hosted on the same server and I believe are running under the same instance of Apache.

I want to use an Apache SSI (virtual include) on the website that includes content from the blog.

Is this possible? If so, how?

Many thanks in advance.

[edited by: jdMorgan at 1:54 am (utc) on Oct. 8, 2006]
[edit reason] Examplified. [/edit]

jdMorgan

12:54 pm on Oct 9, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



The usual approach is to use a *nix symlink to make the other hosted site's content appear to reside in the filespace of the site you wish to share it with.

Jim

cschults

6:56 pm on Oct 9, 2006 (gmt 0)

10+ Year Member



Thanks Jim! I recently learned about symlinks, but that was within the context of the same site.

Additionally, the website is comprised of static HTML pages while the blog is served dynamically.

Assuming it is still possible to use a symlink, would you be able to provide some sample syntax or point me in the right direction?

Thanks.

jdMorgan

1:21 pm on Oct 10, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



symlinks are built into the operating system. They look and act just like a file or directory, but are actually 'pointers' to files or directories that already exist elswhere. You create them just like you create a 'real' file from the OS command shell. See your OS manual or 'man pages' for more info.

Jim