There are some older global functions that are not in a namespace. Most of these start with a $ character. These are
known as Non-namespace APIs. Global symbols that start with
$ are reserved by APEX.
Some functions return an interface, which is an object that contains functions known as methods and variables known as properties, that allows access to a specific instance of a page component or other entity.
Oracle APEX handles the details of rendering a page so compared to authoring your own HTML file it may not be initially
You should avoid entering your own
<script> tags in places where markup is allowed.
where URLs are allowed.
- Function and Global Variable Declaration - This code runs after the core APEX libraries and above File URLs have been loaded and before the document is ready (DOMContentLoaded event or jQuery ready).
See the Page Designer help for details on each of the above attributes.
It is a best practice to put the bulk of your code into one or more files. These files can be served by a web server that you have access to or served by APEX by adding the file to Shared Components: Static Application Files or, to share the file among multiple apps, Static Workspace Files.
minified files should be put in a sub folder named
minified/ relative to the original
source file or the file name should include
.min. This allows using substitution
token #MIN# to include
.min or #MIN_DIRECTORY# to include
minified/ as part of the File URL. You can use #MIN# or #MIN_DIRECTORY# or both.
This allows the minified file to be loaded normally but in debug mode the non-minified (original source) file will
be used for easier debugging.
For example if you have a file called
appUtils.js added to Static Application Files
you can create a minified version of that file called
appUtils.min.js that is also
added to Static Application Files. You would then reference the file as:
If you define your own page template it is highly recommended not to change the order. When in doubt about where
your code is loaded view the page source. Set breakpoints or use
apex.debug functions to determine when your code executes.
The best way to modularize and reuse your code is to create APEX plug-ins. Region, Item, and Dynamic Action plug-ins
All the APEX APIs described here are in files located relative to
has an Interactive Grid region the
widget.interactiveGrid.js files as well as others will automatically be included
without including the corresponding component on the page - this is very unusual.
includes jQuery as well) which is included on all pages. This is for informational purposes.
The set of files and how they are concatenated is subject to change in each release. You can define your own concatenated
files using Shared Components > User Interface Attributes > User Interface Details: Create Concatenated File.
which can be found in
Deprecation and desupport notices are given in the release notes.
Oracle recommends that you rewrite or replace any code that uses these legacy functions.
When developing new applications, no legacy files are included by default.