With Summer 14 release Salesforce remove the support of JavaScript in sidebar component.
doc: http://docs.releasenotes.salesforce.com/en-gb/summer14/release-notes/rn_forcecom_home_page_components.htm
We replaced the rich text editor in HTML Area home page components
with a new version that supports more markup but doesn’t allow HTML to
be manually entered.
In Summer ’15 we will start removing unsupported code from HTML Area home page components. As a result, components that contain
JavaScript, CSS, iframes, or other unsupported markup might stop
working properly. To use JavaScript or other advanced HTML elements in
your home page component, we recommend that you use a Visualforce Area
component instead.
End of javascript sidebar workarounds