Attributes for Fields in Web Maps

Note the For parameter of the Web_Map command affects which fields and working lists are exchanged between the Presentation Layer and the Webroutine. You might find it helpful to think of all the relevant Web_Map commands as defining a parameter list for your Webroutine.

However, the For parameter of the Web_Map command does not affect how the field is presented – that is the job of the Presentation Layer.

While you may want certain values to be for (*both), you may not want the user to be able to change them, or indeed see them, on the web page. To do this, you can specify the following attributes for fields in Web Maps:

     *output – the data is displayed on the web page, but the user cannot change it.

     *hidden – the data is passed between the logic and Presentation Layers, but the user cannot see it.

     *private – the data is passed between the logic and Presentation Layers, but the data is not merged into the XSL. (This has specialized uses where the value of a field or contents of a list are referenced during the XSL transformation process but do not need to be generated into the final page).

     Note: *input is also a valid attribute, and is the default.

Remember, though, that how the field is represented is the responsibility of the Presentation Layer. The field attributes you set in your web map to control this are only effective when the web design is generated for the Webroutine. After that you can alter how the field is represented using the LANSA Editor. What this also means is that field attributes specified in the web map should only be regarded as an indication of your intentions, as ultimately the Presentation Layer controls how the field is represented.

Here's an example where a DEPTMENT is to be passed back and forth and displayed, but you don't want the user changing its value:

Particular things to note about this example are:

As you can see, specifying *output as a field attribute has a very different meaning and effect to using for(*output) on the Web_Map command.