You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by ael <al...@dash.com.ph> on 2010/09/22 09:33:38 UTC
T5 Internet Browser Detection?
Is it possible that tapestry can detect web browser?
I already implement it using JQuery.
Using
script type="text/javascript">
$(document).ready(function(){
if($.browser.msie)
{
if($.browser.version == 4.0)
{
window.location = "http://www.google.com";
alert("Please install the latest IE Browser!");
}
}
});
</script>
But i want to use Tapestry so that it can return into another page.
Is this possible?
Any ideas? ^_^.
--
View this message in context: http://tapestry.1045711.n5.nabble.com/T5-Internet-Browser-Detection-tp2849300p2849300.html
Sent from the Tapestry - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: T5 Internet Browser Detection?
Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
On Wed, 22 Sep 2010 04:33:38 -0300, ael <al...@dash.com.ph> wrote:
> Is it possible that tapestry can detect web browser?
Yes. Just @Inject Request and use request.getParameter("User-Agent") to
get the user agent string.
--
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,
and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: T5 Internet Browser Detection?
Posted by Kristian Marinkovic <kr...@porsche.co.at>.
you'd have to implement a HttpServletRequestFilter or better a Dispatcher
that analyzes the http headers and redirects to other pages or sets some
global state that is used during page rendering. A Dispatcher is more
convenient as you can use all the tapestry services and don't have to use
the servlet api directly.
g,
kris
Von: ael <al...@dash.com.ph>
An: users@tapestry.apache.org
Datum: 22.09.2010 09:34
Betreff: T5 Internet Browser Detection?
Is it possible that tapestry can detect web browser?
I already implement it using JQuery.
Using
script type="text/javascript">
$(document).ready(function(){
if($.browser.msie)
{
if($.browser.version == 4.0)
{
window.location = "http://www.google.com";
alert("Please install the latest IE Browser!");
}
}
});
</script>
But i want to use Tapestry so that it can return into another page.
Is this possible?
Any ideas? ^_^.
--
View this message in context:
http://tapestry.1045711.n5.nabble.com/T5-Internet-Browser-Detection-tp2849300p2849300.html
Sent from the Tapestry - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org