{ib}layout problem with innerHTML and tags with different horizontal size (e.g. h1)

RESOLVED WORKSFORME

Status

()

RESOLVED WORKSFORME
14 years ago
3 years ago

People

(Reporter: twist, Unassigned)

Tracking

({testcase})

Trunk
x86
All
testcase
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

14 years ago
User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.8) Gecko/20050515 Firefox/1.0.4
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.8) Gecko/20050515 Firefox/1.0.4

watch the position of button A and B. push button A and then button B. the
position of the buttons should be restored, but isn´t.



<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN"
"http://www.w3.org/TR/html4/frameset.dtd">
<html>
<head>
</head>

<script type="text/javascript">

function a() {
	document.getElementById('status').innerHTML = '<h1>test</h1>';
}

function b() {
	document.getElementById('status').innerHTML = 'hello world';
}

</script>

<body>

	<span id="status">hallo world</span>
	<br />
	<input type="button" value="A" onclick="javascript:a();" />
	<input type="button" value="B" onclick="javascript:b();" />

</body>

</html>

Reproducible: Always

Steps to Reproduce:




this happens in mozilla Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.8)
Gecko/20050515 too. opera and konqueror is working correctly.

Updated

14 years ago
Component: General → Layout
Keywords: testcase
OS: Linux → All
Product: Firefox → Core
QA Contact: general → layout
Version: unspecified → Trunk

Comment 1

14 years ago
Created attachment 185355 [details]
Reporters testcase

See this on trunk too. Tested to change the span element to a div, since the
scripts insert a h1 into the span. But then the issue was not visible anymore.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Summary: layout problem with innerHTML and tags with different horizontal size (e.g. h1) → {ib}layout problem with innerHTML and tags with different horizontal size (e.g. h1)

Comment 2

14 years ago
This WFM with a current 1.5 branch build (on Linux).
I'm still seeing a problem with the testcase in current trunk build.
After clicking button "b", the <br> element should be next to the <span>, but
isn't, it's under it. That's why the buttons are still too low after clicking
button "b".

Comment 4

14 years ago
Oh, I see what you mean... it's about restoring to the initial position after
page loading, not the position after pressing B. Sorry for the confusion.

Comment 5

3 years ago
Looking at how old is the bug and as I was unable to reproduce it, I'm closing as WFM.
Feel free to reopen it if needed.
Status: NEW → RESOLVED
Last Resolved: 3 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.