darryl561 177 Posted September 11, 2014 Report Share Posted September 11, 2014 I have a list of 100 items like the sample below <td onclick="ubot.runScript('edit(731)')">73</td><td onclick="ubot.runScript('edit(451)')">45</td><td onclick="ubot.runScript('edit(2261)')">226</td><td onclick="ubot.runScript('edit(1371)')">137</td><td onclick="ubot.runScript('edit(2101)')">210</td><td onclick="ubot.runScript('edit(1351)')">135</td><td onclick="ubot.runScript('edit(2211)')">221</td> The only thing I know about regex is that I need to use it to get the data I need and I was hoping someone could show me how. From the sample above I need to end up with a list as below: 7345226137210135221 Any help would be greatly appreciated, cheers. Quote Link to post Share on other sites
beatngu 65 Posted September 11, 2014 Report Share Posted September 11, 2014 Here you go mate.(?<=\">)[0-9]*(?=</td>) 1 Quote Link to post Share on other sites
darryl561 177 Posted September 11, 2014 Author Report Share Posted September 11, 2014 Here you go mate.(?<=\">)[0-9]*(?=</td>) Awesome. Thanks Alex, I really appreciate that, works perfect. Cheers. Quote Link to post Share on other sites
giganut 109 Posted September 11, 2014 Report Share Posted September 11, 2014 You should take a look at this below if your interested in leaning regular expressions.http://www.ubotstudio.com/forum/index.php?/topic/15905-sell-learn-regular-expressions-video-course-2-hours-of-content/ Quote Link to post Share on other sites
darryl561 177 Posted September 12, 2014 Author Report Share Posted September 12, 2014 You should take a look at this below if your interested in leaning regular expressions.http://www.ubotstudio.com/forum/index.php?/topic/15905-sell-learn-regular-expressions-video-course-2-hours-of-content/ Thanks giganut I'll check that out, cheers. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.