elpaisa Posted August 20, 2007 Share Posted August 20, 2007 Hi all! I basically need to remove all characters of a string before the first dot for an example: I have a phrase: statistics.STATUS this should be the result: STATUS this is a post var dinamically loaded, so i don't know if to use str_replace or there is another function that i can call. Thanks. all your help is welcome! Link to comment https://forums.phpfreaks.com/topic/65884-php-explode-all-characters-before-the-first-dot/ Share on other sites More sharing options...
MadTechie Posted August 20, 2007 Share Posted August 20, 2007 $data = "statistics.STATUS "; $result = preg_replace('/.*\.(.*)/sim', '$1', $data); Link to comment https://forums.phpfreaks.com/topic/65884-php-explode-all-characters-before-the-first-dot/#findComment-329338 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.