wood burning stoves 2.0*
The moose likes HTML, CSS and JavaScript and the fly likes need to place a img element right after a select element, how? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "need to place a img element right after a select element, how? " Watch "need to place a img element right after a select element, how? " New topic
Author

need to place a img element right after a select element, how?

Chrix Wu
Ranch Hand

Joined: Nov 15, 2009
Posts: 121
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

</head>
<body>

<div style="width:100px; overflow:hidden; border-right:1px">
<select>
<option>[select]</option>
</select>
</div>


<div>
<img rc="dropDownArrow.png"/>
</div>

</body>
</html>


attached is what the elements look like using above code,

What I want to achieve is: the img element must be on the right side of the drop down list

I tried to modify the css in various different way, but it does not work,

can anyone suggest what i should do??


...


[Thumbnail for before.png]



** SCJP 5.0 84% **
** SCWCD 1.5 76% **
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61437
    
  67

If you want them next to each other, why are they in separate <div> elements? By default, <div> elements are block elements that will each span their container.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
Consider Paul's rocket mass heater.
 
subject: need to place a img element right after a select element, how?