4 Replies - 454 Views - Last Post: 02 May 2020 - 08:12 AM

#1 Geostorm   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 1
  • Joined: 30-April 19

I want to align my search box to the right side(TOP CORNER)

Posted 30 April 2019 - 02:27 AM

CSS :

 .nav-side-menu
        {
            overflow: auto;
            font-family: verdana;
            font-size: 12px;
            font-weight: 200;
            background-color: #fff;
            position: fixed;
            top: 0px;
            width: 250px;
            height: 100%;
            color: #000;
            margin-top: 100px;
        }


Code:

<div class="nav-side-menu">
                <i class="fa fa-bars fa-2x toggle-btn" data-toggle="collapse" data-target="#menu-content">
                </i>
                <div class="menu-list">
                    <ul id="menu-content" class="menu-content collapse out">
                    <li class="sidebar-search">
                            <div class="input-group ">
                                <input class="form-control" id="txtSearch" type="text"  runat="server"  placeholder="Search App/User..."/>
                                <span class="input-group-btn">
                                <asp:Button class="btn btn-default" runat="server" Text="Go" ID="btnGo" 
                                    onclick="btnGo_Click" />
                            </span>
                            </div>

This post has been edited by andrewsw: 30 April 2019 - 03:07 AM
Reason for edit:: added missing [code][/code] tags


Is This A Good Question/Topic? 0
  • +

Replies To: I want to align my search box to the right side(TOP CORNER)

#2 andrewsw   User is online

  • palpable absurdity
  • member icon

Reputation: 6901
  • View blog
  • Posts: 28,559
  • Joined: 12-December 12

Re: I want to align my search box to the right side(TOP CORNER)

Posted 30 April 2019 - 03:08 AM

Please wrap code in code tags, I have added them for you on this occasion.
Was This Post Helpful? 0
  • +
  • -

#3 ishan.shah   User is offline

  • New D.I.C Head

Reputation: 3
  • View blog
  • Posts: 43
  • Joined: 28-March 19

Re: I want to align my search box to the right side(TOP CORNER)

Posted 19 March 2020 - 09:31 PM

You can refer following code :

#txtSearch
{
position :absolute;
right:1%;
}
Was This Post Helpful? 0
  • +
  • -

#4 Pogaca   User is offline

  • D.I.C Head

Reputation: 7
  • View blog
  • Posts: 171
  • Joined: 24-August 13

Re: I want to align my search box to the right side(TOP CORNER)

Posted 20 March 2020 - 03:09 AM

Since I see you are using Bootstrap. Why not use this class:
float-right

Or
float-{sm,md,lg,xl}-{left,right,none}

Was This Post Helpful? 0
  • +
  • -

#5 danchy22   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 29
  • Joined: 27-April 20

Re: I want to align my search box to the right side(TOP CORNER)

Posted 02 May 2020 - 08:12 AM

in this situation if i am lazy (which i dont think anyone should be) i tend to add "margin-left:80%;" and do it that way...
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1