Jump to content

[SOLVED] Need help with trim or some equivilent.


unrelenting

Recommended Posts

I have variables that all start with a number followed by a period and then a space and a team name.

 

I need to grab just the number at the beginning but can't figure out the method to do it with all the available functions.

 

For instance:

 

1. UConn

5. Purdue

12. Cleveland St.

 

I need it to be able to handle single digit numbers as well as double digits. I know this is simple to some of you guys that know php well but I have spent almost an hour at this junction and am forced to ask.  :-[

Sure.  Regex is your best bet hear cause if you tried to explode on ". " (dot space) there could be a team with that in their name.

 

Please mark as [sOLVED] too, thanks.

 

You mean like 1. N. Carolina?  :)

 

You think further ahead than I.

 

Topic Solved.

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.