Giter Club home page Giter Club logo

Comments (8)

capotej avatar capotej commented on August 23, 2024

I can confirm this issue as well.

from mobile-fu.

lukas2 avatar lukas2 commented on August 23, 2024

me too. any ideas how to fix this?

from mobile-fu.

rankinit avatar rankinit commented on August 23, 2024

in the mobile_fu.rb in the vendor/pugins/mobile_fu/lib/mobile_fu.rb look at the method

is_mobile_device?

Do a check on the request.user_agent to see if it matches any of the publicly known search bots: ["googlebot", "msnbot", "mediapartners-google", "ia_archiver", "ask jeeves", "teoma","msnbot-media", "msnbot-webmaster"]

thats roughly what I did to fix

from mobile-fu.

lukas2 avatar lukas2 commented on August 23, 2024

it should be possible somehow to set the default-case to desktop-view. the same seems to happen in internet explorer 8. if the regexp for mobile devices does not match it could render desktop by default, no?

from mobile-fu.

lukas2 avatar lukas2 commented on August 23, 2024

hrmh..
well now i fixed it like this:

before_filter :set_default_response_format

def set_default_response_format
   request.format = :html if params[:format].nil?
end

it works with ie8, but i guess ill have to wait and see what the contents of the google cache for our site will be.

from mobile-fu.

rankinit avatar rankinit commented on August 23, 2024

check google webmaster tools there is something called check as google bot which will allow you to see what the google bot see when it visits your page otherwise you are going to have to wait a while for the google cache to update...

from mobile-fu.

Raphomet avatar Raphomet commented on August 23, 2024

This seems to be a Rails 3 peculiarity, not explicitly a mobile_fu thing. If request.format is nil (for example, when type / is requested, which is what Googlebot asks for), Rails prefers templates that match .mobile.erb over .rhtml. Changing our (very old) file extensions from .rhtml to .html.erb fixed this problem for us.

from mobile-fu.

benlangfeld avatar benlangfeld commented on August 23, 2024

This project is abandoned. Please see the active fork at http://github.com/benlangfeld/mobile-fu. Please test with the released gem and master branch of the new home for the project, and file an issue on the other repo if you still have problems.

See #40.

from mobile-fu.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.