'getBatherExtendedBrowserInfo()' really just builds a small page to test client 
side settings which posts back the information it's gathered. That page is 
provided from 'newBrowserInfoPage()' in WebSession.

Thus, if you want to plug Modernizr into your session before the page load, you 
can override this method and provide a custom page which includes Modernizr. 
Three things to note about this approach. First, you should probably start with 
just extending the 'BrowserInfoPage' class to get it's built in postback 
functionality. Second, this callback doesn't trigger until you call 
'WebSession.getClientInfo()' for the first time, so make sure that's done 
before any heavy lifting. Finally, I would suggest embedding Modernizr onto 
your new page directly instead of linking a JS file. This is mainly to reduce 
latency overhead from multiple requests.

Thanks,
-David Phillips - USAA

-----Original Message-----
From: Corbin, James [mailto:jcor...@iqnavigator.com] 
Sent: Monday, November 12, 2012 9:11 AM
To: users@wicket.apache.org
Subject: EXTERNAL: Re: Detecting HTML 5 Features in Wicket

Thanks, I have already.  I know how to detect HTML5 features using javascript, 
just wondered what is the best way to do so from Wicket code.
Given your suggestion, how could I use Modernizr to set browser state 
indicating, for example, that HTML 5 local storage is in fact supported.
I'm just not sure how to plug something like this into the initialization of 
the web application.  It would be nice if the gather extended browser info 
support in Wicket supported these properties.

I'm just curious how others have managed to answer the question, "Does my 
browser and version support HTML 5 Local Storage?", from Wicket code.

Thanks,
J.D.







On 11/12/12 7:59 AM, "Phillips, David" <david.phill...@usaa.com> wrote:

>I would suggest taking a look at Modernizr (http://modernizr.com/) for 
>feature detection.
>
>Thanks,
>-David Phillips - USAA
>
>-----Original Message-----
>From: Corbin, James [mailto:jcor...@iqnavigator.com]
>Sent: Monday, November 12, 2012 8:40 AM
>To: users@wicket.apache.org
>Subject: EXTERNAL: Detecting HTML 5 Features in Wicket
>
>Is there any built in support for detecting HTML 5 browser features 
>like Web Storage?
>
>If not, what is  the recommended approach for doing so?
>
>I'm looking for a way to detect support for Web (e.g. Local) Storage, 
>so in cases where the browser's do not support it (e.g., IE7), I can 
>use cookies or some other mechanism instead.
>
>Thanks,
>
>J.D.
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>For additional commands, e-mail: users-h...@wicket.apache.org
>
>



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to