Page 1 of 1
Publish to plain html feature
Posted: Tue Feb 07, 2006 10:20 am
by cino
Hi to all,
great job, really neat environment.
I think it lacks only one "small" feature that would bring cms made simple really ahead of competition:
the ability
to publish to plain HTML, possibly through an ftp connection and with a builtin scheduler to manage news etc...
Just think of: performances, ease of deployment, no-worries production environment, ability to use publishing hosts like windows without php and mysql installed...

Re: Publish to plain html feature
Posted: Tue Feb 07, 2006 5:31 pm
by nils73
Let me get right to the point: At present CMSMS isn't capable of producing static HTML (that is why you posted in feature requests, I know *gg*) but there might be a workaround solution which works almost perfectly. Came across this solution while ripping a website onto CD-ROM ...
1. Install CMSMS with Clean-URLs
2. Style you site and enter content
If you have everything in place and Clean-URLs working, simply do the following:
3. Download
HTTrack Website Copier
4. Run it
5. Enter your URL
6. Let it grab all of your pages
There you go - a static version of your dynamic created page. No code-modifications, all images in place, all CSS grabbed. Now you only need to put it somewhere for example via FTP.
Okay, I must admit it's not like having it built into CMSMS but it doesn't take too long to do this and updating existing copies is easy.
Regards,
Nils
Re: Publish to plain html feature
Posted: Wed Feb 08, 2006 11:59 am
by cino
Thank you Nils,
I didn't know of httrack, in fact I'm already using such a solution, currently I'm using Offline Explorer to download the site on my desktop, then I launch a program that search and replace some urls (css) and then I ftp all into the server.
You know, this way you miss all the features like content management on a per user basis, for example, or a forum integration, etc.
What do you think about it? Does anyone think it could be useful?
Re: Publish to plain html feature
Posted: Wed Feb 08, 2006 1:30 pm
by nils73
cino,
what you are looking for is called "staging" respectively "export to static pages" but dynamic pages will always be dynamic. Only if you close a thread in a forum you will be able to make it static. But I guess that incorporating a staging-feature would mean a complete rewrite of CMSMS if I am not mistaken because it will affect content and modules as well as the whole rendering process.
Could someone out of the development team hand me a torch to bring some light into this?
Regards,
Nils
Re: Publish to plain html feature
Posted: Wed Feb 08, 2006 5:15 pm
by Ted
I'm assuming that anyone who wants to publish to html realizes that the dynamic nature of various modules will go away. Right now is about the best mix of static vs dynamic that I can get, but php is obviously still required.
In reality, exporting to purely static html is not a HUGE deal. The only real issues come from rewriting links and finding a way to export out pure module content (like news details). The rest can be done right through smarty without little work.
But, it's those 2 issues that have kept me from spending time of it. If anyone can figure out how to do that, I can throw in my knowledge on how to the rest....
Re: Publish to plain html feature
Posted: Wed Feb 08, 2006 6:25 pm
by jelle
Do I understand correctly that the OP wants something like:
Code: Select all
#!/bin/bash
#first mirror the stuff to a local dir
wget -m http://yoursite.net >/dev/null 2>&1
#pack and compress the stuff you've fetched and put it out to stdout
tar -cz yoursite.net
#maybe clean up after we're done?
rm -r yoursite.net
#not yet complete as it needs to set the http header to something appropriate
the downside there is that if you don't use mod rewrite or modules that can not use that, you will end up with oddly named files. You can get wget to append .html to the end though (both files and in links).
Other gotchas might be: apache timing out the script before it is finished, wget not available on cheap hosts, no gci allowed, etc etc.
But the point is, do not reinvent the wget wheel.