5 ms·
You could use server side includes instead, which have been a feature of web servers for about 20 years now...
by bryanlarsen 13y ago
You could use server side includes instead, which have been a feature of web servers for about 20 years now...
- icebraining 13y agoNot if you host on S3, for example.
- mehulkar 13y agoOr on brace.io (aka Dropbox)
- TheZenPsycho 13y agoA legitimate problem we're solving by… inventing a new templating language. Did we need a new one to do this? Absolutely none of the hundreds of existing languages could have possibly worked, so let's reinvent SSI with different syntax?
- deleted 13y ago[deleted]
- TazeTSchnitzel 13y agoThen just web spider SSI running on a local server. Or someone should write an SSI static site generator.
- oneeyedpigeon 13y agoA fine line, but static pages will be slightly faster than SSI. Edit: Although what would be really nice would be the same kind of pre-processor that works with apache ssi directives
- mantrax2 13y agoThey'll be infinitesimal faster for the server which will sit idle most of the time anyway... and much slower for you when you make a minor header/footer mod locally, and then you need to re-upload all pages that have a header (i.e. all pages). I'm sorry, but this project feels more like "art" than a practical tool. Plus, with a few basic lines of PHP (available on every shared host) you can pre-generate your site statically as well (and on the server, to save you the re-uploading).
- oneeyedpigeon 13y agoPresumably the 're-upload all pages' bit can be automated. As far the reset, the trade-off depends on how often you're updating content versus the amount of traffic coming to your site; in many cases, a tiny saving on frequently-occurring page delivery is well worth a big delay on one-off page generation.
- TheZenPsycho 13y agoSo basically, we've gone down a path of solving problems we've created ourselves.
- nawitus 13y ago>and much slower for you when you make a minor header/footer mod locally, and then you need to re-upload all pages that have a header You should automate that with Grunt or Gulp. Static .html pages is best practise these days instead of dynamic templating.
- eevee 13y agorsync will easily handle a few lines changed in a large number of files. Or you could just, y'know, run the static site generator on the server. What Linux doesn't have Python installed?
- TheZenPsycho 13y agoor you could just, 'y'know, run SSI. what web server doesn't have SSI? What problem are we actually solving here?
- TheZenPsycho 13y agomod_disk_cache and mod_mem_cache make that pretty irrelevant. http://httpd.apache.org/docs/2.2/mod/mod_disk_cache.html http://httpd.apache.org/docs/2.2/mod/mod_disk_cache.html re:edit hxincl uses a similar style as ssi but with a couple of enhancements: http://manpages.ubuntu.com/manpages/trusty/en/man1/hxincl.1.html http://manpages.ubuntu.com/manpages/trusty/en/man1/hxincl.1.... if you want exactly SSI syntax, ain't nuthin' stopping you from pointing curl at localhost.