hi
I want to remove the content embedded in <script> and </script> tags
submitted via text box.
My java script should remove the content embedded between <script> and
</script> tag.
my current code is
function RemoveHTMLScrip t(strText)
{
var regEx = /<script\w*<\/script>/g
return strText.replace (regEx, "");
}
let us say,
strText = "Hi <script> .... .... ..... </script> How are u";
the expected out put is "Hi How are u"
Regular expression solution is preferred
thanks and regards
Raja rao
I want to remove the content embedded in <script> and </script> tags
submitted via text box.
My java script should remove the content embedded between <script> and
</script> tag.
my current code is
function RemoveHTMLScrip t(strText)
{
var regEx = /<script\w*<\/script>/g
return strText.replace (regEx, "");
}
let us say,
strText = "Hi <script> .... .... ..... </script> How are u";
the expected out put is "Hi How are u"
Regular expression solution is preferred
thanks and regards
Raja rao
Comment