Bug 12246

Summary: FCKeditor: Hidden fields doesn't show up
Product: WebKit Reporter: webkit
Component: Layout and RenderingAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal    
Priority: P2    
Version: 420+   
Hardware: Mac   
OS: OS X 10.4   
URL: http://www.fckeditor.net/nightly/browsers_test.html
Bug Depends on:    
Bug Blocks: 9915    

Description webkit 2007-01-13 03:10:29 PST
Hidden fields defined inside the editor, inserted with the appropriate toolbar button, are not being displayed. They are being correctly inserted in the code instead.

A icon should be shown instead, just like in Firefox.
Comment 1 Justin Garcia 2007-03-09 14:19:10 PST
ATM I can't figure out how the hidden field is inserted, there's no execCommand performed, and no queryCommandSupported/Enabled called.  The hidden field must be in the DOM, because it shows up when you use the Source ... toolbar button, but I can't know for sure because I can't inspect the DOM of the editable subframe (the editable subframe has a custom contextual menu that doesn't include Inspect Element).
Comment 2 webkit 2007-03-10 03:15:37 PST
The hidden field "magic" is simply done with CSS:

----

input[type="hidden"]
{
	display: inline;
	width:20px;
	height:20px;
	border:1px dotted #FF0000 ;
	background-image: url(http://www.fckeditor.net/fckeditor/editor/css/behaviors/hiddenfield.gif);
	background-repeat: no-repeat;
}

input[type="hidden"]:after
{
	padding-left: 20px;
	content: "" ;
}

----

I've tried the above definitions with <span> and it worked well. So, I believe that the CSS selectors are working properly.

Probably the buggy thing here is "display:inline". Maybe WebKit is just saying "hidden is hidden", and doesn't do any work to possibly display those kings of elements. I really don't know, it is just a guess. If this is true, we could open    a dedicated ticket for it.

I think I'll be able to make changes in the editor to not use CSS for it. I'll work on it now. I'll come with more news soon.
Comment 3 webkit 2007-03-10 05:29:00 PST
Ok, I was able to fix it in the editor code. It doesn't anymore uses styles to display hidden fields, which are now replaced with an image during editing.

Reference:
http://dev.fckeditor.net/changeset/202