Okay, so for people who are javascript heroes, what I'm going to write about is ridiculously lame.  But I think it's cool.

Yesterday, I was working on an application for a client.  Part of it needed to use the fancy lightbox feature for images.  But on top of this, the client wanted to be able to not only place captions on the lightbox images, but also make elements of the caption linkable.  

This is not hard, but for those not used to writing HTML, much less nested HTML, this can be a challenge–definitely not user-friendly from a client's perspective.  The easy solution was to provide a "template" that the user could copy, paste and alter as needed.  Unfortunately, this is not a very good solution as slight mistakes can cause terrible problems which are not easily resolved by those who don't know how to fix it, much less what the problem actually is.

So I set out for another solution.  I've always admired WYSIWYG editors in that they allow users to easily add complex bits of code (like <a> tags with multiple attributes) through a form, which itself inserts the complied code into another form.  Always intimidated by javascript, I thought this More >