<?xml version="1.0" encoding="windows-1252"?>
<node id="1004415" title="Re: Question on Regex" created="2012-11-18 09:00:33" updated="2012-11-18 09:00:33">
<type id="11">
note</type>
<author id="1001958">
karlgoethebier</author>
<data>
<field name="doctext">
&lt;p&gt;Hello, perhaps this helps.&lt;/p&gt;

&lt;code&gt;
#!/usr/bin/perl
use strict;
use warnings;

my $string = qq (.co.uk/Jobs/Company-Sector/C8A6446X4PND86M9WYJ/Tradewind/?APath=2.21.0.0.0);

$string =~ m/.+\/.+\/.+\/(.+)\/.+/;

print $1;
&lt;/code&gt;

&lt;p&gt;&lt;b&gt;Update:&lt;/b&gt; I did not count right, sorry...&lt;/p&gt;

&lt;code&gt;
$string =~m/.+\/.+\/.+\/.+\/(.+)\/.+/;
&lt;/code&gt;

&lt;p&gt;Regards, Karl&lt;/p&gt;


&lt;!-- Node text goes above. Div tags should contain sig only --&gt;
&lt;div class="pmsig"&gt;&lt;div class="pmsig-1001958"&gt;
&lt;p&gt;«The Crux of the Biscuit is the Apostrophe»&lt;/p&gt;

&lt;/div&gt;&lt;/div&gt;</field>
<field name="root_node">
1004410</field>
<field name="parent_node">
1004410</field>
</data>
</node>
