How to set width on dropdown item in bootstrap?












0















I have to add a little dropdown to the right side of my navbar. Cause I'm new in Bootstrap I stuck on a preety simple problem.



My code:



<li class="nav-item dropdown">
<a href="#"
id="navbarDropdown"
data-toggle="dropdown"
aria-haspopup="true" aria-expanded="false"
class="nav-link dropdown-toggle">
some text
</a>
<div aria-labelledby="navbarDropdownLangMenu"
class="dropdown-menu">
<a class="dropdown-item">AA</a>
<a class="dropdown-item">BB</a>
</div>
</li>


Everythink work's fine, except a width of a elements. Every link has only two characters, but the width of them is very large and it goes beyond the width of the screen:



enter image description here



I'm trying set a width value to a elements, add new css class which set the width, but nothing I tried works.










share|improve this question



























    0















    I have to add a little dropdown to the right side of my navbar. Cause I'm new in Bootstrap I stuck on a preety simple problem.



    My code:



    <li class="nav-item dropdown">
    <a href="#"
    id="navbarDropdown"
    data-toggle="dropdown"
    aria-haspopup="true" aria-expanded="false"
    class="nav-link dropdown-toggle">
    some text
    </a>
    <div aria-labelledby="navbarDropdownLangMenu"
    class="dropdown-menu">
    <a class="dropdown-item">AA</a>
    <a class="dropdown-item">BB</a>
    </div>
    </li>


    Everythink work's fine, except a width of a elements. Every link has only two characters, but the width of them is very large and it goes beyond the width of the screen:



    enter image description here



    I'm trying set a width value to a elements, add new css class which set the width, but nothing I tried works.










    share|improve this question

























      0












      0








      0








      I have to add a little dropdown to the right side of my navbar. Cause I'm new in Bootstrap I stuck on a preety simple problem.



      My code:



      <li class="nav-item dropdown">
      <a href="#"
      id="navbarDropdown"
      data-toggle="dropdown"
      aria-haspopup="true" aria-expanded="false"
      class="nav-link dropdown-toggle">
      some text
      </a>
      <div aria-labelledby="navbarDropdownLangMenu"
      class="dropdown-menu">
      <a class="dropdown-item">AA</a>
      <a class="dropdown-item">BB</a>
      </div>
      </li>


      Everythink work's fine, except a width of a elements. Every link has only two characters, but the width of them is very large and it goes beyond the width of the screen:



      enter image description here



      I'm trying set a width value to a elements, add new css class which set the width, but nothing I tried works.










      share|improve this question














      I have to add a little dropdown to the right side of my navbar. Cause I'm new in Bootstrap I stuck on a preety simple problem.



      My code:



      <li class="nav-item dropdown">
      <a href="#"
      id="navbarDropdown"
      data-toggle="dropdown"
      aria-haspopup="true" aria-expanded="false"
      class="nav-link dropdown-toggle">
      some text
      </a>
      <div aria-labelledby="navbarDropdownLangMenu"
      class="dropdown-menu">
      <a class="dropdown-item">AA</a>
      <a class="dropdown-item">BB</a>
      </div>
      </li>


      Everythink work's fine, except a width of a elements. Every link has only two characters, but the width of them is very large and it goes beyond the width of the screen:



      enter image description here



      I'm trying set a width value to a elements, add new css class which set the width, but nothing I tried works.







      css twitter-bootstrap






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Nov 14 '18 at 10:09









      sosicksosick

      1027




      1027
























          3 Answers
          3






          active

          oldest

          votes


















          1














          There is a min-width on the dropdown menu in bootstrap.
          You can reset it like this:



          .dropdown-menu {
          min-width:inherit;
          }





          share|improve this answer
























          • Thank you! It Works.

            – sosick
            Nov 14 '18 at 10:20



















          0














          Try this:






          .navbar .dropdown-menu.show {
          min-width: inherit;
          display: inline-block;
          }

          <link href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" rel="stylesheet"/>
          <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
          <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js" integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49" crossorigin="anonymous"></script>
          <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script>
          <nav class="navbar navbar-expand-lg navbar-light bg-light">
          <a class="navbar-brand" href="#">Navbar</a>
          <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
          <span class="navbar-toggler-icon"></span>
          </button>

          <div class="collapse navbar-collapse" id="navbarSupportedContent">
          <ul class="navbar-nav mr-auto">
          <li class="nav-item active">
          <a class="nav-link" href="#">Home <span class="sr-only">(current)</span></a>
          </li>
          <li class="nav-item dropdown">
          <a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
          Dropdown
          </a>
          <div class="dropdown-menu" aria-labelledby="navbarDropdown">
          <a class="dropdown-item">AA</a>
          <a class="dropdown-item">BB</a>
          </div>
          </li>
          </ul>
          </div>
          </nav>








          share|improve this answer































            -1














            <div class="dropdown">
            <button class="btn btn-primary dropdown-toggle" type="button"
            data-toggle="dropdown">Dropdown Example
            <span class="caret"></span>
            </button>
            <ul class="dropdown-menu">
            <li><a href="#">HTML</a></li>
            <li><a href="#">CSS</a></li>
            <li><a href="#">JavaScript</a></li>
            </ul>
            </div>





            share|improve this answer























              Your Answer






              StackExchange.ifUsing("editor", function () {
              StackExchange.using("externalEditor", function () {
              StackExchange.using("snippets", function () {
              StackExchange.snippets.init();
              });
              });
              }, "code-snippets");

              StackExchange.ready(function() {
              var channelOptions = {
              tags: "".split(" "),
              id: "1"
              };
              initTagRenderer("".split(" "), "".split(" "), channelOptions);

              StackExchange.using("externalEditor", function() {
              // Have to fire editor after snippets, if snippets enabled
              if (StackExchange.settings.snippets.snippetsEnabled) {
              StackExchange.using("snippets", function() {
              createEditor();
              });
              }
              else {
              createEditor();
              }
              });

              function createEditor() {
              StackExchange.prepareEditor({
              heartbeatType: 'answer',
              autoActivateHeartbeat: false,
              convertImagesToLinks: true,
              noModals: true,
              showLowRepImageUploadWarning: true,
              reputationToPostImages: 10,
              bindNavPrevention: true,
              postfix: "",
              imageUploader: {
              brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
              contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
              allowUrls: true
              },
              onDemand: true,
              discardSelector: ".discard-answer"
              ,immediatelyShowMarkdownHelp:true
              });


              }
              });














              draft saved

              draft discarded


















              StackExchange.ready(
              function () {
              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53297638%2fhow-to-set-width-on-dropdown-item-in-bootstrap%23new-answer', 'question_page');
              }
              );

              Post as a guest















              Required, but never shown

























              3 Answers
              3






              active

              oldest

              votes








              3 Answers
              3






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes









              1














              There is a min-width on the dropdown menu in bootstrap.
              You can reset it like this:



              .dropdown-menu {
              min-width:inherit;
              }





              share|improve this answer
























              • Thank you! It Works.

                – sosick
                Nov 14 '18 at 10:20
















              1














              There is a min-width on the dropdown menu in bootstrap.
              You can reset it like this:



              .dropdown-menu {
              min-width:inherit;
              }





              share|improve this answer
























              • Thank you! It Works.

                – sosick
                Nov 14 '18 at 10:20














              1












              1








              1







              There is a min-width on the dropdown menu in bootstrap.
              You can reset it like this:



              .dropdown-menu {
              min-width:inherit;
              }





              share|improve this answer













              There is a min-width on the dropdown menu in bootstrap.
              You can reset it like this:



              .dropdown-menu {
              min-width:inherit;
              }






              share|improve this answer












              share|improve this answer



              share|improve this answer










              answered Nov 14 '18 at 10:18









              WimanicesirWimanicesir

              449110




              449110













              • Thank you! It Works.

                – sosick
                Nov 14 '18 at 10:20



















              • Thank you! It Works.

                – sosick
                Nov 14 '18 at 10:20

















              Thank you! It Works.

              – sosick
              Nov 14 '18 at 10:20





              Thank you! It Works.

              – sosick
              Nov 14 '18 at 10:20













              0














              Try this:






              .navbar .dropdown-menu.show {
              min-width: inherit;
              display: inline-block;
              }

              <link href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" rel="stylesheet"/>
              <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
              <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js" integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49" crossorigin="anonymous"></script>
              <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script>
              <nav class="navbar navbar-expand-lg navbar-light bg-light">
              <a class="navbar-brand" href="#">Navbar</a>
              <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
              <span class="navbar-toggler-icon"></span>
              </button>

              <div class="collapse navbar-collapse" id="navbarSupportedContent">
              <ul class="navbar-nav mr-auto">
              <li class="nav-item active">
              <a class="nav-link" href="#">Home <span class="sr-only">(current)</span></a>
              </li>
              <li class="nav-item dropdown">
              <a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
              Dropdown
              </a>
              <div class="dropdown-menu" aria-labelledby="navbarDropdown">
              <a class="dropdown-item">AA</a>
              <a class="dropdown-item">BB</a>
              </div>
              </li>
              </ul>
              </div>
              </nav>








              share|improve this answer




























                0














                Try this:






                .navbar .dropdown-menu.show {
                min-width: inherit;
                display: inline-block;
                }

                <link href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" rel="stylesheet"/>
                <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
                <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js" integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49" crossorigin="anonymous"></script>
                <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script>
                <nav class="navbar navbar-expand-lg navbar-light bg-light">
                <a class="navbar-brand" href="#">Navbar</a>
                <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
                <span class="navbar-toggler-icon"></span>
                </button>

                <div class="collapse navbar-collapse" id="navbarSupportedContent">
                <ul class="navbar-nav mr-auto">
                <li class="nav-item active">
                <a class="nav-link" href="#">Home <span class="sr-only">(current)</span></a>
                </li>
                <li class="nav-item dropdown">
                <a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                Dropdown
                </a>
                <div class="dropdown-menu" aria-labelledby="navbarDropdown">
                <a class="dropdown-item">AA</a>
                <a class="dropdown-item">BB</a>
                </div>
                </li>
                </ul>
                </div>
                </nav>








                share|improve this answer


























                  0












                  0








                  0







                  Try this:






                  .navbar .dropdown-menu.show {
                  min-width: inherit;
                  display: inline-block;
                  }

                  <link href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" rel="stylesheet"/>
                  <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
                  <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js" integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49" crossorigin="anonymous"></script>
                  <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script>
                  <nav class="navbar navbar-expand-lg navbar-light bg-light">
                  <a class="navbar-brand" href="#">Navbar</a>
                  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
                  <span class="navbar-toggler-icon"></span>
                  </button>

                  <div class="collapse navbar-collapse" id="navbarSupportedContent">
                  <ul class="navbar-nav mr-auto">
                  <li class="nav-item active">
                  <a class="nav-link" href="#">Home <span class="sr-only">(current)</span></a>
                  </li>
                  <li class="nav-item dropdown">
                  <a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                  Dropdown
                  </a>
                  <div class="dropdown-menu" aria-labelledby="navbarDropdown">
                  <a class="dropdown-item">AA</a>
                  <a class="dropdown-item">BB</a>
                  </div>
                  </li>
                  </ul>
                  </div>
                  </nav>








                  share|improve this answer













                  Try this:






                  .navbar .dropdown-menu.show {
                  min-width: inherit;
                  display: inline-block;
                  }

                  <link href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" rel="stylesheet"/>
                  <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
                  <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js" integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49" crossorigin="anonymous"></script>
                  <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script>
                  <nav class="navbar navbar-expand-lg navbar-light bg-light">
                  <a class="navbar-brand" href="#">Navbar</a>
                  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
                  <span class="navbar-toggler-icon"></span>
                  </button>

                  <div class="collapse navbar-collapse" id="navbarSupportedContent">
                  <ul class="navbar-nav mr-auto">
                  <li class="nav-item active">
                  <a class="nav-link" href="#">Home <span class="sr-only">(current)</span></a>
                  </li>
                  <li class="nav-item dropdown">
                  <a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                  Dropdown
                  </a>
                  <div class="dropdown-menu" aria-labelledby="navbarDropdown">
                  <a class="dropdown-item">AA</a>
                  <a class="dropdown-item">BB</a>
                  </div>
                  </li>
                  </ul>
                  </div>
                  </nav>








                  .navbar .dropdown-menu.show {
                  min-width: inherit;
                  display: inline-block;
                  }

                  <link href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" rel="stylesheet"/>
                  <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
                  <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js" integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49" crossorigin="anonymous"></script>
                  <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script>
                  <nav class="navbar navbar-expand-lg navbar-light bg-light">
                  <a class="navbar-brand" href="#">Navbar</a>
                  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
                  <span class="navbar-toggler-icon"></span>
                  </button>

                  <div class="collapse navbar-collapse" id="navbarSupportedContent">
                  <ul class="navbar-nav mr-auto">
                  <li class="nav-item active">
                  <a class="nav-link" href="#">Home <span class="sr-only">(current)</span></a>
                  </li>
                  <li class="nav-item dropdown">
                  <a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                  Dropdown
                  </a>
                  <div class="dropdown-menu" aria-labelledby="navbarDropdown">
                  <a class="dropdown-item">AA</a>
                  <a class="dropdown-item">BB</a>
                  </div>
                  </li>
                  </ul>
                  </div>
                  </nav>





                  .navbar .dropdown-menu.show {
                  min-width: inherit;
                  display: inline-block;
                  }

                  <link href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" rel="stylesheet"/>
                  <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
                  <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js" integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49" crossorigin="anonymous"></script>
                  <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script>
                  <nav class="navbar navbar-expand-lg navbar-light bg-light">
                  <a class="navbar-brand" href="#">Navbar</a>
                  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
                  <span class="navbar-toggler-icon"></span>
                  </button>

                  <div class="collapse navbar-collapse" id="navbarSupportedContent">
                  <ul class="navbar-nav mr-auto">
                  <li class="nav-item active">
                  <a class="nav-link" href="#">Home <span class="sr-only">(current)</span></a>
                  </li>
                  <li class="nav-item dropdown">
                  <a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                  Dropdown
                  </a>
                  <div class="dropdown-menu" aria-labelledby="navbarDropdown">
                  <a class="dropdown-item">AA</a>
                  <a class="dropdown-item">BB</a>
                  </div>
                  </li>
                  </ul>
                  </div>
                  </nav>






                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Nov 14 '18 at 10:19









                  Manish PatelManish Patel

                  3,2591721




                  3,2591721























                      -1














                      <div class="dropdown">
                      <button class="btn btn-primary dropdown-toggle" type="button"
                      data-toggle="dropdown">Dropdown Example
                      <span class="caret"></span>
                      </button>
                      <ul class="dropdown-menu">
                      <li><a href="#">HTML</a></li>
                      <li><a href="#">CSS</a></li>
                      <li><a href="#">JavaScript</a></li>
                      </ul>
                      </div>





                      share|improve this answer




























                        -1














                        <div class="dropdown">
                        <button class="btn btn-primary dropdown-toggle" type="button"
                        data-toggle="dropdown">Dropdown Example
                        <span class="caret"></span>
                        </button>
                        <ul class="dropdown-menu">
                        <li><a href="#">HTML</a></li>
                        <li><a href="#">CSS</a></li>
                        <li><a href="#">JavaScript</a></li>
                        </ul>
                        </div>





                        share|improve this answer


























                          -1












                          -1








                          -1







                          <div class="dropdown">
                          <button class="btn btn-primary dropdown-toggle" type="button"
                          data-toggle="dropdown">Dropdown Example
                          <span class="caret"></span>
                          </button>
                          <ul class="dropdown-menu">
                          <li><a href="#">HTML</a></li>
                          <li><a href="#">CSS</a></li>
                          <li><a href="#">JavaScript</a></li>
                          </ul>
                          </div>





                          share|improve this answer













                          <div class="dropdown">
                          <button class="btn btn-primary dropdown-toggle" type="button"
                          data-toggle="dropdown">Dropdown Example
                          <span class="caret"></span>
                          </button>
                          <ul class="dropdown-menu">
                          <li><a href="#">HTML</a></li>
                          <li><a href="#">CSS</a></li>
                          <li><a href="#">JavaScript</a></li>
                          </ul>
                          </div>






                          share|improve this answer












                          share|improve this answer



                          share|improve this answer










                          answered Nov 14 '18 at 10:14









                          Riyal SavajRiyal Savaj

                          8113




                          8113






























                              draft saved

                              draft discarded




















































                              Thanks for contributing an answer to Stack Overflow!


                              • Please be sure to answer the question. Provide details and share your research!

                              But avoid



                              • Asking for help, clarification, or responding to other answers.

                              • Making statements based on opinion; back them up with references or personal experience.


                              To learn more, see our tips on writing great answers.




                              draft saved


                              draft discarded














                              StackExchange.ready(
                              function () {
                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53297638%2fhow-to-set-width-on-dropdown-item-in-bootstrap%23new-answer', 'question_page');
                              }
                              );

                              Post as a guest















                              Required, but never shown





















































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown

































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown







                              Popular posts from this blog

                              Bressuire

                              Vorschmack

                              Quarantine