GenLink(Name : Function : Subfunction : Class : Target : Label : XML : Label type)
Name = HTML variable (30A)
Function = iSeries2Web function from SSAPD001P (20A)
Subfunction = iSeries2Web Sub-function from SSAPD001P (20A)
Class = CSS (Stylesheet) Sets the style of the hyperlink (20A)
Target = HTML target frame ( _self, _Blank , “Name”) (20A)
Label = Text on the hyperlink (200A)
XML = The XML data information encoded in the hyperlink (32000A)
Label type = *optional. The label is default, translated through the
language system. Specifying this parameter, enables control
over this. “L” = Language control , all other will disable the language control system and the text in the hyperlink will be as specified in the Label variable. (1A)
Return type:
Encoded XML that creates a encoded hyperlink, with a unique ID
Description:
For security reasons links etc. are encoded as a unique ID number. This way you can use any protected information (e.g. social security number etc.) in your links on the browser.
Normally you would set a link with query information displayable on the link:
http://www.xxxxx.com/somepage.asp?name=”Albertha”+secretinfo=”reveal”
You see this on top of your screen or in the hyperlink inside the HTML source
With iSeries2web the function GenIDtag all this is encoded and therefore not displayable in the browser.
The information you want to embed into the code is written in normal XML functions and then set into the GenLink function.
This function uses the Genid function, to make it easier to create hyperlinks. I the HTML page specify the name of the link in
“name”, and it will be transformed into at hyperlink.
Putxmlrdc(list_of_links:
GenLink(
:‘LINK’
:‘customer’
:‘edit’
:‘buttonclass’
:‘_self’
:‘l_edit_customer’
:xmlN('cust_no’: custno)
+xmlN('cust_tlf’: custtlf)
)
)
This way the 2 inner xmlN functions sends the encoded xml-string into the GenLink function, which created the code and sends this to the outer Putxmlrcd function, together with the rest of the hyperlink definitions.
When the user clicks on the link the values just encoded can be retrieved by normal RtvVar functions
All kinds of functions are allowed as the xml-string