Hello,

I would like to query and use the data returned from a google local search... For those who dont know the google local search this can be found here...

http://www.google.co.uk/local?hl=en&lr=&q=pizza&near=Colchester+CO3+9FA&sa=X&oi=localr

Using Lynx, I was able to get a text dump of the page
[1]Google Local _______________________ _________________________________ Search What Where [_] Remember this location Local Search within: [2]1 mile - [3]5 miles - 15 miles - [4]45 miles Show only: [5]Pizza Delivery & Takeaway - [6]Takeaway Food A. [7]1st & Always Sam's Pizzeria 01206 575555 5 Crouch St Colchester, CO3 3EN 1.8 mi NE - [8]Directions References: [9]the-business-search.co.uk - [10]2 more » B. [11]Pizza Italia Plus 01206 545500 34a Mersea Rd Colchester, CO2 7ES 1.9 mi E - [12]Directions C. [13]Pizza Express plc 01206 760680 1 St. Runwald Street Colchester, CO1 1AG 1.9 mi NE - [14]Directions References: [15]bbc.co.uk - [16]2 more » D. [17]Perfect Pizza 01206 546444 1 Middleborough Colchester, CO1 1QS 2.0 mi NE - [18]Directions References: [19]perfectpizza.co.uk E. [20]Pizza Hut (UK) Ltd 01206 574478 48-50 High St Colchester, CO1 1DH 2.0 mi NE - [21]Directions . . . etc . . .
What I would like is a regex to extarct the Name,Telephone,Address and distance of each record returned



Any help would be really appricated.

Dan

In reply to Google local search regex by danambroseUK

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.