Pre-load a Query
To load a predefinded filter, you need to pass its JCSDL definition to the Query Builder and execute the loadJCSDL function with the query as a parameter. You can do this in several ways:
- Provide a text area into which a user can paste the JCSDL definition of a query.
- Hard code a JCSDL definition in your HTML code.
- Retrieve a JCSDL definition through an AJAX call (for example, from a database).
The following example shows how you can pre-load a hard-coded JCSDL query in the Query Builder.
This code produces this result.