http://www.animeseason.com/naruto-shippuuden-episode-143/ I need to decode the embed code on that page with php. this is the escapeall() code: function escapeall(str){return str.replace(/[A-Z]/g,'');} Code (markup): basically i need that in PHP. I need the answer quick, so first come first served. will only pay if it fixes my problem. MSN: PayPal only. Regards.
Hi, If I understood right: in php is: function escapeall($str){ return preg_replace(/[A-Z]/,'',$str); } PHP: Regards, Nick
OK, Thanks! If you need case insensitive function: javascript function escapeall(str){return str.replace(/[A-Z]/ig,'');} Code (markup): php function escapeall($str){ return preg_replace('/[a-z]/i','',$str); } PHP: Regards, Nick p.p. : difference is i modifiers. Edit: Oh, I forgor '' (writing in forum directly) -> '/[a-z]/i'
Not quite, but i changed it to this and it worked: function escapeall($str){ return preg_replace("/[A-Z]/",'',$str); } PHP: (Notice you forgot the quotation marks for "/[A-Z]/") Well it works so I'll PM you now.