Archive for April 2008

HTTP errors with WP 2.5 and 2.5.1 uploads

I keep getting HTTP errors when using the flash upload in WP 2.5 and 2.5.1. After some digging around a bit, adding the following to my .htaccess file solved it:

<IfModule mod_security.c>
<Files async-upload.php>
SecFilterEngine Off
SecFilterScanPOST Off
</Files>
</IfModule>

Hopefully this helps someone else out too…

jQuery Example: Ajax activity indicator

Rick Strahl has been doing some great posts about jQuery on his blog. Yesterday he posted about an excellent resource, ajaxload.info, for creating ajax activity indicators. The second jQuery example that I’d like to share concerns how to display those images on each ajax call. Here is the relevant jQuery code:

The first two jQuery snippets are placed in the $(document).ready function. The HTML body has a div appended to it that will hold the loading image. We then set the CSS properties of that div to hide the image and define the placement.

The last snippet is outside of the $(document).ready function and serves to bind the visibility of the ajaxStart and ajaxStop jQuery events.

Now, everytime an ajax call is placed back to the server, a animated gif image will display in the upper right hand corner of the page to indicate background ajax activity. When the request is finished, the image will hide itself again.

See the demo and view the source to learn more. In this demo, your message is POSTed via ajax to the server which sleeps for 3 seconds then outputs your message into a message box. Make sure to peak at the upper right side of the page to see the activity indicator.

Thanks go out to jQuery for their awesome framework and Mike Alsup, the jQuery Form plugin author, for such a great plugin.

Crazy Oregon Weather II

April 12th 2008: 79 degrees and sunny. Beautiful spring day.

April 19th 2008: Snowing and hailing…

Snow and hail blanket valley

Desktop Tower Defense foils me again

I’ve been trying for months to get past level 80 (and over 10,000 points) on the 10K gold fun mode on Desktop Tower Defense. I passed level 80 today, with level 74 being my previous record for the last few months. So close!

jQuery Example: Zebra Tables (Striping)

I’m working on putting some of my most often used jQuery snippets onto SKFox.com. Here is my first such attempt. Table striping makes data easier to read and jQuery has some great selectors for this.

$(”table.zebra thead > tr:first-child()”).addClass(”zSelected”);
$(”table.zebra tbody > tr:nth-child(odd)”).addClass(”zOdd”);
$(”table.zebra tbody > tr:nth-child(even)”).addClass(”zEven”);

Be sure to check out the table striping demo page and view the source to see the small amount of CSS and javascript it takes to make your tables pop for your users.

More to come over the next few weeks…