Home | Printable Version
3.11: JavaScript
You can access Javascript files using the Files tab on the left hand side of the Page Design tab. These files are categorised as application-wide and page-specific, depending on whether they affect the whole application or just individual pages. You can use JavaScript of your choice to provide dynamic behaviour for your application. You can access the JavaScript files using the Project Repository browser. To do this, click on the Include local file... link. It is also possible to link script files that are hosted remotely using the Include remote file link. These latter files are referenced, but cannot be viewed or edited in the Studio. Once the files are linked, the JavaScript functions can be called from the Events tab. JavaScript - Adding files
Using other JavaScript Frameworks
You may wish to use your own controls either to enhance the WebMaker controls or include new controls. You can include controls from attribute-based control frameworks such as Dojo. WebMaker uses Dojo for some controls such as, Currency Amount and Accordion. JQuery is also used for Paging Table and Charts, and Google is used for the Maps. To use other JavaScript frameworks you need to use the Page Onload Events section and the Custom Attributes section within the Properties tab. In the Page Onload Events section you need to enter the Dojo requires script calls to ensure the correct controls are included for use. You can access the Page Onload Events section by clicking on the top-level Page Details icon on the panel above the Page canvas. By default, the relevant Dojo script files are included within WebMaker when elements are dragged on from the Palette on the left hand side. Adding onload page event for dojo control You can also include script files of your choice within the Files tab. Once this is done you can simply include attributes by specifying their name-value pairs under the Custom Attributes section of the Properties tab. A version of the JQuery files is pre-loaded. Please refer to the section on Custom Attributes later in this guide for more details. Creating Rich Controls
Page Display Bindings Previewing and Testing Pages