Jump to content

Explode


CodyBecker

Recommended Posts

Hi all,

 

(Im new to this so go easy on me  :shy: )

 

I have a messaging system set up and i want one input field to contain the location to be sent and the message.  So i basically want a text-box that will contain this information in this format.... 

 

[location], [text to send]

 

so . . . . . if i were sending a message to ABC i would type into the text box . . .

 

ABC, Hi how are you

 

So im guessing i would use explode to find the receiver name (ABC) and the message text (Hi how are you) and post them.

Link to comment
https://forums.phpfreaks.com/topic/187086-explode/
Share on other sites

Sorry, but firstly... this isn't the place to ask php questions. This board is for help installing and configuring php.

 

Anyway, I don't see a question in your post, so I'll just assume your looking some guidance. explode would definately be one way to get the data you are after. You'll likely also want to look at the limit argument in case a message contains a , you won't wont the message broken into pieces as well.

Link to comment
https://forums.phpfreaks.com/topic/187086-explode/#findComment-987966
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.