Michdd Posted June 1, 2009 Share Posted June 1, 2009 What would be faster, using strpos() on a string, or breaking up a string into a array using explode() and using in_array() on that? Link to comment https://forums.phpfreaks.com/topic/160561-solved-whats-faster/ Share on other sites More sharing options...
ldougherty Posted June 1, 2009 Share Posted June 1, 2009 One function vs Two Functions If str_pos will return the value you need why convert to an array? Link to comment https://forums.phpfreaks.com/topic/160561-solved-whats-faster/#findComment-847388 Share on other sites More sharing options...
Michdd Posted June 1, 2009 Author Share Posted June 1, 2009 I don't know, probably a stupid question. I was just under the impression that strpos() was somewhat 'slow', however it was something else unnecessary in my code, Thanks. Link to comment https://forums.phpfreaks.com/topic/160561-solved-whats-faster/#findComment-847390 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.