Author: lfryc(a)redhat.com
Date: 2010-07-10 15:35:29 -0400 (Sat, 10 Jul 2010)
New Revision: 17853
Modified:
root/tests/metamer/trunk/src/main/webapp/components/a4jPoll/simple.xhtml
Log:
extended output for a4jPoll - time since epoch + client side output
Modified: root/tests/metamer/trunk/src/main/webapp/components/a4jPoll/simple.xhtml
===================================================================
--- root/tests/metamer/trunk/src/main/webapp/components/a4jPoll/simple.xhtml 2010-07-10
19:34:57 UTC (rev 17852)
+++ root/tests/metamer/trunk/src/main/webapp/components/a4jPoll/simple.xhtml 2010-07-10
19:35:29 UTC (rev 17853)
@@ -12,6 +12,7 @@
</f:viewParam>
</f:metadata>
<h:outputStylesheet library="css"
name="a4jPoll.css"/>
+ <h:outputScript library="script" name="date-format.js"
/>
</ui:define>
<ui:define name="outOfTemplateBefore">
@@ -38,8 +39,23 @@
</h:panelGroup>
<h:panelGroup id="time">
- <h:outputText id="outputDate"
value="#{a4jPollBean.date}"/>
+ <h:outputText value="Server: " />
+ <h:outputText id="serverDate"
value="#{a4jPollBean.date}" title="#{a4jPollBean.date.time}">
+ <f:convertDateTime pattern="dd.MM.yyyy HH:mm:ss.SSS" />
+ </h:outputText>
***
+ <h:outputText value="Client: " />
+ <h:outputText id="clientDate" value=""
title="" />
+ <script type="text/javascript">
+ //<![CDATA[
+ var now = new Date();
+ jQuery("div.content span[id$=clientDate]")
+ .text(now.format("dd.mm.yyyy HH:MM:ss.l", false))
+ .attr("title", now.getTime());
+ //]]>
+ </script>
+ ***
+ <h:outputText value="Counter: " />
<h:outputText id="outputCounter"
value="#{a4jPollBean.counter}"/>
</h:panelGroup>
</ui:define>
Show replies by date