Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7818689
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T06:39:50+00:00 2026-06-02T06:39:50+00:00

I have a simple controller that goes to a view under views/mobile/home/index.html.haml It works

  • 0

I have a simple controller that goes to a view under views/mobile/home/index.html.haml

It works and now I am trying to add files to views/layouts/mobile to ensure that the site responds to mobile and tablet viewing.

Should I create a new index.html.haml for the tablet and a separate one for the tablet view?

Also, as I understand it, I am supposed to make the index.html.haml and views/mobile/home/index.html.haml have a yield command so that at certain point during loading it loads the correct version of the mobile page. How do I do that?

My current controller is very basic like this:

class Mobile::HomeController < ApplicationController
  def index

    respond_to do |format|
      format.html
    end
  end

  def create

  end
end
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T06:39:52+00:00Added an answer on June 2, 2026 at 6:39 am

    Typically the responsive design should happen at the CSS and Javascript level. The HTML should define the semantic structure of the information you are displaying and NOT the visual design. Instead look at how frameworks like TwitterBootstrap handle the responsive design using things like CSS media queries etc.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a simple controller called list_controller with an index that basically does def
I have a simple Controller that looks like this:- @Controller @RequestMapping(value = /groups) public
I have a number of simple controller classes that use Doctrine's entity manager to
I have a simple form in python + pylons that submits to a controller.
I have a simple UserControl for database paging, that uses a controller to perform
I have a very simple RootView Controller ->Detail View Controller, to display a list
i wish to have a simple Action in my controller that accepts a few
In my html I have <h2>Title goes here</h2> @using (Html.BeginForm(Action, Controller, FormMethod.Post, new {
Simple scenario: table view controller, with 5.000 rows. I have 5000 images name from
I have a simple controller test, containing a.o. the following code: context POST :create

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.