GenericElementUDR

The GenericElement UDR is used to create any HTML element.

Click the following to see an example APL code to create an image on a page using GenericElement.

GenericElement img = udrCreate(GenericElement); img.tag = "img"; img.attributes = mapCreate(string, string); mapSet(img.attributes, "src", "https://www.w3schools.com/jsref/img_pulpit.jpg"); mapSet(img.attributes, "width", "304"); mapSet(img.attributes, "height", "228");

The following fields are included in the GenericElement UDR:

Field

Description

Field

Description

attributes (map<string,string>)

This field may contain extra attributes to be added.

components (list<ComponentUDR>)

This field contains a list of child components.

cssClasses (list<string>)

This field may contain a list of extra values added to the class attribute. This is typically used to style the component. Please read more on Bootstrap.

id (string)

This field may contain the id of the component

tag (string)

This field contains a tag name for a valid HTML tag. For example: Div, Img, Span .