Jump to content

Search String Get Value Then move next


jjmusicpro

Recommended Posts

I have a string like this

 

val1=1,val2=2,val3=3,val4=stop,val1=1,val2=2,val3=3,val4=stop,val1=1,val2=2,val3=3,val4=stop,val1=1,val2=2,val3=3,val4=stop,

 

I dont know how to take the string, look for something like "val4=stop" print out everything before that, and move on to the next.

so it should print out something like

 

val1=1,val2=2,val3=3,val4=stop,val1=1

val1=1,val2=2,val3=3,val4=stop,val1=1

val1=1,val2=2,val3=3,val4=stop,val1=1

 

and not have it in one huge string

Link to comment
https://forums.phpfreaks.com/topic/119855-search-string-get-value-then-move-next/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.