Why is my str_replace not working on short code submitted by front-end?

try to put this code before replace text in string

inside if( !empty( $_POST['scembed'] ) ) {

$_POST['scembed'] = stripslashes( $_POST['scembed'] );

Note

problem occuring because your quote are escaped in string, so ” becomes \”

File not found.