Opened 12 years ago

Closed 12 years ago

#7819 closed bug (notabug)

positon() does not work when div contains multiple spans

Reported by: JVerstry Owned by:
Priority: minor Milestone: 1.9.0
Component: ui.position Version: 1.8.16
Keywords: Cc:
Blocked by: Blocking:


Following a question I asked on StackOverflow (, it seems like there is a bug in the position() method when trying to position a div containing spans, within another div.

If each spans is not followed by a <br /> (except for the last one), the position() method does not work. There is no error message thrown by FireBug and I a could not find any documentation related to this. Setting a value for collision does not help.

The SO question contains screenshots and code samples.

Change History (3)

comment:1 Changed 12 years ago by JVerstry

I have create a code example at:

In this example, even if I add a <br /> after each span, it does not solve the issue.

comment:2 Changed 12 years ago by JVerstry

After discussions in the SO question, someone found out that the enclosing div MUST have an explicit height or width. This is not mentioned in the documentation.

comment:3 Changed 12 years ago by Scott González

Component: ui.coreui.position
Resolution: invalid
Status: newclosed

That's because your elements are all floated, so they don't have the dimensions that you think they have.

Note: See TracTickets for help on using tickets.