So several people have been bugging me for a while about signing up for Dropbox.

I know they’re mostly just doing it for the 250 MB referral credit, but up until now I’ve never really had much desire to use a service like that. I guess I’m kinda stuck in my ways as far as carrying a flash drive around with all of my documents on it, plus I’m not too crazy about installing the client on all of the various PCs that I use just because I don’t necessarily want 2 GB of my personal files sitting on all of them. That said, yesterday I bit the bullet and signed up because I finally found a way to make Dropbox useful to me – I’m able to use it to automate backups of all of my WordPress sites.

It was an idea that came to me on a whim – I was pondering how I still haven’t bothered to establish a reliable backup procedure for most of my stuff, and to some extent all of my websites needed to be included in that, even though technically my host is supposed to be making regular backups as well. Pretty much just at random, I searched the WordPress plugin repository for the word “backup” and there in the listings, I found this little plugin called WordPress Backup to Dropbox and decided to give it a try. It ended up being super simple to use, and in less time than it took to actually register my Dropbox account, the plugin was installed, authenticated with Dropbox, and had already started pushing files out the door to backup!

I spent the rest of yesterday watching these things update in the background, and as soon as one site had completed, I’d install the plugin on another and keep going. By the end of the day, I had eaten up about 25% of the disk space on my free account, but already the biggest of my sites had been safely backed up … including My Time with the Mouse… and its massive, 2000-image photo galleries! … and what’s especially cool about this plugin is that it even runs a SQL export of the database and then backs that up, too! A WordPress backup isn’t really much good if the actual data isn’t copied alongside the actual theme files, so I was pretty impressed to find that this plugin managed to do it all in one fell swoop.

One of these days I’m going to sit down and put together a list of all of the plugins that are kind of standard for me when I setup a new WordPress site, and I can tell you already that this plugin is definitely going in that list! Though Dropbox may not necessarily guarantee that your data will be there (it is a free service), backups are all about redundancy and at least this gives me one additional layer of protection to the host-level backups that I already had. Eventually I do also want to set something up to download weekly backups to one of my local machines here as well, but in the meantime leveraging Dropbox as an off-site backup solution works, too. :mrgreen:

Just the other day, another one of these crackpot, opt-out web services aimed at innovating the future came across my radar. Like pretty much all of them, it was brought to my attention by a deluge of upset people on Twitter who never actually signed up for the service in the first place…

The concept of this one seems a little too weird and artsy for me to really be interested in – the idea is that you trade your time for time talking to other people … the tricky part being that while the no-name film director might very well want to chat with someone more successful, there in turn needs to be someone else who the more successful guy would also want to talk to, otherwise it seems like they’d just end up with a pyramid where lots of people on the bottom are left wanting to talk to a relatively few number of people at the top…who I’m not sure why they would want to use the service anyways.

And yeah, maybe there’s some potential for cross-genre blending and whatnot, but the concept itself isn’t really even what I wanted to talk about here today…

The problem is actually that instead of only letting its users trade time with other users who had already signed up for the service, AllThis also took it upon themselves to create “non-member profiles” for people when they were found to be not a member by an existing user. Kind of like how when you plug-in your email account to Facebook to allow them to search your address book for friends to add, then offering the option to “invite via e-mail” people who aren’t yet Facebook members … except in this case, AllThis just went ahead and created a profile for them anyways as a way of hinting that there was already a demand for their time on this new site that they weren’t a part of yet.

Like clockwork, a lot of people got mad because as a general rule, people don’t like getting signed up for things without their consent! Consider spammy e-mail lists when you place an order from a website – all you wanted to do was order their product, and as a gentle thanks, they proceed to bombard your e-mail account with promotional offers that you never asked for in the first place. It’s the reason why I’ll never, ever go on a Princess Cruise – because after being signed up for some Carnival Cruise Line promotions that I also didn’t ask for, they went and shared my address with all of their sister brands and now for the life of me I can’t seem to get them to stop sending me cruise promotions for this line that I’ve never even had the slightest interest in buying from!

But as far as web services like AllThis are concerned, I think the main problem is that they see somebody like Facebook or Twitter who already have hundreds of millions of users and with the idea of starting from the ground up being so daunting beside those numbers, the gears start to turn with ways that new companies can leverage the existing user bases of these much larger, completely opt-in successes.

AllThis certainly isn’t the first and they won’t be the last, either – before them, we saw TwitShirt, a company that saw potential in creating on-demand shirts of any tweet in the Twitter stream, despite the small detail that copyright over individual tweets is retained by each individual user. Not too long ago we were introduced to Kachingle, a micro-payment service which offered to accept donations from readers for their favorite websites before actually soliciting those website owners for permission to do so! The ideas were fine all by themselves, but nobody has the patience to wait several years for their user base to grow organically these days, so they try to cut corners like this and end up doing more harm to themselves than good.

Frankly, I think it takes an awful lot of nerve to spend all of this time creating a new project, then only to design its business plan around the assumption that everyone will just naturally want to be associated with your craft genius. It’s a great goal to be loved by everyone, but in the meantime you’ve got to work for it and luckily these days the Internet provides plenty of resources for folks to voice their concerns about you if they think that you’ve overstepped your bounds with your latest and greatest venture.

Whether they’re scared because they don’t actually think that their service could hold its own to build growth organically, or even if they’re truly just inexcusably naive to the idea that the entire world might not think that their idea is as great as they think it is, either way it amuses me that the proven track record itself of opt-out technologies that people actually enjoy alone isn’t enough of a deterrent for them to take a step back and launch their products the right way.

The web isn’t built on tricking users into trying out your service – you still actually have to sell them on it the old-fashioned way, and at that point if it’s not cool enough to actually persuade people on its own merit, then maybe that should be a sign that could save you 6-12 months of your life and several million dollars in venture capital before pissing off the very people who you’re hoping will become the passionate users who will make or break your latest vision.

So if there’s one thing moving my blog from LiveJournal over to WordPress has reminded me, it’s just how much I absolutely, positively love WordPress!

This is something that I’ve been planning to do on and off for quite a while now, although it kept slipping off the radar due to other priorities.  Well, last weekend for whatever reason I was feeling particularly unmotivated with whatever I was supposed to be working on, so instead I decided to start digging into this new little project.  I found a theme that I liked … well, technically a couple of them that I ended up mashing together to get what you see here today … and after a few hours of hammering away at the initial theme setup, the question came – just how ugly was importing all of my posts from LJ actually going to be???

I was ready for the absolute worst (i.e. copying and pasting them one by one into new posts ad nauseam), but instead it turns out I was both lucky and happy to find that not only does a script already exist to pull in content directly using LJ’s API, it even already has hooks built into the WordPress core!  It was literally a 5-minute job – click to install the actual plugin to do the heavy lifting, enter my username and password, and then wait while it churned through some 2,000 blog posts spanning the last eight years of my life!

The only problem that’s still outstanding is for some reason the importer isn’t pulling the comments down after it finishes with the posts themselves – instead, it just says that I don’t have any comments and then finishes, whereas apparently I have about 800 comments!  So I still need to keep an eye on that – I already found where a WordPress.com user is reporting the same problem recently, so hopefully they’ll fix it sooner than later and we’ll officially be in business.

In the meantime, next steps are to finish polishing up the interface a little more, although so far I’m already very happy with the aesthetics, then for the blog side of things I do actually still have to go through each and every post manually – both because I want to refine my tags and also need to tag a good 80% of the older posts before I started using them, and also to address a few small issues where Flash videos, etc… didn’t actually get embedded like they should’ve.

So mostly small stuff, but still time consuming – once I can get everything sorted out so I know what all to look for, I’ll just pick 50 or so a night and slowly start pouring through them until they’re all done.  In the end, I do think that it’s going to make for a better site, and besides, being the nostalgic doof that I am, I never really mind pouring back through old posts that I wrote years ago all that much anyways… :)

So in summary, thus far probably my easiest redesign I’ve done in a long while!  I still have one more that’s on the docket to knock out later on this month before Thanksgiving, and I can only hope that it goes as smoothly as this one did.

So today’s big project was something that ended up taking a whole lot longer than I had expected, but at least I can say that I’m definitely happy with the results. Up until the latest one, I’ve been using Flickr to host the photos for the write-ups that I occasionally do for our Wednesday night LFR games, however I actually hit the photo cap for free accounts (200 photos) a while ago and in the meantime have just accepted the fact that as I added newer posts, the photo sets from the older ones were disappearing. I wasn’t crazy about the idea, and I almost considered just paying the $18 for a while to side-step the issue, but ultimately I knew that eventually one day I needed to suck it up and migrate all of the galleries back to my own server because a) it’s silly to pay Flickr when I already have a monthly hosting bill anyways, and b) hosting them myself allows me to do a lot of cool things that I simply can’t do via another service.

Anyways, several nights of uploading photos, updating posts, and tweaking code later, everything has been moved over and seems to be running smoothly. I’m using the NextGEN Gallery plugin for WordPress – the same one that I’m using for the other big project I’ve been randomly musing about – and all in all I think I’m really starting to like it as a photo gallery for WordPress sites. My one beef is that it doesn’t handle comments on a photo by photo basis, which is more of an issue for the other site than this one, but in the same vein I’ve already spent years struggling with Gallery2 and even though it’s technically a more robust gallery system, integration with other sites is just atrocious and I don’t think I’ve ever come across a site using it in a way other than the regular, blocky templates that come stock with it.

In fact, I’m currently running Gallery2 for the photos on scottandsara.info and I’ll probably end up moving those into NextGEN eventually too because it just seems too clunky for what it does these days…

That said, here’s the final product for the D&D site:


I’ll do a separate post here in a little bit about the technical hurdles that I faced with this one because there is some customization taking place under the NextGEN hood, but overall I really like how it allows me to highlight the photos from my LFR Adventure Logs because there are times when I think I enjoy going back and just flipping through the pictures more than reading the actual posts! Bottom line is, after over 300 photos across 24 separate games, it was time for something a little fancier than Flickr sets and I think NextGEN does the job nicely, if I do say so myself! :)

If I would’ve had any idea that the project I’m working on would be this intensive … I still would’ve started it anyways, but boy, am I sure going to be happy when it’s finally done!

I know I’ve been a little hush-hush about it, although I think I’ve dropped enough clues here and there that you could probably stumble upon it if you really wanted to. I just don’t want to officially point people to the site until it’s completely 100% done, and for what it’s worth so far I am extremely happy with the way that it’s been turning out. It really isn’t as much of a blog as a whole network of different types of content to highlight my passion for the thing, and even though it’s unfortunate not to mention quite tedious to think that I’m a month and a half behind schedule and it’s still going to be one hell of a push to get done by August 1st, it’s exactly what I’ve wanted this new site to be since I first started brainstorming concepts back in 2008.

Maybe even 2007???

Wow – I just checked my notes back to some early renditions of articles that won’t be appearing on the new site and it was indeed 2007 when I made my first attempts at crafting this new project, albeit at the time if I recall it was going to be simply a new feature incorporated into my main site whereas now it’s basically a stand-alone project all by itself. It’s going to be some work to keep the content up to date – basically doubling the amount of writing I do for The Humor Column each month, but it’s a fun topic and from what I’ve already written to date I think it should flow pretty naturally because it’s a little different writing style than what I currently use for my other projects.

So anyways, the original theme of this post was intended to be about designing because I basically spent the majority of my weekend figuring out a couple of minor, but not insignificant design issues. I’ve definitely learned a lot about WordPress and PHP in general throughout the course of this project, and I’ve been trying to share my experiences for the greater good as I’m able to work through them. It’s truly been a great example of “Don’t let code limit your design – decide what you want and then figure out how to make it happen…” and I really hope that the final product shows it. I really wanted to create something unique that every other blog isn’t already doing, and I think I’m on the right track.

Now whether anyone else will actually want to visit this unique site once it’s completed, that’s another story altogether … but in the end, all I can do is create something that I enjoy and hope that others like it, too, so all joking aside, we’ll see what happens!

Anyways, hopefully by this time next month I’ll finally be posting a little blurb here directing everyone to come check out the new site and it’ll be a smashing success, but between now and then I’ve still got a lot of work left to do to get there. So many late nights, long weekends, and time secluded away from the wife hunched over a keyboard – all I can hope is that at the end of the day it’ll all have been worth the sacrifice.

Until then, I guess here’s one more clue for the curious, little monkeys in the crowd…

Conquering Regular Expressions

May 23, 2011 11:08pm
Tagged with:

So in between battling puppy pee, I’ve also been fighting with regular expressions for the better part of the evening. To summarize, I hate regular expressions. I just don’t get the logic, never have, and just when I think something makes sense, I’m told that I forgot like eight different escape characters or special circumstances or whatever and I feel like I’m back at square one.

With that said, after my last geeky code post of this nature, I decided that I want to get in the habit that when I fight with something long enough, I at least post about it online, both to vent and also to share in case someone else encounters something similar in the future!

Anyways, the scenario is this – working in PHP with WordPress, writing a custom category template for a new site I’ve been building. In this case, I needed to be able to pull the first image tag out of a post so that essentially I could create a category view that simply showed POST TITLE/DATE/ETC, IMAGE, MORE LINK TO VIEW ENTIRE POST.

Quickly, the caveats:

  1. I know that there are plug-ins to do this, however using code directly in the template is far more efficient because this will really only affect a fraction of the posts.
  2. Those plug-ins basically just parse out the tags, which won’t work for me anyways because I’m using NextGen Gallery for my images, meaning that the syntax stored in post is a shortcode like this – [singlepic id=123 w=550 h=413 float=center].

I fought with regular expressions for hours upon hours, but finally managed to come up with this:

(searching for this tag)
[singlepic id=123 w=550 h=413 float=center]

preg_match_all ('/(^\\[.*?\\])/is', get_the_content(), $matches);
$image = $matches[0]; $image = $image[0];
echo do_shortcode($image);

Basically it just looks for a tag in brackets at the very beginning of the post, which is my default format, however also meaning that it won’t get caught on anything if for whatever reason I end up using additional tags later on in the post. The first function does the actual search through the post content and throws the results into an array ($matches), with the second line extracting the tag out to a single variable and the final line executing it as a WordPress shortcode.

I’m still not entirely sure why I have to do line #2 twice – I guess between the preg_match_all() function and the data, it ends up as an array within an array, but after literally four hours of staring at this stupid thing, what you see above is officially the point where I said, “It works – good enough!”

WordPress Bug Talk

May 9, 2011 6:48pm
Tagged with:

I know that this one is going to get a little more technical than most, but after battling with WordPress over something that in retrospect just seems incredibly inane, I feel the need to pronounce my victory in a public forum such as this…

So on one of the sites that I’m currently revamping (and hoping to officially launch in May), I’m doing a lot with photo galleries embedded in pages … probably not using pages exactly the way that was intended, but it seems to get the job done so I’m not going to complain. Anyways, the trouble started when I wanted to introduce a related posts plugin that also accommodates pages – the plugin technically works great, however one tiny detail in the format that I wanted for the output really just managed to throw me for a loop.

Basically, despite my pages being nested – sometimes several levels deep – in the related posts output, I always wanted to see the top-level mentioned instead of a page’s immediate parent. For example:

Photo Galleries —> Food —> Watermelon

becomes

  • (Photo Galleries) Watermelon

not

  • (Food) Watermelon

So the trick here is that you can’t simply look to a page’s parent, you need to loop through all of its parents’ parents until you get back to the top. The good news is, there’s actually a function already in WordPress to do exactly this. The bad news is, it’s broken!

I discovered this the hard way after feeling triumphant one night about solving my problem, then getting up the next day to find that it was only sometimes working. Most of the time I would get the correct “grandparent,” but for one page in particular I got back a null value instead, despite seeing the hierarchy plain as day through the main admin interface. From there I tore apart the database tables looking for an incorrectly populated relationship, started from scratch with the function itself, and even tried deleting and rebuilding the page, thinking that it might be a problem from when the page was originally generated.

Nothing, until another day at random I happened across this page

Apparently it’s a caching problem that was found almost two years ago, however obviously being not a very high priority just never got addressed. Fortunately in my case, though, a workable fix was found at the end of that thread – the basic solution was to run a function to clear that specific post out of the cache. Admittedly not knowing a ton about how WordPress’ cache works and not wanting to break something by constantly clearing the cache for every single post and page, I ended up doing something like this…

if ($post->post_parent)	{
   if (!get_post_ancestors($post->ID)) { wp_cache_delete($post->ID, 'posts'); }
   $ancestors=get_post_ancestors($post->ID);
   ... }

At least this way the deletion only runs if the ancestry is already broken for a particular page. This is definitely the first time that I’ve ever had to dig this deep to root out a problem in WordPress … usually it’s a problem with my coding, not theirs! So anyways, that’s my story and all is now well in the universe – just had to share in case someone else one day stumbles across that same problem with get_post_ancestors() and they still haven’t fixed the bug yet…

Happy coding!

Sometimes I think that there should be a rule about registering domain names if you’re not actually going to use them.

I don’t know how it would be enforced or what the criteria would even be, but it’s really, really frustrating to have four or five ideas for a new project, only to find that most of the prime domain names have already been scooped up and are currently parked with advertising and offers to resell for an inflated price.

I mean, I’d be fine if I pulled up the name and there was a site already made doing the same thing as my idea – sure, it’s a little disappointing because somebody beat me to the punch, but to find somebody who’s just sitting on the name because it’s catchy and can bring in a few bucks a month in keyword search advertising – that really bugs me because I feel like it’s a waste of space on the internet, so to speak.

Of course, the problem is there’d really be no way to actually prove intent – if you required a “website” within a certain amount of time after registering, you’d see template sites just like you see now with the “What you want, when you want it!” garbage that poses for parked domain sites nowadays anyways – there’s no real way to enforce making a decent website to justify owning a particular domain name. We’ve got enough of those cookie-cutter, syndicated content sites clogging up the tubes these days anyways – I have a feeling that trying to put the crunch down on parked domains would just exacerabate the problem ten-fold.

I guess the sad thing is, the only real way for a guy like me to combat this problem is to think ahead and do the exact same thing myself so that I can hold onto the names before someone else gets a chance to! Which sucks for this particular idea that I had because a) I don’t ever know if it’ll even come to fruition or be worth persuing a year down the road when I’d likely have time to start working on it, and b) it’s an idea that would fit into a larger scope, meaning that I’d likely want to register a handful of similar names all at once to ensure that they all fit into the same naming convention … which could get expensive at 6-12 names @ $9.95 each.

It’s either that or just wait it out and potentially consider settling for subpar names, but seeing as I’ve already done that a couple of times and ended up missing out on names that seemed innocent enough at the time but later got scooped up anyways, maybe it’s better to just squat now and then if things don’t work out, drop them in a year or two for someone else to immediately grab and put ads on themselves… :(

As I’m getting ready to do a redesign of my main personal site, one of the questions that I keep coming back to is whether or not it’s finally time to just wave goodbye to LiveJournal and migrate everything over to something that I would host myself. This used to be something that I was really passionate against because I’ve been using LJ since 2003 and have accumulated nearly 1,700 posts here, but the more I go back and review the reasons that I didn’t want to leave, the less weight they’re all starting to have…

It’s where all of my friends blog!
Well, hardly any of those people actually use LJ anymore! The people that do still blog are either self-hosted or using another platform, and several have just thrown in the towel altogether and just post updates to Facebook these days. My Friends List, and even Friends of Friends List, are pretty much both just filled with RSS syndication of comics nowadays – I rarely ever see actual blog posts in there anymore.

LiveJournal Icons are cool!
While I still can’t necessarily deny this, I do think that I know enough about WordPress now to just mimic the feature there … that is, if there isn’t already a plugin available for it. I also used to argue that icons made my friends list more colorful to read, but if nobody else is posting…

I like the app that I use to post my updates.
I’ve been using a program called Semagic for a number of years that’s really easy to use and offers pretty dropdowns for all of the LJ-specific features (icon, mood, music, etc…), however the downside of this is that it’s actually a pain to post when I don’t have access to the application. Like for this actual post, for instance – I’m actually writing it in Word, but when I paste it into Semagic to post later, the formatting will look really ugly because of how Microsoft bloats its HTML output … I usually end up posting as plain text and then re-adding all of the formatting manually anyways.

Although I believe that Semagic can actually post into WordPress, too, I also have the option to post via the regular interface wherever I have web access OR I can paste via Word without formatting issues … this is already verified because that’s exactly how I do my humor columns each and every week.

Migrating everything is going to be a pain in the ass, and I’ve already paid for another year…
True, 1,700 posts is going to be a pain, especially considering that whatever import tool that I use likely won’t preserve all of the tags and formats as clearly as I would like, but on the other hand … you’ve got to start somewhere, right?!

I guess in looking over the nitty-gritty, I basically just convinced myself that it’s finally time … at least to say that I’m going to do it, anyways. Sure, it’s only $20 a year for a paid account with LJ and there’s really no reason why I couldn’t just go free, but the more I look at it the benefits are really dwindling these days … namely, nobody else uses LJ anymore and everyone I do follow I now use RSS for. Plus, I’m kind of making it a point to dump old online stuff that I don’t really need anymore this year, anyways. Already I’ve let a few domain names expire for projects years old that just never came to fruition, and although I never paid for Flickr, I’m still debating whether I want to get a pro account with them or use my own hosting account for photos as well.

Again, the money isn’t really a big deal, but a) like the placeholder domain names, it’s dumb to keep paying for something that I don’t need; and b) I already have a monthly bill for webhosting, so to some extent it does seem a little silly to pay an extra fee for another service that I could host myself … unless it offers some amazing features that open source software doesn’t currently replicate (arguably, this is my debate with Flickr right now…).

My requirements are pretty simple for this blog – I don’t even know if anybody else reads it because I’ve always looked at it more just as something for me to look back at reminiscently from time to time, so if we’re finally to the point where it makes more sense for me to just host a simple WordPress blog for it myself, maybe that’s finally ok. Besides, maybe that will put it in a better position to actually get read by more random people, and a few cents here and there from Adsense never hurts. I’ve already proven this year that even though something may seem stupid to me, that doesn’t mean other people won’t be interested in it nonetheless!

Anyways, I’m sure I won’t stop posting here for a while, but I suppose it’s something for me to start playing around with when the redesign for scottsevener.com gets underway. My original plan was just to keep it a portal pointing to all of my other sites, but I was planning on using WordPress as the framework, so including a blog in the mix shouldn’t be much trouble on that part. I’m not really concerned about the design, but the 1,700-post import could get a little ugly! Then again, maybe it’d be a good task to do 6 months at a time – that way, I can go back and tag all of those really old posts at the same time, too!

We’ll see whether I still renew my paid account here in Sept. 2011 whether this plan actually worked out or not…

An Evolution of Web Design

October 31, 2010 9:42pm
Tagged with:

Sometimes it’s interesting to look back at the various websites that I’ve built over the years, to compare notes, to see how I’ve improved, and even sometimes just for a little bit of that embarrassing nostalgic cringe…

Even after finishing the rebuild for pumpkin tonight, and my D&D site earlier this summer, I still have a couple of other redesigns that I’d like to tackle this year – maybe I’m just in the mood, or I feel guilty that they’ve gone this long, or even simply that I feel like I’ve finally got the technical know-how to at least somewhat do them justice!

And granted, I owe the vast majority of that success to WordPress – I know that the last two sites turned out as well as they did because in both cases I could take advantage of existing WordPress themes and just modify them to fit my needs. Mind you, we’re still talking more than just moving widgets around – I’m writing php and tweaking images to fit my design, modifying the widths of sidebars, and for the D&D site doing some pretty funky stuff with the loop to get the homepage output that I wanted, but at least to me it’s still a far cry from creating all of my own graphics from scratch, too.

Right now, my design process begins with a sketch of what I’d like the page to look like, then I find a theme (or several) that incorporates as many of the features that I want, and I go from there. It’s nice having the whole WordPress framework to lean back on to organize the actual content, as opposed to having separate files for each and every page like I used to do! Overall, I have a very love-hate relationship with web design because as much as sometimes I’d love to just hand all of this to someone else and say, “You deal with the stupid CSS – I’m gonna go write content!” at the same time design work can be a nice break for me when I’m not feeling as creative from a writer’s perspective and just want to work through a list of website tweaks that I need.

My ultimate short-term goal is to have another three sites redesigned by January-ish – two big ones and one that should be relatively painless, after which I’m hoping to take some time off from design to work on a new book. After that, who knows – maybe I’ll have a new project altogether to focus on, or maybe I’ll be taking another pass at one of these. A web designer’s work never ends…

© 1999 - 2012 Comedic-Genius Media, All Rights Reserved.