Monolith Design

Pi Day — a Hundred Million of them!

Archived in the category: Random Fun

The US population reached pi * 100,000,000 = 314,159,265 on August 12, 2012. Here’s the link from Huffington Post. The Census Bureau has a running population counter, as well. I must admit — I was not there waiting for it to reach the Super Pi.

I have been a fan of the SimpleDrop dropdown menu from JavaScript Array for a while. Basically, once I found it, it became my standard dropdown menu package. The simplicity is what originally drew me—it has a tiny footprint beyond jQuery. Of course, the name SimpleDrop was well-chosen. It has no frills, but it works on all major browsers, including Internet Explorer 6. IE6 is almost extinct, but I have a client that doesn’t have the money to update their infrastructure, and are therefore limited to IE6.

I have made some improvements to what I now call SimpleMegaDrop, and it now offers these features:

  • Standard dropdown menus (single-level) in a navbar
  • Mega-dropdown menus integrated with dropdown menus
  • Free-standing Buttons that invoke dropdown or mega-dropdown menus.
  • All of the menu items use hoverIntent to reduce the overall twitchiness.

Proceed to the demo—download links are at the bottom.

English is Tough Stuff!

Archived in the category: Random Fun

Written by G. Nolst Trenito, 1870 – 1946. These verses were designed to help multi-national personnel at NATO headquarters discard their accents. After trying them, a Frenchman said he’d prefer 6 months at hard labor to reading 6 lines aloud. This has floated around for a long time, since before the Web. I first saw it while working at HP Labs back in the Eighties. It makes a great sample post for a new blog….

Dearest creature in creation,
Study English pronunciation.
I will teach you in my verse
Sounds like corpse, corps, horse, and worse.
I will keep you, Suzy, busy,
Make your head with heat grow dizzy.
Tear in eye, your dress will tear.
So shall I! Oh hear my prayer.

Just compare heart, beard, and heard,
Dies and diet, lord and word,
Sword and sward, retain and Britain.
(Mind the latter, how it’s written.)
Now I surely will not plague you
With such words as plaque and ague.
But be careful how you speak:
Say break and steak, but bleak and streak;
Cloven, oven, how and low,
Script, receipt, show, poem, and toe.
Read more »

Unknown Kyrie by Palestrina?

Archived in the category: Music

I’ve been trying to identify a Kyrie that I sang a long time ago (maybe 1972), but I don’t have the sheet music for it. I remember it as being by Palestrina, so I’ve searched every Kyrie from every Mass I can find by Palestrina on cpdl.org, and I have not been able to identify the piece. It’s pretty distinctive: the tenors start out with a lovely line, and then the basses come in, and then the upper voices.

Unknown Kyrie by Palestrina

Does anybody know the source of this piece? Maybe it’s not even Palestrina, although I’m pretty sure of it. If you have a clue, please let me know! I’m always looking for music for the 2 SATB groups in which I sing, so other suggestions are appreciated.

Here’s the second installment in my Working Set series: my standard set of jQuery plugins. I’ll also include a few other bits of code I use occasionally that are not in plugins. I make no claims about these being the best or anything like that, but this is a really useful, robust set of plugins that will be useful in any Web site.

Fall Cow by DFF

jQuery

www.jQuery.com

The source of jQuery.

jQueryUI

www.jQueryUI.com

The source of jQuery’s user interface modules.

AjaxContactForm

http://midmodesign.com/news/coding/jquery-ajax-contact-form-with-honeypot/

A straightforward Ajax Contact Form that can be dropped into a sidebar anywhere. You can see this in action at www.kelleyhousemuseum.org.

Cycle Plugin

http://malsup.com/jquery/cycle/

I use this all the time. It’s a very easy way to cycle images or HTML content. There’s even a light version that eschews the flashy kinds of transitions.

DataTables

DataTables.net

This is an amazingly full-featured table plugin. Filtering, striping, searching, and more.

HighSlide

Highslide.com

HighSlide is a superb Javascript library for displaying images and slideshows. This well-supported module has a minimal charge for commercial usage, but it’s well worth it. Tremendous flexibility and stability! It’s been in continuous development for many years, and it really shows in the feature set. They have lots of excellent examples of the library in use.

hoverIntent

jquery.hoverIntent.html

This wonderful little plugin helps smooth out user interactions. Instead of immediately invoking the onmouseover handler on links, this waits for a settable threshold before firing the onmouseover event. If you slide the mouse over a row of menu items, this will suppress all the random firings along the way to wherever you were moving the mouse. It can really make a big difference in reducing the jerkiness of the interface.

jkMegamenu

www.javascriptkit.com/script/script2/jkmegamenu.shtml

This little module from JavascriptKit is a straightforward implementation of a mega-dropdown menu. You can see this code in action on MendocinoFun.com.

SimpleDrop

javascript-array.com/scripts/jquery_simple_drop_down_menu/

Simple jQuery-assisted dropdown menu code. It only does a single level of dropdown, which is plenty— that’s why mega-dropdowns were invented! This code is simple to use and to style with CSS, and it’s robust because it’s so simple. And it works reliably on IE6, too.

Equal Column Heights

(hack)

This is a little hack I use a lot, and it ensures that selected columns are the same height. One of the great advantages of absolute positioning is that you can place sidebar material after more important content in the file for search engine spiders. The disadvantage is that absolute positioning removes the object from the flow, and the sidebar can therefore overlap the footer below if the sidebar is taller than the main content on the page. Note that this can equalize heights among multiple columns, not just 2. Place this code in the bottom of your HTML, just inside the /html tag.

<script type=”text/javascript”>
// this sets all columns to the tallest height of the selected elements….
var max = 0;
$(“#content, #leftnav, #sidebar”).each(function() { max = Math.max(max, $(this).height()); }).height(max);
</script>

This code will equalize the heights of columns with IDs “#content”, “#leftnav”, and “#sidebar”.

There’s my working set. There are other modules I use occasionally, so I’ll get to those in a subsequent post.


QR Code Business Card