Tidy up the RSS

I’ve been playing around with backing up my tweets lately. At this point I’m using the Twitter Tools plugin to create a weekly digest. Since I created a Tumble-blog not to long ago to share social stuff like this I also wanted the tweets to go to tumblr. Part of this was just a way to clean up Tumblr and not create a new post everytime I tweet.

Now, having the tweets on the blog is mostly for me. I didn’t want to bombard people that are subscribed to the RSS feed with this weekly mashup of all my tweets, but still be able to have the RSS feed to send to Tumblr or for anybody that wants it.

This is what I ended up doing:

function tweetRSS123($query) {
if ($query->is_feed && !is_category()) {
$query->set(‘cat’,’-1′);
}
return $query;
}

add_filter(‘pre_get_posts’,’tweetRSS123′);

(more…)

Anything Slider: Go on “Go”

Last week when I was in the CSS-Tricks forums, somebody wanted to modify the functionality of Chris Coyier‘s anythingSlider. Not a huge change, he just wanted to make the slider advance to the next panel when you click “Go”. Made sense to me. By the time you click “Go”, you’re done looking at that panel and are ready for the next one. If it doesn’t advance until after whatever delay you’ve setup, it could be confusing.

Basically what we want to do is make the slider advance to the next panel when we click go, which is the same as advancing to the next panel after we click the start/stop button if the slider ends up playing. It sounds complicated, but it will make more sense when we look at the code.

base.$startStop.click(function(e){
base.startStop(!base.playing);
if(base.playing) base.goForward(true);
e.preventDefault();
});

(more…)

Youtube, Vimeo Showing in HTML5

Both YouTube and Vimeo recently gave an option to watch videos in HTML5. I switched right away knowing that every time I try to play an HD video on YouTube, my Macbook fan spins up because of the heat caused from flash processing. On the Dell Mini I just bought, I couldn’t even watch HD videos on youtube because HD video in flash was too much for the atom processor.

When I saw that YouTube and Vimeo were offering HTML5 instead of flash video, I immediately tested both of the above mentioned issues. The fan in the macbook stayed quiet and the Dell Mini didn’t have any problems when I watched HD content with HTML5 video instead of flash. This is an example of the power of HTML5 video and why Apple decided to skip flash on the iPad.

The other thing that I really like about this is the fact that it pushes the HTML5 spec forward that much more. Obviously Google is involved in developing HTML5, so it shouldn’t be a surprise to see this on YouTube. Vimeo, however, is not involved — at least that i know of — in developing the HTML5 specification and just wants clean, efficient code. HTML5 is a good way to do that.

(more…)

A Contact Page to Avoid Spam

There are too many website owners displaying their email address in the “name [at] tld [dot] com” format, or something like that. Whatever happened to the good old mailto link with the email address being displayed how it’s supposed to? I’ll tell you what happened — spam happened.

Many site owners are afraid of displaying their email address, as it should be displayed, on their site. Since spammers can use scripts to scan websites, the same way google does, to look for email addresses. I’ve been seeing more and more contact forms and weirdly formatted addresses to combat the issue, but there’s a better way.

The robots.txt file in the root of your website is where you control what these bots can do and what they can’t. So if you’ve got your contact info on a certain page, then don’t allow bots to view that page. Bingo.

Now, the robots.txt file isn’t a standard and there’s nothing that guarantees that spam bots will follow the rules, but we can take this a step further.

(more…)

Blogroll Links Favicons

Awhile back I wrote that I was having issues with Blogroll Links Favicons plugin for WordPress. I came up with some code that better displayed the favicons and fixed my issue. I wrote the author and he agreed that this code made more sense. I hadn’t thought about it, but recently I checked to see if the updated code had been put into the plugin and it hadn’t.

Just yesterday I emailed John about getting added as a contributor to the plugin, as he’s recently switched his personal site over to Posterous. He agreed to add me and I put my code in right away.

In the future I’m also going to be looking for ways of optimizing the plugin even more than it already is. I have quite a few links on any given page of my site that use this plugin, especially the about page. It’s getting to the point that having to retrieve all these thumbnails slows down my site, so I’m going to look into making this as fast as possible.

Let me know if you’ve got any questions or suggestions.