ChartDirector 5.1 (PHP Edition)

JsChartViewer.getCustomAttr


Usage

getCustomAttr(key)

Description

Gets a custom attribute.

The JsChartViewer does not interpret or use custom attributes. It merely receives them from the server side WebChartViewer control. On the server side, these attributes are set using WebChartViewer.setCustomAttr.

Custom attributes are useful for transferring application specific information between the server and the browser during partial chart updates (AJAX requests).

For example, one can use custom attributes to pass the values of browser side HTML controls to the server. (For non-AJAX requests, one can always use FORM POST or GET to pass information to the server.)

Both the key and value of a custom attribute should be text strings. The key should be a valid variable name, that is, it should start with A-Z, a-z or underscore, and consists entirely of alphanumeric characters with no spaces.

Arguments

ArgumentDefaultDescription
key(Mandatory)The attribute key.

Return Value

The value of the required attribute.