<canvas height="100" width="100%"> <class name="clickClock" extends="text"><attribute name="dayTable" value="
["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"]
"/> <handler name="onclick"> var now = new Date; this.format("You clicked me at %02d:%02d:%02d on %s", now.getHours(), now.getMinutes(), now.getSeconds(), dayTable[now.getDay()]); </handler> </class> <clickClock> Click Me! </clickClock> </canvas> <!-- * X_LZ_COPYRIGHT_BEGIN *************************************************** * Copyright 2008 Laszlo Systems, Inc. All Rights Reserved. * * Use is subject to license terms. * * X_LZ_COPYRIGHT_END ****************************************************** -->