Go Premium for a chance to win a PS4. Enter to Win

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

horizontal scroll bar <select> html tag strut

Hi,
How can i set up a horizontal scroll bar for <select> tag.
0
komlaaa
Asked:
komlaaa
  • 2
  • 2
1 Solution
 
komlaaaAuthor Commented:
to be more clearer,
when i say <select> tag, i meant something like:

<select .....>
      <options ....../>
</select>
0
 
colr__Commented:
The horizontal scroll bar will only appear if the horizontal area taken up by your <option> elements is bigger than the avaiable space of the <select>. There is no way to force a horizontal scrollbar in this html element, it just takes as much room as it needs. You can however, force the vertical size via the following:

<select size="5" >
      <option>sds fdgfd fd fd fdg</option>
      <option>sds dfg fdg fd</option>
      <option>sdsg fdg d</option>
</select>

colr__
0
 
komlaaaAuthor Commented:
>The horizontal scroll bar will only appear if the horizontal area taken up by your <option> elements is bigger than >the avaiable space of the <select>.
I am afraid, mine is not behaving like that.
0
 
colr__Commented:
You cannot force a horizontal scrollbar on an HTML select.

colr__
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

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