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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T18:58:19+00:00 2026-05-17T18:58:19+00:00

So this is sort of an exceptional case situation – I have a plugin

  • 0

So this is sort of an exceptional case situation – I have a plugin that I can’t modify for contractual reasons. It displays a set of drop downs and I need it to display a set of radio buttons instead. Is there a js/jquery method for converting dropdowns to radio buttons w/o changing the HTML. Remember, I can add stuff – I just can modify the plugin (and thus the HTML) directly.

I get that this is a bad way to do it, trust me I don’t like it any more than you do.

Possibly by detecting the values of the drop-down options and then reformatting them as radio buttons, hiding the original dropdown?

<form action="http://example.net/store/cart/" method="post" class="shopp product"> 
  <ul class="variations"> 
    <li> 
      <label for="options-1">Music Download</label> 
      <select name="products[117][options][]" class="category-catalog product117 options" id="options-1">
        <option value="">Select an option</option> 
        <option value="1">Full Album</option> 
        <option value="7">Theme</option> 
        <option value="8">Simian Segue  </option> 
        <option value="9">DK Island Swing</option> 
        <option value="10">Cranky's Theme</option> 
        <option value="11">Cave Dweller Concert</option> 
        <option value="12">Bonus Room Blitz</option> 
        <option value="13">Aquatic Ambiance</option> 
        <option value="14">Candy's Love Song</option> 
        <option value="15">Bad Boss Boogie</option> 
        <option value="16">Mine Cart Madness</option> 
        <option value="17">Life in the Mines</option> 
        <option value="18">Voices of the Temple </option> 
      </select>
    </li>       
  </ul> 

  <p> 
    <select name="products[117][quantity]" id="quantity-117">
      <option selected="selected" value="1">1</option><option value="2">2</option>
      <option value="3">3</option>
      <option value="4">4</option><option value="5">5</option>
      <option value="6">6</option><option value="7">7</option>
      <option value="8">8</option><option value="9">9</option>
      <option value="10">10</option><option value="11">11</option><option value="12">12</option>
      <option value="13">13</option><option value="14">14</option>
      <option value="15">15</option><option value="20">20</option>
      <option value="25">25</option>
      <option value="30">30</option><option value="40">40</option>
      <option value="50">50</option><option value="75">75</option>
      <option value="100">100</option>
    </select>

    <input type="hidden" name="products[117][product]" value="117" />
    <input type="hidden" name="products[117][category]" value="catalog" />
    <input type="hidden" name="cart" value="add" />
    <input type="submit" name="addtocart"  value="Add to Cart" class="addtocart" />
  </p> 

</form>
  • 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-05-17T18:58:20+00:00Added an answer on May 17, 2026 at 6:58 pm

    Hide the dropdown and place the new radio elements outside the form, they don’t need to post, just update the dropdown value.

    Here is a code example on jsFiddle.

    $("#d option").each(function(i, e) { // get the options
        $("<input type='radio' name='r' />") // create a radio element
            .attr("value", $(this).val()) // set the value
            .attr("checked", i == 0) // check the first by default
            .click(function () { // add event click which updates the dropdown
                $("#d").val($(this).val()); // update the dropdown if clicked
            })
            .appendTo("#r"); // append to some visible place
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a section of makefile that has this sort of structure: bob: ifdef
I have YAML data that looks sort of like this, but ~150k of it:
This is sort of SQL newbie question, I think, but here goes. I have
I have this big data-entry sort of page, a table kind of layout using
Trying to do this sort of thing... WHERE username LIKE '%$str%' ...but using bound
I've run across this sort of thing on multiple websites and was wondering what
How would you describe the running time of this sort, given a function sorted
This is sort of a follow-up to this question . If there are multiple
I am using this command: cut -d: -f2 To sort and reedit text, Is
I want to do something sort of like this: let x = 5 let

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.