|
| 23 Apr 2015 11:13 PM |
let's say this is my string: (html cause HTTPService)
class="name1">teamkilled<
how can I use string manipulation to return "teamkilled"?
HOWEVER, "name1" under class isn't always "name1" and can be shorter/longer |
|
|
| Report Abuse |
|
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
|
| 23 Apr 2015 11:15 PM |
string.match(blah, "teamkileld")? If name1 changes and teamkilled changes, then you're going to have to find a different point since there might be more elements above that have a class= |
|
|
| Report Abuse |
|
|
|
| 24 Apr 2015 01:48 AM |
http://wiki.roblox.com/index.php?title=Function_dump/String_manipulation The ROBLOX wiki actually has an entire page dedicated to string-manipulating functions. I'd highly reccomend getting familiar with at least a few of the ones listed. Combined with Patterns, they're pretty versatile. |
|
|
| Report Abuse |
|
|
eLunate
|
  |
| Joined: 29 Jul 2014 |
| Total Posts: 13268 |
|
|
| 24 Apr 2015 02:10 AM |
string.match(stringythingy, 'class="[%w%s]+">(%w+)<')
That will match class="ANYTHING ALPHANUMERIC">capturestring< |
|
|
| Report Abuse |
|
|