Last Comment Bug 301416 - Form doesn't show submit button: regression from 1.0.6 to DPalpha2
: Form doesn't show submit button: regression from 1.0.6 to DPalpha2
Status: RESOLVED FIXED
: regression, testcase
Product: Core
Classification: Components
Component: HTML: Parser (show other bugs)
: Trunk
: All All
-- major (vote)
: mozilla1.8beta4
Assigned To: Blake Kaplan (:mrbkap) (inactive, use needinfo)
: Blake Kaplan (:mrbkap) (inactive, use needinfo)
: Hsin-Yi Tsai [:hsinyi]
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-07-20 01:43 PDT by Olivier Cahagne
Modified: 2006-03-12 18:43 PST (History)
3 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Testcase (doesn't show submit button on Deer Park alpha 2) (318 bytes, text/html)
2005-07-20 01:46 PDT, Olivier Cahagne
no flags Details
Working testcase (removed <p> tag) (315 bytes, text/html)
2005-07-20 03:01 PDT, Olivier Cahagne
no flags Details
patch v1 (1.73 KB, patch)
2005-07-20 14:03 PDT, Blake Kaplan (:mrbkap) (inactive, use needinfo)
jst: review+
jst: superreview+
asa: approval1.8b4+
Details | Diff | Splinter Review

Description User image Olivier Cahagne 2005-07-20 01:43:59 PDT
Build ID: FF Deer Park Alpha 2, 20050712 on WinXP.

Steps to reproduce:
1. Load testcase with DPa2, no submit button shows up,
2. Load testcase with FF 1.0.6 or IE6, submit button shows up.

If I remove the <p>, the <textarea> or the <a> tag, the submit button shows up
in DPa2.
Comment 1 User image Olivier Cahagne 2005-07-20 01:46:59 PDT
Created attachment 189870 [details]
Testcase (doesn't show submit button on Deer Park alpha 2)
Comment 2 User image Olivier Cahagne 2005-07-20 03:01:03 PDT
Created attachment 189874 [details]
Working testcase (removed <p> tag)
Comment 3 User image Uri Bernstein (Google) 2005-07-20 03:25:39 PDT
This regressed between 2005-06-01-07 and 2005-06-02-07.
http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=all&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=explicit&mindate=2005-06-01+07%3A00&maxdate=2005-06-02+07%3A00&cvsroot=%2Fcvsroot
This seems to be an HTML parsing issue. unfortunately, the regression window
contains quite a few parser patches.
Comment 4 User image Olivier Cahagne 2005-07-20 11:31:50 PDT
Camino 0.9a2 is also (logically) affected.
Comment 5 User image Blake Kaplan (:mrbkap) (inactive, use needinfo) 2005-07-20 11:43:12 PDT
Taking, this looks like another bug resulting from the move away from skipped
content.
Comment 6 User image Blake Kaplan (:mrbkap) (inactive, use needinfo) 2005-07-20 14:03:10 PDT
Created attachment 189938 [details] [diff] [review]
patch v1

I'm not entirely sure why the <p> was needed here, but this patch is correct.
The problem is that the <a> is being closed by the <p> and reopened inside the
<textarea>, so we were ignoring the <textarea>'s end tag and putting the rest
of the document into the textarea. With this patch, we don't allow residual
styles to be opened inside the textarea and things are happy.
Comment 7 User image Johnny Stenback (:jst) 2005-07-20 14:21:06 PDT
Comment on attachment 189938 [details] [diff] [review]
patch v1

r+sr=jst
Comment 8 User image Blake Kaplan (:mrbkap) (inactive, use needinfo) 2005-07-20 14:42:06 PDT
Comment on attachment 189938 [details] [diff] [review]
patch v1

This patch is very safe and prevents a silly regression where textareas would
eat up the rest of the page if there were any residual style tags (such as <a>)
on the residual style stack.
Comment 9 User image Blake Kaplan (:mrbkap) (inactive, use needinfo) 2005-07-20 14:45:27 PDT
For the record: the <p> is necessary because <a> can contain <textarea>, so it
wasn't getting put on the residual style stack. I suspect if there was a space
or text before the <textarea>, this problem would have been masked. So the
reduced testcase is:
<a><p><textarea></textarea>hi
Comment 10 User image Blake Kaplan (:mrbkap) (inactive, use needinfo) 2005-07-20 19:57:12 PDT
Fix checked in. Thanks for finding this.

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