You can create as many new web request forms as you wish by creating new request HTML pages and designating each one as a different Document Type.
Copy an Existing Request Form
- Select one of your existing ILLiad request forms (for example, LoanRequest.html) and copy it.
- Rename the copied page to GenericRequestX.html where the X represents your description of the new page. Example: GenericRequestMusicScore.html.
- Edit the HTML of the new page to reflect the new request type.
Note that ILLiad requires that the name of the file begin with the text GenericRequest.
Copy an Existing Edit Request Form
For every new request form that you decide to create, you also need to create a corresponding Edit form to handle the error and editing functions. If the DLL encounters a problem when the request is submitted, it jumps to the Edit page for editing.
Add Identifier Code to the New Form
- Add the following lines to the HTML code of the new request form.
- Note that if you are creating the new form by copying an existing form, the first line of code is already there.
- You will need to edit the value field of the first line and then add the two remaining lines of code as shown below:
<input type="hidden" name="ILLiadForm" value="GenericRequestX"> <input type="hidden" name="RequestType" value="Loan"> <input type="hidden" name="DocumentType" value="Y">
- Again, the X in the first line of code is used to describe the new type of request, for example, GenericRequestMusicScore.
- In specifying the RequestType (in line 2), you should first decide if the system should treat this new type of request as an Article or as a Loan. If the request type is intended to be consumable and will not be returned to the lending institution, set the RequestType value to Article. If the request type is intended to be returned to the lending institution, set the value to Loan.
- The DocumentType to be recorded by the system for this type of generic request is represented by the Y in Line 3. For this example, we are using Music as the DocumentType.
The DocumentType can only be set on Generic Request forms. You cannot set the DocumentType on default request forms such as ArticleRequest.html or LoanRequest.html - the database will automatically change it back to the default value.
Edit the Main Menu Page
To create a link to the new request form on the ILLiad Main Menu (include_menu.html):
- Open the include_menu.html page.
Add the following code to the list of new requests:
<li> <a href="<#ACTION action="10" form="20" value="GenericRequestMusicScore">"> Music Score</a> </li>
- Be sure to use the settings exactly as they are in the code sample for action and form.
- This text can be customized, but must contain the text that you used when creating the new page.
Changes in the Customization Manager
Adding Values to the WebFormValues Table
If you are using Submit, Cancel and Quit, or similar buttons on the new form, you need to add entries for the buttons to the WebFormValues table in the Customization Manager. The value in the SubmitButtonValue field should be the default value of this button. The value in the SubmitButtonText field is the text that you are using for this button in your request form.
Adding Values to the DocumentTypeOptions Key
In order for the document type of your new generic request to appear as a drop down option in the request form within the ILLiad client, it will need to be added to the DocumentTypeOptions key. This will be the same value that you placed in the DocumentType hidden field.