Nanbudo_Norge2007-12_038Shiga, Japan 2010-04-18Kuortti.2010-06-26Vesa-Rauttu-60v_1899Oslo.Norway.2002.summer.034norge5oslo_169Osaka, Japan 2010-04-29Saaristoleiri-Uto-2008_180italia2005-04_219Kobe, Japan 2010-05-01Kuortti.2010-06-26Naginata Helsinki 2010-02-07 09Slovenia2009-04_658Helsinki2005-10-15_16_019Zoo2006-10-07_043Kobe, Japan 2010-04-28italia2005-05_131Saaristoleiri-Uto-2008_177Nanbudo_Norge2007-12_211South.Africa.Roadtrip.2007-08_216Inujima, Japan 2010-04-30Pakkas03Pitkanen_076
A warning sticker on a wooden stick

The martial artist should be warned.

WYMeditor content updating

In kobudo.fi the content editing is done with a jQuery plugin called WYMeditor.

It works remarkably well in Firefox, but in the loving Internet Explorer the content of the original content container was not updated when the update event was something else than "click". I wanted to use "mousedown" which would trigger in most cases few milliseconds earlier than "click" event, thus giving more time for the browser to do its javascript processing. Below is the current implementation shown.

$('textarea.editor').wymeditor({
    lang: 'en',
    xhtmlParser: 'xhtml_parser.min.js',
    cssParser: 'wym_css_parser.min.js',
    stylesheet: 'css/kobudo.fi.css',
    jQueryPath: 'js/jquery.set8.min.js',
    updateSelector: '#formsubmit',
    updateEvent: 'click'
});

The file called "jquery.set8.min.js" is a set of jQuery and common plugins needed througouht the site, in minified form. At the time of writing, the plugins and their versions are the following:

  • jQuery 1.2.3
  • dimensions revision 4841
  • cluetip 0.9.6 (actually using 0.9.3 since 0.9.6 has some performance issues)
  • TableSorter 2.0.3
  • validate 1.2.1
  • bgiframe 2.1.1
  • Autocomplete 1.0 beta
  • UI.datepicker 3.4.3

WYMeditor used here is the release version 0.4.

An example for testing purposes of the difference between browsers and the event handlers is available at kobudo.fi:
Using "click" event as the update handler
Using "mousedown" event as the update handler.

Time: 14/04/2008 14:02

QR code for paazio.nanbudo.fi