Menu
I use the function below to view HTML source code in the WYSIWYG editor I’m putting together . But if the web page has a dark background image, I can’t read the HTML because the image appears as background to the source code!
I tried tacking (background=’hidden’) onto the innerText statement, but it doesn’t work.
Any ideas to get around this weird problem?
function doToggleView()
{
if(viewMode == 1)
{
iHTML = iView.document.body.innerHTML;
iView.document.body.innerText = iHTML;
viewMode = 2; // Code
}
else
{
iText = iView.document.body.innerText;
iView.document.body.innerHTML = iText;
viewMode = 1; // WYSIWYG
}
}