Global JavaScript and CSS Files

In your extension, you can adjust Plesk functionality and appearance by means of JavaScript and Cascading Style Sheets (CSS). These technologies enable you to do a variety of customizations to the Plesk interface, for example, adding new GUI elements and hiding existing ones. To make Plesk load your JavaScript or CSS code on every page of Plesk, put the code in the files global.css and global.js inside the /htdocs directory.

To load the code only on certain pages, use a construction like the following:

    if ("/smb/file-manager/list" != window.location.pathname) {

The Plesk's JavaScript framework is Prototype.

If you need to load additional libraries, you can do this directly in HTML, for example:

    	new Element("script", {type:"text/javascript", src:"//"})