Does anyone know how to insert tags around an object that’s going to be inserted into the editor?
I’ve tried InsertHTML but it creates a closing tag right after the opening tag. Right now I’m using the following code in the Ok function of fck_image.js:
if (GetE('cmbAlign').value == "middle")
{
SetAttribute( oImage, "outerHTML" , "<p align=\"center\">" + oImage.outerHTML + "</p>" ) ;
}
It’s not pretty but it works in IE. Unfortunately it doesn’t work in Firefox. (it creates an attribute called outerHTML)
I'd basically like the code 'justifycenter' code that FCKEditor uses. I haven't found it yet though.
Any help would be appreciated.
Thanks,
M
I’ve tried InsertHTML but it creates a closing tag right after the opening tag. Right now I’m using the following code in the Ok function of fck_image.js:
if (GetE('cmbAlign').value == "middle")
{
SetAttribute( oImage, "outerHTML" , "<p align=\"center\">" + oImage.outerHTML + "</p>" ) ;
}
It’s not pretty but it works in IE. Unfortunately it doesn’t work in Firefox. (it creates an attribute called outerHTML)
I'd basically like the code 'justifycenter' code that FCKEditor uses. I haven't found it yet though.
Any help would be appreciated.
Thanks,
M