Re: routing based on browser width

sax
Mon, 07 Sep 2009 19:08:43 -0000

Seriously. Why bother disabling desktop browsers? I''ve seen a number
of mobile sites that render fine in any number of desktop browsers.

If you want to optimize layouts for particular browsers, you can turn
your layout call into a method. You can then put user-agent detection
there to render a particular layout customized for the particular
browser or device. If you really want to do redirection, it may be
possible to sneak that in there. I''ve never tried it myself, though.

On Sep 7, 11:17 am, Marnen Laibow-Koser <rails-mailing-l...@andreas-
s.net> wrote:
> dansinker wrote:
> > I have a site that''s directed toward mobile use. As a result,
the
> > basic structure consists of pages that render exclusively on mobile
> > devices, and then corresponding pages for desktop browsers that
> > explain that they need to come back on a mobile device.
>
> Please don''t do this.  If it''s optimized for mobile use,
that''s great,
> but there may be some use cases that you didn''t envision where it
would
> be convenient to use a desktop browser.  You may not like it, but you
> shouldn''t prevent your visitors from using the browser of their
choice.
>
> Best,
> --
> Marnen Laibow-Koserhttp://www.marnen.org
> mar...-sbuyVjPbboAdnm+yROfE0A@public.gmane.org
> --
> Posted viahttp://www.ruby-forum.com/.