[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 90
  • Last Modified:

bootstrap table

I have a table and it has a scroll bar at the bottom (left to right). How can I get the scroll bar to show up at the top of the table as well?

<div class="table table-responsive">
<table width="500" class="table table-striped table-hover table-condensed">
..... long content that's why it needs to scroll at the top and bottom ...
</table>
</div>

Open in new window

0
Robert Saylor
Asked:
Robert Saylor
  • 3
  • 2
1 Solution
 
KarenAnalyst programmerCommented:
Hi Robert,
This is determined by a CSS property. It is hard to tell without knowing your full CSS but you could try something like

<div class="table table-responsive" style="overflow:auto">

Open in new window

0
 
Robert SaylorSenior DeveloperAuthor Commented:
thanks but the scroll bar is still at the bottom.

As far as CSS I am using:

bootstrap, font awsome, jquery
    <!-- Bootstrap Core CSS -->
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap3-dialog/1.35.3/css/bootstrap-dialog.css" rel="stylesheet">

    <!-- Custom Fonts -->
    <link href="font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css">

   <link rel="stylesheet" href="jquery-ui-1.10.3/themes/base/jquery.ui.all.css">

  <link rel="stylesheet" type="text/css" href="css/jquery.timepicker.css" />

Open in new window

0
 
KarenAnalyst programmerCommented:
oops sorry I misread the question.
There is a jquery plugin that does this for you:
https://github.com/avianey/jqDoubleScroll
0
 
Robert SaylorSenior DeveloperAuthor Commented:
I gave doubleScroll a try but the scroll bar still only shows on a bottom. Will mess with it some more tomorrow.
0
 
Robert SaylorSenior DeveloperAuthor Commented:
I messed with it some more and got it working.
0

Featured Post

Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now