Re: [PHP] pattern match help

2001-03-28 Thread Stuart J. Browne
> $str = "Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)"; > > I need to fetch the 5th charcter after ".compatible; M" in $str (ie > '5'). > > - The following gets me the fifth character along (ie 'l') > $variable = substr ($str, 5, 1); > > How do i tell the substr to start counting from

[PHP] pattern match help

2001-03-28 Thread Costas
$str = "Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)"; I need to fetch the 5th charcter after ".compatible; M" in $str (ie '5'). - The following gets me the fifth character along (ie 'l') $variable = substr ($str, 5, 1); How do i tell the substr to start counting from ".compatibl