Ok, so, you might know about JavaScript regular expressions. Well, here is a tutorial about them, but written by a 13 year old, so it isn't actually any good!
Regular expressions go between / characters. Here is an exampe, /hi/.
Ok, now then. Let's learn how to match the string abc. Well, that's quite simple.
/abc/. Yey! So putting letters next to each other makes them match one after the other.
Ok, now, after the second / we can put a g to make it match globally, that is, we can extract abc from xyzabcghi.