Domanda

I'm working on a website and am using MAMP built in server for local development. In my site I want to use SSI and am .shtml to do so. I have a testing server which is Apache and the files are going to eventually end up on an IIS server, and I was told doing this type of include will work in both environments. I got to work on the local environment but when I tried to put it on the testing Apache server I get an "SSI error". And the weird thing is if I change it to , it works fine on the testing Apache server but doesn't work on the local environment. I have a very basic understanding of this but am wondering if there is a reason "virtual" works locally but not on testing and "file" works on testing but not local.

È stato utile?

Soluzione

Without seeing an example of the includes, it's difficult to offer suggestions. I'll take a stab in the dark though.

Both the file and virtual attributes depend completely on how the web server in question is configured.

The file path depends on how the filesystem is made available to the relevant web server - try traversing to the file path from the point where it's called on both your 'local' and 'test' web servers.

The virtual path depends on how the document root is mapped to URIs being called against the relevant web server - try requesting the virtual URI path against both your 'local' and 'test' web servers.

These debugging steps should indicate where the configuration differs between the two environments.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top