Updated flyout javascript.