I\'d like to return string between two characters, @ and dot (.).
I tried to use regex but cannot find it working.
(@(.*?).)
Anybod
this is the best and fast to use
function get_string_between ($str,$from,$to) { $string = substr($str, strpos($str, $from) + strlen($from)); if (strstr ($string,$to,TRUE) != FALSE) { $string = strstr ($string,$to,TRUE); } return $string; }