View Full Version : How do I see SSI's on local machine?
wkenny
08-29-2011, 06:26 AM
I am using SSI's for things like nav bar. When I preview a html file on my local machine for testing, it does not include the file to be included. This means I can't accurately test a page without uploading to the server. Is it possible to have these pages show the included file locally?
djr33
08-29-2011, 06:38 AM
No. And yes, in a way.
Server side languages, including SSI, PHP, CGI, and anything else that runs on the server can't just be previewed in a browser from an .html file.
If you need a local preview without uploading to the internet, then you can install a webserver (hopefully with the same configuration as your final distribution location) and then preview it on this local server. This still won't display it just be opening the file in the browser, but by viewing it through the local server in your browser as if you're viewing on a remote page.
Unfortunately due to the way that server side languages work, you need a server-- that's the point. I hope that helps.
Personally I like to preview directly on the final server to be sure it's correct and because once it's working, it's working, and I don't need to change anything. Others prefer to create a local test server for this purpose. It's your choice.
wkenny
08-29-2011, 08:48 AM
Thanks, Daniel. I installed xampp and that does the trick.
local servers are definitely the way to go. with a little study, you can even set up your own domain names for your local sites (I use .dev instead of .com for my "working" sites).
Powered by vBulletin® Version 4.2.2 Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.