Add a delay for performance reasons so that the caret position is only checked a few times per second, the 'updateinterval' attribute on the linked element will allow users to modify this value.