Goodreads widget follow-up

And just a few minutes after my last post, I’ve figured it out: The Goodreads widget wasn’t working, because I had Privacy Badger enabled in my browser. Well, that answers a lot of questions.

And now that I can see what the Jetpack Goodreads widget does, I see that it is likely just a wrapper around the HTML/JS widget that I could have added directly in a code block. I’m going to leave it on the page for now, but I might drop it later.

Sigh. Well, back to that whole iced coffee idea. And lunch. Yeah, lunch sounds good.

WordPress widgets — On This Day and Goodreads

After updating to WordPress 4.6.1 recently, I also updated all my plugins, and decided to spend some time messing around with the site a bit.

First, I found that updating the On This Day plugin broke something; it started showing a PHP error. After looking at the code a bit, I figured out that just changing something in the widget config would fix the problem. If I was more ambitious, I would actually go ahead and see if I could fix the error in the PHP code, and maybe even see if I could get the original author to merge it in. But I don’t have the energy for that right now. We’re in the middle of a late summer heat wave, and I’m not up for PHP debugging right now. Maybe next week.

After messing with that a bit, I noticed that Jetpack had added a Goodreads widget recently. I like the idea of showing what I’m currently reading in the sidebar, so I added and configured it, but couldn’t get it to display anything. This is possibly because I have my Goodreads profile set to private. (Or at least partially private.)

I’d previously messed around with adding a Goodreads widget, using a general-purpose RSS widget, but (for some reason) had never added it to my live site. Looking back at that, I see that there’s a key associated with the RSS feed URL, so that’s probably the issue with the Jetpack widget; it doesn’t have the key (or anyplace to enter it in the widget config). And looking at the RSS widget that I’d experimented with previously, I see that I’d have to expose the key on my site to use that one. So I guess I should leave my “currently reading” list off this site, since I’m not sure what else somebody could do with that key.

Goodreads also has a customizable HTML/JavaScript widget that I could use, and which probably works with private profiles (without exposing the key), but I’m not sure I want to add that right now, since I don’t want to go down the road of starting to add miscellaneous JavaScript widgets all over my home page. (Been there; done that.) So if you want to know what I’m reading, you’ll have to add me as a friend on Goodreads, I guess.

After some spelunking into the Goodreads account settings, I’m a bit confused about all this though. I’m not entirely sure which stuff in Goodreads is public and which is private, and I’m pretty sure the “currently reading” list isn’t private. So I really think this is a rabbit hole I shouldn’t have gone down at all.

The weather app on my phone says it’s 86 degrees out, and feels like 96, so I should really stop messing around on the computer and go get an iced coffee or something.

Fifteen years

I just noticed my 10 year post in the “on this day” sidebar. And my first post. So it looks like this blog is fifteen years old today! Weird.

I’m not really in a “reminisce about the last five years” mood right now, so I’ll just leave this here as a marker. I wonder if I’ll still be maintaining this blog in five years, at the twenty-year mark?

switching to SSL

I got a notice recently saying that the SSL certificate for this site would be renewing soon. That reminded me that it was about a year ago that I bought the cert and set things up so my login and admin were under SSL. That’s been working fine, and I decided today to switch the whole site to SSL. There’s nothing on this site that’s really important enough to require SSL, but I wanted to do it as an experiment, if for no other reason.

I did this simply by switching the site URL in WordPress from http to https. This doesn’t force everything to SSL, but it does make all the internal site links go through SSL. If I want to force SSL, I think I can do that with .htaccess / mod_rewrite, or with a WordPress plugin. But it’s fine for now.

I’m using a cert purchased from my host, 1&1. Their prices aren’t bad, but I probably should have switched to a free cert from Let’s Encrypt. Maybe next year.

removing Google AdSense

I put a Google AdSense ad block on my site way back in 2010. Looking at it again in 2012, I’d gotten up to about $3 in earnings. Right now, it stands at about $15 total. So I’m still nowhere near the amount you need to reach before Google will actually pay you out, which I think is still $100. (Though I’ve read that if you close out your account, and you’re over $10, they’ll mail you a check. But I’m not sure about that.) And lately I’ve been seeing some pretty sleazy ads in my little ad block, so I think it’s time to get rid of it. So, yesterday, I removed it.

I’m using a combination of Adblock Plus and Privacy Badger myself, so I don’t even see most ads on the web. (Though I have whitelisted a bunch of sites, and ABP lets certain “acceptable” ads through by default.) My goal with this blog was never to make money. And I really only did AdSense as an experiment to learn about it. (At this point, I’ve clearly learned that I can’t make any money with AdSense. So, goal achieved!)

WordPress backup

Not long after I first moved this blog to WordPress, I installed the UpdraftPlus plugin for site backups. I’ve been using the free version for the last couple of years, and it works fine. I have it configured to simply back up to local storage on my web host, and I hadn’t really thought about it much since I set it up. But of course backing up files to the same place that’s hosting them isn’t a great system. It’ll protect me against some possible issues, but it won’t be much help if something happens with my web host and I lose access to my account, or if someone breaks in to my account and deletes or scrambles all my files.

UpdraftPlus supports copying its backup files to DropBox, Google Drive, or several other possible offsite destinations. I don’t know why I’d never set this up, but I decided that it was past time I did that, so I started messing around. I found that the DropBox support was easy to set up, but just didn’t work for me. It would partially copy the backup to DropBox, then it would get stuck and never finish. This has got to be some kind of configuration issue on my host; Updraft is a pretty mature plugin and it gets updated frequently, so if there was some general issue with Updraft’s DropBox support, they would have fixed it.

I didn’t want to spend a lot of time trying to figure out the DropBox issue, so I thought I’d just try Google Drive instead. The Google Drive support requires getting an API key from Google. Updraft’s documentation has a good write-up on how to do that, but Google has changed their interface for doing that, so the write-up didn’t quite match the interface. I probably could have stumbled my way through it, but I decided to punt on that too, since there was a good chance that whatever issue was causing the DropBox backup to be so slow would affect Google Drive too.

So I went looking for another alternative. Updraft supports several other services, including OneDrive, which would have been my preferred alternative anyway. But OneDrive support isn’t included in the free version, and I didn’t want to pay for it, only to find out that it had the same problem as DropBox.

In the end, I decided to continue letting Updraft back up only to local storage, and then copy the backups to my Mac with a script that I could run locally. After flailing around a bit with a few options, I settled on using rsync. I’ve always connected to my web host with SSH, and rsync uses SSH to connect, so that worked fine.

One other related thing that I had never gotten around to setting up is key-based auth for SSH. I’d simply been connecting to my host with my user name and password. And, embarrassingly, I’d actually had a pretty simple password on my account until recently. I set a more complex password recently, so getting the public/private key auth working was something I really needed to do too. Well, it turns out that wasn’t nearly as complicated as I (for some reason) thought it would be. I just had to generate a key on my Mac, and then copy it into an authorized_keys file on my host.

I have Updraft configured to send me an email every time it finishes a backup. (I do weekly backups.) So now, every time I get that email, I just need to run a shell script that runs rsync and copies the backup down to my Mac. Easy enough. A fully-automated solution would be better, and maybe someday I’ll talk myself into paying for UpdraftVault or VaultPress, but I should be fine for now.

more WordPress updates

After updating my 1&1 environment from PHP 5.4 to 5.6 this morning, I decided to check for WordPress plugin & theme updates tonight. I had a few plugin updates, plus a surprise theme update. The base theme for this site is Stargazer, from Justin Tadlock. There hasn’t been an update to it for a while. (Which is fine; it’s quite stable and I haven’t had any problems with it.) But I see he released version 2.0 recently, so I went ahead and updated it. As far as I can tell, nothing is broken. Theme updates can sometimes be tricky, especially if you’re updating the base theme for a child theme that you’ve hacked together yourself. But everything looks OK, so far.

I’m way too tired to look into what’s been changed in Stargazer 2.0, but hopefully I can check on that at some point. I haven’t done anything at all with this site’s theme lately, so maybe it’s time to mess around with it a bit!

PHP 5.6

I got an email from 1&1 this morning, telling me that if I didn’t switch from PHP 5.4 to PHP 5.6, I’d be subject to a $7.19 monthly “extended support” charge for using an old version of PHP. Fair enough, I suppose, though I didn’t even realize I was still on PHP 5.4.

I remember at some point in the past either updating it, or trying to update it and failing, but that was probably a long time ago. Maybe that was from 5.2 to 5.4 or something like that.

Either way, this site should now be on PHP 5.6. This post is basically just a test to see if the site still works. I don’t think I have any WordPress plugins that won’t work under 5.6, but I guess I’ll find out soon.

Blogging tools

I played around with the WordPress.com app for Mac a couple of weeks ago. I used it to write a few recent blog posts, but I’ve mostly gone back to just using the regular WordPress admin. The app is nice, but it’s not really that much better than the regular admin pages.

The WordPress.com app is now also available for Windows. I’ll probably install it on my ThinkPad at some point and give it a try. And, interestly, Windows Live Writer has (finally) been open-sourced and released as Open Live Writer. Windows Live Writer had a really good reputation as a great tool for authoring blog posts, and I know at least one guy who used it with WordPress and liked it. Microsoft pretty much abandoned it in 2012, and there’s been talk about open-sourcing it for quite some time. It’s great that they’ve managed to do it. I know it’s not easy with software like this that comes out of a large company.