(a) 
addDynamicContent("temperature", &getTemperature); 

(b)
static char dyndata[81];
char *getTemperature(void)
{
	float temp;
	// read the temperature
	sprintf(dyndata, "%5.2f", temp);
	return(dyndata);
}

Example 3: (a) Function installed along with the string name represented in an HTML file; (b) function returning a string representation of the dynamic data.

Back to Article