I think I found one more issue
if (action == "spoiler") {
var thisSpoiler = prompt("Enter Spoiler Data", "Spoiler Text");
if (thisVideo == null){return;}
insertAtCaret(document.replier.Body, ' ' + "" + ' ' );
document.replier.texteditor.focus();
return;
}
should read
if (action == "spoiler") {
var thisSpoiler = prompt("Enter Spoiler Data", "Spoiler Text");
if (thisSpoiler == null){return;}
insertAtCaret(document.replier.Body, ' ' + "" + ' ' );
document.replier.texteditor.focus();
return;
}
There is an instance where thisVideo should read thisSpoiler but I'm not sure if that's why it is not placing the new text in the post. /edit after further testing it appears that this is why the text was not getting posted into the message when you would click ok on the box.