denoteone Posted September 13, 2010 Share Posted September 13, 2010 If I explode a string well using a substring when I implode that substring is now missing. for example. $exploded = explode("[MAC]",$data); $data = implode($exploded); Now [MAC] would be missing in the $data string. any way to get around this? Link to comment https://forums.phpfreaks.com/topic/213290-explode-and-then-implode-now-substring-that-was-use-to-explode-is-missing/ Share on other sites More sharing options...
.josh Posted September 13, 2010 Share Posted September 13, 2010 implode accepts an optional parameter that lets you specify the "glue" delimiter. If you don't specify, "" is used. Link to comment https://forums.phpfreaks.com/topic/213290-explode-and-then-implode-now-substring-that-was-use-to-explode-is-missing/#findComment-1110550 Share on other sites More sharing options...
denoteone Posted September 13, 2010 Author Share Posted September 13, 2010 thanks for some reason I was thinking that would put that value in the first instance of the array. Which I didnt want. Thanks again. Link to comment https://forums.phpfreaks.com/topic/213290-explode-and-then-implode-now-substring-that-was-use-to-explode-is-missing/#findComment-1110552 Share on other sites More sharing options...
fortnox007 Posted September 13, 2010 Share Posted September 13, 2010 I am wondering if organisations like CIA and NSA have this topic in there eye sight, with terms like implode and explode Link to comment https://forums.phpfreaks.com/topic/213290-explode-and-then-implode-now-substring-that-was-use-to-explode-is-missing/#findComment-1110553 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.