开发者

Prevent absolutely-positioned elements from overlapping with text

开发者 https://www.devze.com 2023-03-12 09:45 出处:网络
I have a unique situation here. Essentially, I have an absolutely positioned block of text, which must be absolutely positioned due to design limitations.

I have a unique situation here.

Essentially, I have an absolutely positioned block of text, which must be absolutely positioned due to design limitations.

I also have the rest of my text, which is normally positioned. However, I need to prevent my normal text from overlapping with my origina开发者_如何学Gol text.

Is this possible simply with HTML and inline CSS? I do not have access to JavaScript or external/head-related CSS; only inline styles are available. I have created a simplified version of my CSS with this jsFiddle.


Is a solution to create another div (div2) that overlaps the absolutely positioned div (div1), but is itself invisible? Then the rest of the text would avoid overlapping div2...

Sketched this out here: http://jsfiddle.net/VKYwD/8/

Not entirely clear on what your constraints are though.

0

精彩评论

暂无评论...
验证码 换一张
取 消