non so alla fine dopo vari tentativi ho risolto con:

$scheda_clear = substr($scheda, strpos($xml_str,">")+38);