Bug #20268 » rtehtmlarea_bugfix_10834_typo3_4-2.patch
typo3/sysext/rtehtmlarea/htmlarea/htmlarea.js (copie de travail) | ||
---|---|---|
if (cls[--i] != removeClassName) ar[ar.length] = cls[i];
|
||
}
|
||
if (ar.length == 0) {
|
||
if (!HTMLArea.is_opera) el.removeAttribute(HTMLArea.is_gecko ? "class" : "className");
|
||
else el.className = '';
|
||
if (!HTMLArea.is_opera) {
|
||
el.removeAttribute("class");
|
||
if (HTMLArea.is_ie) {
|
||
el.removeAttribute("className");
|
||
}
|
||
} else {
|
||
el.className = '';
|
||
}
|
||
} else el.className = ar.join(" ");
|
||
};
|
||
typo3/sysext/rtehtmlarea/htmlarea/plugins/BlockElements/block-elements.js (copie de travail) | ||
---|---|---|
}
|
||
}
|
||
}
|
||
this.allowedAttributes = new Array("id", "title", "lang", "xml:lang", "dir", (HTMLArea.is_gecko?"class":"className"));
|
||
this.allowedAttributes = new Array("id", "title", "lang", "xml:lang", "dir", "class");
|
||
if (HTMLArea.is_ie) {
|
||
this.allowedAttributes.push("className");
|
||
}
|
||
this.indentedList = null;
|
||
|
||
/*
|
typo3/sysext/rtehtmlarea/htmlarea/plugins/InlineElements/inline-elements.js (copie de travail) | ||
---|---|---|
* This function gets called by the base constructor
|
||
*/
|
||
configurePlugin : function (editor) {
|
||
|
||
this.allowedAttributes = new Array("id", "title", "lang", "xml:lang", "dir", (HTMLArea.is_gecko?"class":"className"));
|
||
|
||
this.allowedAttributes = new Array("id", "title", "lang", "xml:lang", "dir", "class");
|
||
if (HTMLArea.is_ie) {
|
||
this.allowedAttributes.push("className");
|
||
}
|
||
if (this.editorConfiguration.buttons.textstyle) {
|
||
this.tags = this.editorConfiguration.buttons.textstyle.tags;
|
||
}
|
||
... | ... | |
newElement.setAttribute(this.allowedAttributes[i], attributeValue);
|
||
}
|
||
}
|
||
|
||
// In IE, the above fails to update the class and style attributes.
|
||
if (HTMLArea.is_ie) {
|
||
if (element.style.cssText) {
|
||
newElement.style.cssText = element.style.cssText;
|
||
}
|
||
if (element.className) {
|
||
newElement.setAttribute("class", element.className);
|
||
if (!newElement.className) {
|
||
// IE before IE8
|
||
newElement.setAttribute("className", element.className);
|
||
}
|
||
} else {
|
||
newElement.removeAttribute("class");
|
||
// IE before IE8
|
||
newElement.removeAttribute("className");
|
||
}
|
||
}
|
||
if (this.tags && this.tags[tagName] && this.tags[tagName].allowedClasses) {
|
||
if (newElement.className && /\S/.test(newElement.className)) {
|
||
var allowedClasses = this.tags[tagName].allowedClasses;
|
typo3/sysext/rtehtmlarea/htmlarea/plugins/TableOperations/table-operations.js (copie de travail) | ||
---|---|---|
newCell.style.cssText = element.style.cssText;
|
||
}
|
||
if (element.className) {
|
||
newCell.setAttribute("className", element.className);
|
||
newCell.setAttribute("class", element.className);
|
||
if (!newCell.className) {
|
||
// IE before IE8
|
||
newCell.setAttribute("className", element.className);
|
||
}
|
||
} else {
|
||
newCell.removeAttribute("class");
|
||
// IE before IE8
|
||
newCell.removeAttribute("className");
|
||
}
|
||
}
|
||
|
||
if (this.tags && this.tags[nodeName] && this.tags[nodeName].allowedClasses) {
|
||
if (newCell.className && /\S/.test(newCell.className)) {
|
||
var allowedClasses = this.tags[nodeName].allowedClasses;
|