andrewgarn Posted October 16, 2008 Author Share Posted October 16, 2008 This works: $newpieces = preg_split("/\s+| /", $newoutput); Thanks but i'm still getting duplicate words appear in the output, including "master" which appears 5 times. Its the same all 5 times in the source code. EDIT: fixed that myself, i was making everything lowercase AFTER the if fuction. Last problem is the junk still in the file: avxds fdbb2 vqme0 igsbe rgqsl za9f6 qqok1 ccci2 idat1 idatw fdyll qeyv3h tdesdr 98s9er 1fxhi rvuk1f wva8j b2iam p9uk0 jakten ynfe2f Quote Link to comment https://forums.phpfreaks.com/topic/128580-solved-remove-words-from-string-underover-a-certain-length/page/2/#findComment-666658 Share on other sites More sharing options...
prexep Posted October 16, 2008 Share Posted October 16, 2008 You want to override the file with the new data? Quote Link to comment https://forums.phpfreaks.com/topic/128580-solved-remove-words-from-string-underover-a-certain-length/page/2/#findComment-666667 Share on other sites More sharing options...
andrewgarn Posted October 16, 2008 Author Share Posted October 16, 2008 no i want to know if there is any of methods I can use to remove this: avxds fdbb2 vqme0 igsbe rgqsl za9f6 qqok1 ccci2 idat1 idatw fdyll qeyv3h tdesdr 98s9er 1fxhi rvuk1f wva8j b2iam p9uk0 jakten ynfe2f from the data string. The random garbage letters change for each file. Quote Link to comment https://forums.phpfreaks.com/topic/128580-solved-remove-words-from-string-underover-a-certain-length/page/2/#findComment-666668 Share on other sites More sharing options...
Maq Posted October 16, 2008 Share Posted October 16, 2008 no i want to know if there is any of methods I can use to remove this: avxds fdbb2 vqme0 igsbe rgqsl za9f6 qqok1 ccci2 idat1 idatw fdyll qeyv3h tdesdr 98s9er 1fxhi rvuk1f wva8j b2iam p9uk0 jakten ynfe2f from the data string. The random garbage letters change for each file. To my knowledge no. That would be like having a spell check to get rid of that jibberish. If I were you, I would mark this topic solved because the title is "Remove words from String under/over a certain length?", and that's solved. Start a new topic with your current code so people can follow it easier. Quote Link to comment https://forums.phpfreaks.com/topic/128580-solved-remove-words-from-string-underover-a-certain-length/page/2/#findComment-666783 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.