Scrivener as a website drafting environment

I would like to build a website entirely offline, and go live only when the core content is fully developed. The primary site would always reside on my local drive. Everything online would be copies. My first thought is that Scrivener would be the ideal place to build the local site. But I’ve never done this before, and would appreciate feedback from those with experience. The local environment would be macOS 10.15, Scrivener 3.1.4, plus whatever site builder is the best fit. Is this something that lots of you are doing, or would I be better of writing entirely within the website tool (e.g., RapidWeaver)? Thanks.

Far from being ideal for this task, Scrivener would be a rather poor choice. There are a great many ways to develop web sites off-line and it’s well worth spending a bit of time researching appropriate tools for your preferred operating system and web server. I have always run an Apache development environment on my home server and created the pages and code using a good text editor, which has been SublimeText (available for all three major platforms) for the last decade or so.

There are of course many WYSIWYG tools for creating web sites for those who prefer to work that way although, not being a user of such, I can’t recommend any. On the other hand, I will caution you not to use a word processor for the task, as their handling of HTML is far less than great and they generally produce invalid code, which may well not be rendered correctly in some, if not all, web browsers.

I’ve “written” websites in perl, php and java. My wife “writes” them in wordpress. Ioa (amberv) writes them in turtle-knows-what with a metric crap ton of css. “website” doesn’t mean much without explaining what you are using to host the website and the technologies involved.

That said, I tend to eclipse because i hate myself. And it will invoke javac/perl/php to render my pages without me doing to much other then crying about the inevitable missed comma in the function call with the most arguments.

Well one nice thing about the Mac is that it comes with Apache, and with only a few easy steps you can get yourself a decent PHP/MySQL testing environment set up as well. You can even just work straight out of the stock “Sites” in your home folder and point your browser to it.

Depending on how important offline is to you though, I’d consider working online. As to what I’ve always done in the past, and for that I didn’t use anything fancy:

  • An FTP client that allows for server-side editing (well, not directly but through auto-upload magic). On the Mac, these days I would use Forklift. It’s a local file manager that doubles as an FTP client with handy sync system—ideal for keeping a local mirror, and a good enough file manager to replace Finder entirely.
  • A coding editor with a decent HTML/PHP language kit. Sublime Text would be my modern choice here. Back in the day I used TextMate, and before that BBEdit.
  • An image editing tool. Anything works, but ideally you want something that can compress images efficiently, which rules out a lot of the cheaper Cocoa-based tools (where they struggle the most is high quality low size JPEG, and hardly any of them support indexed PNG, which for some things will mean the difference between 150kb and 5kb files).

And that’s about it! I would hand code every line of HTML myself (with the help of the coding editor to minimise manual labour). That was mainly before the days of Markdown though—these days I would generate the HTML from .md files and go from there with a hand-coded framework around it.

There was one exception, for a while I used Tinderbox to generate websites. Again most of the HTML was hand-coded, but Tinderbox made a uniquely good interface for generating all of the repetitive stuff like the template around the content for each file.

Were I to adopt a constraint like using Scrivener, I would probably take something like my file splitter workflow and go from there. This way I could establish a multi-file output from the draft folder, and probably even have it manage the .php and .css files as well. It could convert the content files from Markdown, and even organise things into a hierarchical structure for uploading to the server.

I don’t think I would willingly do that though, except as an exercise in proving it could be done. It wouldn’t be any more efficient than a hand-built system and an FTP editor, especially considering the amount of work it would take to turn a program that is primarily a word processing tool designed to output one large file, into something that produces hundreds of semantic HTML files. Markdown would be essential to get around the word processing part, and one can use that workflow without entirely eschewing the formatting tools, you’d just be using them a little differently, not to establish formatting directly, but to use formatting to signify Markdown output. To my mind learning Markdown is easy enough that you might as well just use it directly in Scrivener.

The best option I think would be to do this the way it has always been best done, by slotting Scrivener into a role where it is best suited, and using other tools around it to handle the areas they are best suited for. Scrivener would be where you generate the content files, perhaps even with a simpler file-splitter approach, but everything else is handled using the best tools for each individual component of the job. Even Firefox’s developer tools and a couple of dev extensions can be a huge asset in designing CSS on the fly, if you want something free and capable.

Apparently I’m lazy. My solution for everything these days is to look at something that provides a 805 framework “out of the box” then build the minimal customizations on that. Ex: my wife really wanted me to “run her website” but really, all she wanted was something to display some words and an image to two. By using something like wordpress she focuses on content, not code. And I don’t have to send her a bill that will get me “singled”.

basically, don’t over complicate things if you don’t have to…

I think my main problem is that I am a control freak. I’ve tried to use some framework setups in the past, but found I was spending more time reverse engineering the code to modify how they work, than it would have taken to build a dirt simple “does what I needed and nothing more” framework of my own.

It’s a terribly old fashioned way to work though, I’m not sure I would recommend it, as these days a website isn’t hip unless it has animated buttons and slide out panels and an entirely different interface for phones. Frameworks, even streamlined ones like Wordpress, will often give you all of that, or at least the means to put that kind of stuff together without buying 10 O’Reilly books.

I agree that Scrivener may not be ideal for actually producing your web pages, but it’s great for (e.g.) planning out content, next six weeks of blog posts, etc. which you can copy and paste into your CMS.

Especially if you want to keep content creation and formatting etc. as discrete activities.

This also has that advantage that security is hard, and if you stick to well-known and well-updated plug-ins plus good security tools, you can usually keep current on your site and stay ahead of most issues. Even then, though, where you host it is also a factor. I’m looking at moving my site from Dreamhost to Wordpress just because I’m tired of having somebody partially succeed in trying to hack my site (just enough to break it) and then having to go spend a couple of hours cleaning up the mess, even when using Wordpress with auto-updates, Jetpack, and Wordfence.

Go with Wordpress and Local by Flywheel. https://localbyflywheel.com

Easy to install on Win, Mac, Linux and the standard install includes an import/export plugin.

Painlessly sets up a VM with the install and seems to work with all themes and plugins.