Modified the JavaScript