Comments on: Make WordPress static https://mossiso.com mossiso = more better Fri, 28 Jul 2017 09:50:21 +0000 hourly 1 https://wordpress.org/?v=6.6.1 By: Claudio https://mossiso.com/code/make-wordpress-static/#comment-202968 Fri, 28 Jul 2017 09:50:21 +0000 http://historicalwebber.mossiso.com/?page_id=300#comment-202968 Hi Ammon,
my name is Claudio and I’m the founder of HardyPress (www.hardypress.com),

We just built a platform where you can use your WordPress as usual, but then a staticized version of the site gets published for the rest of the world to see. Something like you explained in your blog post, but automated 🙂

We seamlessly support Contact Form 7, and we take care of scraping your website’s pages and augment the search box to provide instant suggestions so, for most websites, everything will work just fine, even if the site is completely static.

If you want to give a try, I would be happy to hear some feedbacks from you.

]]>
By: Jiju Thomas Mathew https://mossiso.com/code/make-wordpress-static/#comment-173331 Mon, 14 Mar 2016 00:47:09 +0000 http://historicalwebber.mossiso.com/?page_id=300#comment-173331 In reply to ammon.

You can run this on windows, you will need to install cygwin on windows and then this will run

]]>
By: hoppy https://mossiso.com/code/make-wordpress-static/#comment-108977 Tue, 17 Mar 2015 12:22:05 +0000 http://historicalwebber.mossiso.com/?page_id=300#comment-108977 Just for the record, if you are getting 403 errors, add a user-agent to wget at line 218, something like this -U “Mozilla/5.0 (X11; Linux i686; rv:28.0) Gecko/20100101 Firefox/28.0”

]]>
By: ammon https://mossiso.com/code/make-wordpress-static/#comment-12925 Tue, 17 Sep 2013 15:57:59 +0000 http://historicalwebber.mossiso.com/?page_id=300#comment-12925 In reply to john.

You could also run this on your local computer, if that has terminal access. This would put it on your local computer already, and have it browseable from there.

The bare minimum command you need to run is: wget --mirror -P blog-static -nH -np -p -k -E --cut-dirs=5 http: //sitename.com/blog/

This should work with minor adjustments depending on what OS you run on the local computer and which flags or options that version of the wget command has.

Otherwise, there are a couple of plugins out there already:
http://wordpress.org/plugins/static-html-output-plugin/
http://wordpress.org/plugins/really-static/

Hope that helps!

]]>
By: john https://mossiso.com/code/make-wordpress-static/#comment-12905 Mon, 16 Sep 2013 22:52:49 +0000 http://historicalwebber.mossiso.com/?page_id=300#comment-12905 hi

i do not have terminal access, as my site is hosted on a shared host. any way i can do this? or, can you make it a wp plugin?

the output i need would be browsable on my local computer, not hosted on the web. So, no need to disable comments etc. Just need the absolute minimum to make the site browsable offline.

thx!

]]>
By: Permanently Convert WordPress Blogs to Static Pages – tumblilarius lukhnos | IT Lyderis https://mossiso.com/code/make-wordpress-static/#comment-12752 Sun, 18 Aug 2013 21:26:20 +0000 http://historicalwebber.mossiso.com/?page_id=300#comment-12752 […] for this task is Ammon Shepherd’s WPStatic utility. Shepherd wrote extensively about his project (usage, origin, more details). The project has been around for a while, and the version hosted on github […]

]]>
By: Sari https://mossiso.com/code/make-wordpress-static/#comment-12180 Fri, 24 May 2013 00:27:34 +0000 http://historicalwebber.mossiso.com/?page_id=300#comment-12180 Thank you, I find this very helpful. I use local wp copy and now I can burn it to CD.

]]>
By: Kai https://mossiso.com/code/make-wordpress-static/#comment-12096 Wed, 15 May 2013 16:28:15 +0000 http://historicalwebber.mossiso.com/?page_id=300#comment-12096 Hi Ammon,

great script, I think, but I can’t get it to work:
wget: –cut-dirs: Invalid number `-1′.
The script has been chmodded +x and is run with root-privileges in this case.
The line-endings are unix, the shell is bash, run in an Ubuntu 12.04 x64 environment.
The SELECT-Statement in line 92 gives a correct result, which ist resolvable.
The error occurs on line 103, where
home_cdirs=( $(echo $home_url | cut -d’/’ -f4- | awk -F/ ‘{print NF-1}’ ) )
is done.
I changed the cut -d’/’ -f4- to
cut -d’/’ -f3-
which makes the script work.
I think this might be caused by the option_name = ‘home’ , which is set to http://mysite.com instead of http://www.mysite.com.

Anyway, it works, and maybe someone might find my info useful.

Kind regards and thanks

Kai

]]>
By: derry https://mossiso.com/code/make-wordpress-static/#comment-10977 Fri, 01 Feb 2013 21:09:24 +0000 http://historicalwebber.mossiso.com/?page_id=300#comment-10977 In reply to ammon.

Gosh, I so would like to use this script locally on my mac. I was just about to call it quits when I tried something different.
@ marco If you are running xampp like i am you should make a symlink in your root ‘private/tmp’ directory
cd /private/tmp
sudo ln -s /path/to/your/xampp/or/mamp/mysql.sockfile mysql.sock
“my path was /Applications/XAMPP/xamppfiles/var/mysql/mysql.sock” which i found in my my.cnf file in xampp

and like stated in directions open terminal, and cd into the root directory where your wordpress is located and run “./wpstatic [optional flags]”

This will get you pass this error message. However, I recieved this message later:
Run wget now? [y/n]: y
–16:07:30– http://localhost/wordpress/
=> `wordpress-static/index.html’
Resolving localhost… 127.0.0.1
Connecting to localhost[127.0.0.1]:80… connected.
HTTP request sent, awaiting response… 404 Not Found
16:07:30 ERROR 404: Not Found.

FINISHED –16:07:30–
Downloaded: 0 bytes in 0 files
Converted 0 files in 0.00 seconds.

I believe it has something to do with my local wordpress being installed in a sub directory and not the root of the htdocs.

Any thoughts?

]]>
By: ammon https://mossiso.com/code/make-wordpress-static/#comment-9730 Mon, 24 Sep 2012 17:31:14 +0000 http://historicalwebber.mossiso.com/?page_id=300#comment-9730 In reply to Marco.

Most likely you have something wrong with your MySQL connection or server. Maybe MySQL isn’t running. Only thing I can suggest is to do a google search and see what you come up with.

]]>