jmurch Posted September 25, 2007 Share Posted September 25, 2007 Can someone please tell me what's up with this function? It works fine on one server and not at all on another. It's not found on php.net but is known as a function in my zend studio editor? Is it a function that's found in another library? Is there something more reliable I can use to do the same thing? Thanks Link to comment https://forums.phpfreaks.com/topic/70564-solved-whats-up-with-get_stringdelim1-str-delim2/ Share on other sites More sharing options...
EvanAgee Posted September 25, 2007 Share Posted September 25, 2007 Is the purpose of the function to extract a string from within a string? Link to comment https://forums.phpfreaks.com/topic/70564-solved-whats-up-with-get_stringdelim1-str-delim2/#findComment-354582 Share on other sites More sharing options...
jmurch Posted September 25, 2007 Author Share Posted September 25, 2007 Yep Evan. It was a function that I had in an included file not a php function. <?php function get_string($delim1,$str,$delim2) { list($dmy,$tmp) = explode($delim1,$str,2); list($tmp,$dmy) = explode($delim2,$tmp,2); return ($tmp); } $string = 'stringstringstringstringxxxxstringstringyyyystring'; $newstring = get_string('xxxx',$string,'yyyy'); echo $newstring; ?> Link to comment https://forums.phpfreaks.com/topic/70564-solved-whats-up-with-get_stringdelim1-str-delim2/#findComment-354586 Share on other sites More sharing options...
EvanAgee Posted September 25, 2007 Share Posted September 25, 2007 Ah, that's what I thought Link to comment https://forums.phpfreaks.com/topic/70564-solved-whats-up-with-get_stringdelim1-str-delim2/#findComment-354587 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.