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 8651111
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T13:58:56+00:00 2026-06-12T13:58:56+00:00

I have been struggling with getting this to work properly. I am trying to

  • 0

I have been struggling with getting this to work properly. I am trying to get the Horizontally grouped select inputs to work, on my mobile site from this page:

http://jquerymobile.com/demos/1.0/docs/forms/selects/

Right now my select boxes look like this:

enter image description here

But when I view the example it looks like this:

enter image description here

My HTML looks like this:

   <fieldset data-role="controlgroup" data-type="horizontal"> 
    <select name="select-choice-month" id="select-choice-month">
        <option>M</option>
        <option value="January">January</option>
        <option value="February">February</option>
        <option value="March">March</option>
        <option value="April">April</option>
        <option value="May">May</option>
        <option value="June">June</option>
        <option value="July">July</option>
        <option value="August">August</option>
        <option value="September">September</option>
        <option value="October">October</option>
        <option value="November">November</option>
        <option value="December">December</option>
    </select>
    <select name="select-choice-day" id="select-choice-day">
        <option>D</option>
        <?php while($c < 32) {
            echo '<option value="'.$c.'">'.$c.'</option>';
            $c++;
        } ?>
    </select>
    <select name="select-choice-year" id="select-choice-year">
        <option>Y</option>
        <option value="2012">2012</option>
        <option value="2013">2013</option>
        <option value="2014">2014</option>
    </select>
</fieldset>

And my include scripts look like this:

<link rel="stylesheet"  href="//code.jquery.com/mobile/1.0/jquery.mobile-1.0.min.css" />
<script src="//code.jquery.com/jquery-1.6.4.js"></script>
<script src="//code.jquery.com/mobile/1.0/jquery.mobile-1.0.min.js"></script>

I’ve tried copying and pasting the example exactly, and I still get the vertical and not horizontal, what am I doing wrong here?

  • 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-12T13:58:57+00:00Added an answer on June 12, 2026 at 1:58 pm

    Ok. So playing around with it some more and I got the select options working as you want it. These were the changes I had:

    <meta name="viewport" content="width=device-width, initial-scale=0.9">
    

    Keep in mind that the initial-scale value will change as per the width of your page and design.

    Then I changed the select options as follows:

    <div data-role="fieldcontain">
        <div data-role="controlgroup" data-type="horizontal">
            <select name="select-choice-month" id="select-choice-month" data-mini="true">
            <option>Month</option>
            <option value="jan">January</option>
            <!-- etc. -->
            </select>
    
            <select name="select-choice-day" id="select-choice-day" data-mini="true">
            <option>Day</option>
            <option value="1">1</option>
            <!-- etc. -->
            </select>
    
            <select name="select-choice-year" id="select-choice-year" data-mini="true">
            <option>Year</option>
            <option value="2011">2011</option>
            <!-- etc. -->
            </select>
        </div>
    </div>
    

    For some strange reason adding the legend tag inside the controlgroup wrapper breaks the design. Don’t know if this is a bug or not. If you want a title for the dropdowns then you can do the following:

    <div data-role="controlgroup" data-type="horizontal">
        <div style="font-weight: bold;">Date of Birth</div>
    

    These changes worked for me on my iPhone4, HTC One, and iPad (there is a whole lot more real estate on the iPad, so it was always going to work. But tested it there anyway).

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

Sidebar

Related Questions

i have been struggling getting this to work for 2 weeks, I am trying
I have been struggling with getting this to work for a number of days
I have been struggling quite a bit to get this JQgrid to work with
I have been struggling with Core Data sigh so I decided to work this
I have been struggling all afternoon trying to get a simple mailto: tag to
I've spent many hours trying to get this to work. And I'm getting quite
I've been struggling for several hours trying to figure out how to get this
Ok, so I've been trying to get my head around this, but I'm struggling.
I have been struggling with this all morning and was hoping to get some
I have been struggling with this for a while now. given a set of

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.