Last modified: 2010-05-15 15:51:39 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T9713, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 7713 - h1 Tag causes saved page to have missing data (section editing)
h1 Tag causes saved page to have missing data (section editing)
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Page editing (Other open bugs)
1.10.x
Other Linux
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on: 12652
Blocks: 4899 11960
  Show dependency treegraph
 
Reported: 2006-10-25 22:46 UTC by bjkcubed
Modified: 2010-05-15 15:51 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description bjkcubed 2006-10-25 22:46:10 UTC
It seems using the h1 tag in a wiki page causes issues with editing sections.  These results are not seen with 1.6.8 but are seen with 
1.7 and 1.8.

Start out with:
==Heading 1==

<pre>
<h1>test</h1>
</pre>
==Heading 2==

If you click on Heading 2 to edit that section and then save that page you will get the result below.

==Heading 1==

<pre>
==Heading 2==
asdf

In the example above I added the asdf when editing the second section, as you see data is lost.  Editing section 1 creates even more 
strange results.  Starting with the first example and editing section 1 I get the following output.

==Heading 1==
asdf
<pre>
<h1>test</h1>
</pre>

<h1>test</h1>
</pre>
==Heading 2==
Comment 1 bjkcubed 2006-10-25 22:48:20 UTC
More server information...

MediaWiki: 1.8.2
PHP: 5.1.6 (apache2handler)
MySQL: 5.0.24a-standard
Comment 2 bjkcubed 2007-01-19 22:30:03 UTC
Bug still remains in version 1.9

MediaWiki: 1.9.0
PHP: 5.1.6 (apache2handler)
MySQL: 5.0.24a-standard-log
Comment 3 Alan Harder 2007-02-22 17:47:59 UTC
I also hit this problem (in version 1.9.2 and 1.9.3) but with h2 tags inside a pre.

It seems that code generating the section [edit] links properly skips over the
h2-inside-pre since it is rendered with the < and > encoded as html entities. 
However, the code saving the changes probably sees the raw text and counts this
as a section boundary, thus saving and overwriting the wrong section!
Comment 4 Brion Vibber 2007-02-23 06:39:09 UTC
Can confirm with 1.9, but seems fine on 1.10 w/ current trunk.
Comment 5 Thomas Hempel 2007-05-02 16:31:20 UTC
This is still an open issue with 1.10. All you need is a page with multiple
sections, some of which contain <pre> areas. Then go to a section right after
one with a <pre> tag in it, edit it, and add a new section, thus splitting the
section in half. When you save it is almost always corrupted. Just tried this
with 1.10RC1.
 
Comment 6 Thomas Hempel 2007-05-02 16:32:00 UTC
This is still an open issue with 1.10. All you need is a page with multiple
sections, some of which contain <pre> areas. Then go to a section right after
one with a <pre> tag in it, edit it, and add a new section, thus splitting the
section in half. When you save it is almost always corrupted. Just tried this
with 1.10RC1.
 
Comment 7 bjkcubed 2007-05-04 20:43:30 UTC
Just to confirm that the original example still has the same result on 1.10.0rc1.
Comment 8 Robert Leverington 2007-05-07 12:33:58 UTC
I have tested with MediaWiki 1.5 through to trunk and can verify that it happens
in all versions of MediaWiki higher than or equal to 1.7 (including trunk) - see
http://www.wikitest.co.uk/1_6/Header_test,
http://www.wikitest.co.uk/1_7/Header_test and
http://www.wikitest.co.uk/SVN/Header_test

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links