Menu

#11 application/xhtml+xml support

open
nobody
None
5
2007-04-04
2007-04-04
rvallee
No

Current version does not support application/xhtml+xml content type because of the use of document.write, which is not valid in an XML DOM.

I replaced the document.write code for the following equivalent XHTML DOM valid code:

// BEGIN CODE
var smartInputFloater = document.createElement("table");
smartInputFloater.id = "smartInputFloater";
smartInputFloater.className = "floater";
smartInputFloater.setAttribute("cellpadding", "0");
smartInputFloater.setAttribute("cellspacing", "0");

var smartInputFloaterRow = document.createElement("tr");
var smartInputFloaterCell = document.createElement("td");

smartInputFloaterCell.id = "smartInputFloaterContent";
smartInputFloaterCell.setAttribute("nowrap", "nowrap");
smartInputFloaterRow.appendChild(smartInputFloaterCell);

smartInputFloater.appendChild(smartInputFloaterRow);
// END CODE

As weird as it sounds, it is neither necessary nor useful to write the table element to the page as the script still works and doing so crashes IE6 page loading, at least in my environment.

Discussion


Log in to post a comment.