In the topic Zoho Creator URL Patterns we learned about the default URLs to access a Zoho Creator application and its forms, reports and pages. In this topic, we will learn about the functionality based URLs to set default values for form fields, edit individual records by passing record-ID in the URL, set criteria for and print reports and pages.
All URL formats will use the following:
|<base_url>||the base URL of your Creator account|
For example, its creatorapp.zoho.com if your account belongs to Zoho's US DC, and is app.zohocreator.eu if it belongs to Zoho's EU DC.
|<account_owner_name> ||is the username of owner of the Creator account in which the application exists|
|<app_link_name>||is the link name of the Zoho Creator application|
|is the link Name of the component - form, report, or page, respectively|
Permalink of Forms, Reports and Pages
You can also access the components (forms, reports and pages) in your Zoho Creator application using their permalinks. As the word suggests, a permalink is a permanent link; it refers to the URL of a particular webpage (a form, report or page, here).
The format of permalinks of your app's components are as given below:
Note: Accessing a component using its permalink requires the end user to be logged in.
To allow public access to your application components, refer to publish and embed forms, publish and embed reports, and publish and embed pages.
Functionality based URLs for Forms
To set default values for Form Fields
The default values for Form Fields can be set by passing additional parameters in the Form's URL. For example, to automatically load a value for the Field Employee ID in the Employee Manager Application, the default value is passed as query string (Employee_ID=1234) in the Form's URL, where Employee_ID is the Deluge script name of the Field in the Employee Form.
The Form's URL with query string will be in the below formats:
- Accessing within the Application:
- Accessing via its permalink:
- Accessing a Form, which is embedded in another webpage:
For the multi select and checkbox fields, there can be the need to set multiple values. For this, the values must be comma-separated in the URL. For example, if the values "Manager" and "Programmer" are to be set for the field Roles in the Employee Form, the URL will be: https://creatorapp.zoho.com/zchelp/employee-manager/#Form:Employee?Roles=Manager,Programmer
Note: The values that are passed as querystring in the URL will be set when the user accesses the form, i.e., On Load of the form.
To load Form without Field focus
You may note that when you access your form in your Zoho Creator application, the focus gets set on the first Field of the Form, i.e., the cursor appears on the first Field of the Form.
Assume that you have a website or blog, in which you have embedded your form. When your webpage is accessed, this default auto-focus behavior will scroll your webpage to where your form is placed. This may hinder a user's experience as the content present above the embedded form gets skipped. To handle this, Zoho Creator provides the zc_Focus parameter.
To edit individual records by passing record-ID in the URL
The URL to view and edit individual records using their record-ID is given below. This will display the Zoho Creator Form in Edit mode.
Refer to the topic Editing Records via Record ID for more information.
Functionality based URLs for Reports
To filter the data displayed by a Report
You can filter the data displayed by a report by setting the filter criteria as querystring in its URL. Filtering using multiple criteria is supported — use an ampersand character (&) to separate two field-value pairs. Below are examples of filtering the Employee Manager application's Employee View report. This report's URL:
URL format for filtering a report based on the EQUALS operator
where, FieldName1 and FieldName2 are the link names of the fields in the form
URL format for filtering a report based on the STARTS WITH operator
|Fieldname1||is the link name of the Field in your Form|
|Fieldname1_op||is the parameter that links the Fields and Operators|
|constant||is the value that refers to the operator that will act on the respective fields. Refer to this table to view the list of all Operators and their Constants.|
URL format for filtering a report based on the CONTAINS operator
For example, the URL to have this report display only those employee records where the employee is in some administrative role, is as follows. In this application, Role is a checkbox field and 26 is the constant that identifies the CONTAINS operator.
URL format for filtering a report based on the BETWEEN operator
where, StartingValue and EndingValue can be a number, decimal value, or date
Example: The URL to have this report display only those employee records where the date of joining is between 10-Sep-2019 and 30-Mar-2020, is as follows. The Date of Joining field in this application is of type date and 58 is the constant that identifies the BETWEEN operator.
URL format for filtering a report based on other date/date-time specific operators
Note: Refer to the table
below for the list of constants that denote the operators.
List of Operators and their Constants
To print a Report
To print a Report with criteria
To import data to Report
By adding this URL to the application components like page, form, or workflow in your application, you may enable users to import the data to the specified report by directing them to the import interface when the user accesses it. For instance, you can include this URL in the page panel or in openURL task within a workflow depending on you preference.
The users can import data only when they have import permission
to the application.
URL format for importing data to report is :
Example: Consider a sales management application, where a user has the invoice data and wants to import that data to the invoices report. The user can do it in a conventional way, or you can let user to import data directly with one click by attaching the URL as a button panel in the application page. When the user clicks the button, he will be directed to the import interface and by selecting the invoice file, data will be imported to the specified report.
Functionality based URLs for Pages
Pages can also accept URL parameters. You may access the below given URL as an example (parameter emp is being passed a value).
To print a Page with parameter
The URL format to print a Page with parameter is given below,
|paramName||is the name of the parameter defined in the Page|
|paramValue||is the value passed to the parameter that is defined in the Page|
Example: The URL to print a Page named "TestHTML" with paramName "dept" and paramValue as "Engineering" is given below. Here, the paramName "dept" is the name of the parameter defined in the Page to fetch records with the specified paramValue.
To convert Page to PDF
For example https://creatorapp.zoho.com/export/sampleapps/customer-support/pdf/More_Details_Html_View?ticketID=104
where ticketID is the name of the parameter defined in the Page
You can add the following parameters to customize certain aspects of the output PDF:
- Div embedded Forms/Reports inside Pages is not supported as already discussed in this Forum post. (This will be done only after we provide #include support, i.e., server-side include directive in Deluge. Users will have to change to the new implementation once done to enable PDF output). Refer to our limitations page for more details.
- Any authenticated content like images/CSS that requires your current credential will not be supported, i.e., any link/embedding in the Page to be converted into PDF, should be public content.
Any CSS/images and other links to be rendered have to be specified in full path. For example, /images/xyz.jpg will not be properly rendered.
Note: Refer to this
page to learn how to control the visibility of the PDF export option for your pages.