Web Functions

Web Functions

LANSA's web development offerings have grown with the development of web technologies. Web Functions, described in this guide, are no longer supported for new customers.
LANSA's web development is now a part of the Visual LANSA development environment. This enables you to take advantage of the LANSA Repository and to use the RDML application development language to develop both web pages and server functions without the need to know HTML or JavaScript. To develop web based applications, refer to the Building Web Applications with Visual LANSA Guide for information.
Unless you are an existing web functions customer, we recommend that you bypass this guide.

 

Edition Date July 31, 2017

© LANSA

1. Introduction to LANSA Web Functions
1.1 What are LANSA Web Functions?
1.2 Major Features of LANSA Web Functions
1.3 LANSA Web Function Architecture
1.4 Programming Language Skills
1.5 How Do You Develop Applications with LANSA Web Functions?
1.6 LANSA Web Function Transaction Server
1.7 WEBEVENTs or WAMs?
2. Developing Applications with LANSA Web Functions
2.1 Before You Begin Checklist
2.2 Web Enabling a LANSA Process
2.3 Types of Web Functions
2.4 Example of a Procedural Function
2.5 Example of a WEBEVENT Function
2.6 Shipped LANSA Web Function Templates
2.7 Compiling Functions
2.8 Calling LANSA Web Processes and Functions
2.9 Executing Applications: Process Menu
2.10 Executing Applications: WEBEVENT
3. Executing LANSA Web Function Applications
3.1 No Existing Web Site
3.2 Integrating with an Existing Web Site
3.3 Before You Deploy Your Applications
3.4 Uniform Resource Locator (URL) Syntax
3.5 Calling a LANSA Process
3.6 Calling a LANSA Function Directly
3.7 Passing Parameters to a LANSA Function
3.8 Specifying a Task Identifier
3.9 Debugging using IBM i Batch Debug
3.10 Debugging using Visual LANSA
3.10.1 Start Development Environment Debugging Session
3.10.2 Start Web Browser Debugging Session
3.11 Invoking the IBM i Spooled File Facilities
3.12 Event Logging
3.13 Enabling Event Logging
3.14 Logging User Defined Fields
4. WEBEVENT Functions
4.1 What is a WEBEVENT Function?
4.2 How Does WEBEVENT Work?
4.3 How is WEBEVENT Different?
4.4 WEBEVENT Templates
4.5 WEBEVENT Example
4.5.1 Procedural Add an Employee Function
4.5.2 Changes Required to Restructure for WEBEVENT
4.5.3 Handling Re-entrant Functions
4.5.4 Final WEBEVENT Function
4.5.5 More Complex Example
4.6 Automatic Data Exchange
4.7 WEBEVENT Routing
4.8 WEBEVENT Keywords
4.9 Considerations for WEBEVENT Functions
4.10 WEBEVENT Data and Function Timeout
5. LANSA Generated HTML Pages
5.1 Page Security
5.2 Identifying Generated Pages
5.3 Modifying the Process Menu
5.4 Versioning of Pages
5.5 Comparing Versions
5.6 HTML Page Structure
5.7 LANSA Field Names in HTML Pages
5.8 HTML Generation Skeleton
5.8.1 What is the HTML Skeleton?
5.8.2 How Do I Use the HTML Skeleton?
5.8.3 Considerations for Using the HTML Skeleton
6. Default Process Pages
6.1 What are Default Process Pages?
6.2 Shipped Default Pages
6.3 Other Default Pages
6.4 Customizing Process Specific Pages
6.5 User Defined Default Pages
6.6 Standard HTML Page Components
6.7 Other HTML Page Components
6.8 Special XHTML Pages
6.9 Process Specific Page Components
7. RDML Tags
7.1 What are LANSA Tags?
7.2 How Do LANSA Tags Work?
7.3 LANSA Tags Example
7.4 Using <RDML> and </RDML> Tags
7.5 <RDML BUTTON>
7.6 <RDML CHECKVALUE>
7.7 <RDML COMPONENT>
7.8 <RDML COOKIES>
7.9 <RDML FUNCTION>
7.10 <RDML INCLUDE>
7.11 <RDML LAYOUT>
7.12 <RDML MERGE>
7.13 <RDML MESSAGES>
7.14 <RDML NOTCONDITION>
7.15 <RDML ONCONDITION>
7.16 <RDML ONMODE>
7.17 <RDML PAGE>
7.18 <RDML PARENT>
7.19 <RDML SETTMPFLD>
7.20 <RDML SSI>
7.21 <RDML TRACE>
7.22 Reserved Words
8. Graphic Variables
8.1 What are Graphic Variables?
8.2 Why Use Graphic Variables?
8.3 Types of Graphic Variables
8.3.1 Image File Graphic Variables
8.3.2 Color Graphic Variables
8.3.3 Text Graphic Variables
8.4 Default Graphic Variables
8.5 Process Level Graphic Variables
8.6 Browse List Graphic Variables
8.7 Technically Speaking
9. Web Components
9.1 Introduction to Web Components
9.1.1 What are Web Components?
9.1.2 Web Component Architecture
9.1.3 Web Component Example
9.1.4 Types of Web Components
9.1.5 Web Components and Modes
9.1.6 Automatic Embedding of Web Components
9.1.7 Dynamically Embedding Web Components
9.1.8 Considerations for Using Web Components
9.2 Manually Defined Web Components
9.2.1 Banner
9.2.2 Text
9.2.3 Web Link
9.2.4 Page
9.2.5 Script
9.2.6 Naming Page and Script Web Components
9.3 Generated Web Components
9.3.1 Visual Web Component
9.3.2 Creating Visual Web Components
9.3.3 Using Triggers to Generate Visual Web Components
9.3.4 File Web Component
10. Function Editor
10.1 Introduction to Web Function Editor
10.1.1 What is the Web Function Editor?
10.1.2 Connecting to the Data/Application Server
10.1.3 Starting the Web Function Editor
10.1.4 Web Function Editor's Main Window
10.2 File Menu
10.2.1 New
10.2.2 Open . . .
10.2.3 Close
10.2.4 Save
10.2.5 Save As
10.2.6 Compare
New Comparison
Compare With
Compare With Version
Close
10.2.7 Page Setup
10.2.8 Print
10.2.9 Connect
Save As
Advanced
10.3 Edit Menu
10.3.1 Paste HTML
10.3.2 Clear All
10.4 View Menu
10.5 Tags Menu
10.5.1 Insert RDML Component
10.6 Components Menu
10.6.1 Maintain Component
Add a new Component
Duplicate
Banner Component
Add/Change Banner Component
Add/Change Banner Detail
File Component
Page Component
Script Component
Text Component
Visual Component
Web Link Component
10.6.2 Generate Component
Generate Visual Component
Generate File Component
Considerations for using File Web Components
10.6.3 Graphic Variables
Add Graphic Variable
Change Graphic Variable
10.7 Options Menu
10.7.1 Configure
Third Party Editor
View
Miscellaneous
10.7.2 Font
10.7.3 Invoke Third Party Editor
10.8 Tools Menu
10.8.1 Keywords
Add Keyword
Maintain Keyword
Change Keyword
12. Web Development Tips & Techniques
12.1 HTML as Field Contents
12.2 Automatic Data Apportionment
12.2.1 Specifying Apportionment Position
12.3 Considerations for Browse Lists
12.4 Message Presentation Layout
12.5 Using <RDML MERGE="&END">
12.6 Cascading Style Sheets
12.7 Retrieve Additional Information from Browse List
12.8 Handle the ENTER key in Browsers
12.9 Embed a Calendar Control
12.10 Modify LANSA Messages
12.11 Set the Initial Focus in an HTML Page
12.12 Tailoring the DEFAULT_SCRIPT
12.13 Generate Static Page Output to the IFS (Integrated File System)
12.14 Integrate LANSA Applications with Static HTML Pages
12.15 CheckBox Visual Web Components
12.16 Extend LANSA Drop Downs
12.17 Modifying charset for non-English Systems
Tutorials for Web Functions & WEBEVENTs
WEB001 - Types of LANSA Web Functions
Step 1. Create a Procedural Function
Step 2. Create a WEBEVENT Function
Step 3. Execute your Procedural Function
Step 4. Execute Your WEBEVENT Function
Summary
WEB002 - Coding a WEBEVENT Functions
Step 1. Review Procedural Logic
Step 2. Create New Functions
Step 3. Define Keywords for Function Routing
Step 4. Test Your WEBEVENT Functions
Step 5. Re-entrant WEBEVENT Function
Summary
WEB003 - IBM i Batch Debug
Step 1. Identify Your Terminal ID
Step 2. Call Your Function in Debug Mode
Step 3. Enter valid data into your browser.
Summary
WEB004 - LANSA Generated HTML Pages
Step 1. Open and Configure the Web Function Editor
Step 2. Identify Generated HTML Pages
Step 3. Edit the HTML Page for iiiFN05
Step 4. Modify and Recompile Function iiiFN05
Step 5. Use Compare and Contrast to Review your HTML
Summary
WEB005 - LANSA Process Pages
Step 1. Create a Message Presentation Page for iiiPROC03
Step 2. Create a Standard Header for Functions in Process iiiPROC03
Step 3. Create a Standard Footer for Functions in Process iiiPROC03
Step 4. Component Registry
Step 5. Add the Calendar Control and Edit the Default JavaScript
Step 6. Test the Calendar Control
Summary
WEB006 - Graphic Variables
Step 1. Create New Graphic Variables
Step 2. Add Graphic Variables to the Process Pages
Step 3. Test Your Graphic Variable.
Optional Step 4. Web Functions Wizard Graphic Variables
Summary
WEB007 - LANSA Tags
Step 1. Review the LANSA Tags in iiiFN05
Step 2. Add LANSA Tags to iiiFN05001 HTML Page
Step 3. Modify Standard Process Footer
Step 4. Test the function
Summary
WEB008 - Web Components
Step 1. Create a New Field in the Repository
Step 2. Create Visual Web Component
Step 3. Create a Text Web Component
Step 4. Banner Web Component
Step 5. Use Hidden Fields in Function
Step 6. Create a Web Link Component
Summary
WEB009 - Web Page Substitution (Optional - Advanced)
Step 1. Create a New Function
Step 2. Create a New Web Component
Step 3. Copy the HTML Code For Page Component iiiFN08C
Step 4. Test the Function
Step 5. Add Fields to the iiiFN08 Function
Optional Step 6. Modifying iiiFN06
Summary
WEB010 - Web Skeletons (IBM i)
Step 1. Copy Default Web Skeleton
Step 2. Edit the Web Skeleton
Step 3. Execute Your Function
Step 4. Recompile Your Function
Step 5. Execute Your Functions
Summary
WEB011 - Using DEFAULT_HIDDEN
Step 1. Create Login Function
Step 2. Edit Standard Header for iiiPROC03
Step 3. Test your Functions
Step 4. Create a Process Level _HIDDEN Page
Step 5. Test your Functions
Summary
WEB012 - Dynamic Components
Step 1. Create a New Page Component
Step 2. Modify iiiPROC03_STDHEADER
Step 3. Test Your Function
Summary
WEB013 - JavaScript and Browse Lists
Step 1. Create Fields to be used as Function Parameters
Step 2. Create iiiFN11 Employee List
Step 3. Edit Process Level _SCRIPT
Step 4. Create a Link Component
Step 5. Modify Function iiiFN07
Step 6. Test Changes
Step 7. Include New Component Link into Employee Browse List
Step 8. Build Function iiiFN12 Employee Details
Step 9. Test Your New Functions
Step 10. Execute function iiiFN12 from a Command Line (Optional)
Step 11. Create Page Component for Function iiiFN12 (Optional)
Step 12. Test Changes (Optional)
Summary
WEB014 - Browse Lists
Step 1. Create Page Component for Function iiiFN11
Step 2. Test Changes
Step 3. Create Graphic Variable for Browse List
Step 4. Test Changes
Step 5. Customize Browse List
Step 6. Test Changes
Step 7. Add Table Tags Around Browse List
Step 8. Test Changes
Step 9. Add Column Headings To Browse List
Step 10. Test Your Functions
Summary
WEB015 - Data Apportionment
Step 1. Create iiiFN13 – Contact Us
Step 2. Create a New Page Component
Step 3. Compile and Test Your Function iiiFN13
Step 4. Using JavaScript Alerts (Optional)
Summary
Personnel Demonstration System
Personnel System Demonstration Files
Sample Data in the Personnel Files
Appendix A. Header Styles
Static Header
Dynamic Header
Scrolling Header
Non-Scrolling Header
Frameset Definition
Limitations of non-scrolling headers
Combination Of Scrolling And Non Scrolling Header Styles
Override Header Style
Adopted Header Style
Appendix B. LANSA Web XHTML
Introduction to XHTML 1.0
What is XHTML 1.0?
Why use XHTML 1.0?
Compatibility with HTML
Converting HTML to XHTML 1.0
XHTML Syntax Rules
XML Declaration
XHTML Document Type Definition (DTD)
Document Type Definition (DTD)
How to Avoid the Insertion of the DOCTYPE Declaration
Serving XHTML Pages as Pure XML Pages