SmileyBot 13 Posted July 16, 2018 Report Share Posted July 16, 2018 Hey guys I'm wanting to scrape the website url from goole maps listing, I'm able to scrape it when just running normal browser I'm currently using HTTP GET to run the bot so I would like to continue using it to find regex expression can anyone help as the HTTP code is messy to regex Example url: https://www.google.com/maps/place/Cityside+Conveyancing+Services/@-37.6956501,145.0148806,17z/data=!4m5!3m4!1s0x6ad644f85ba0b2dd:0x9b61e2d8af06c697!8m2!3d-37.6956544!4d145.0170693 Thanks in advance Quote Link to post Share on other sites
bestmacros 60 Posted July 16, 2018 Report Share Posted July 16, 2018 (?<=widget-pane-link">).*(?=<)will work in specific link, but you need to test it on different pages to see if it work everywhere Quote Link to post Share on other sites
SmileyBot 13 Posted July 16, 2018 Author Report Share Posted July 16, 2018 thanks bestmacro for your time, but this doesn't seem to work with HTTP GET cheers this is the SET just need correct regex Thx set(#get_website_url,$find regular expression($plugin function("HTTP post.dll", "$http get", "https://www.google.com/maps/place/?q=place_id:ChIJ78PxQ60Q1moR8NHDUv_v0gk", "", "", "", ""),"(?<=widget-pane-link\">).*(?=<)"),"Global") Quote Link to post Share on other sites
HelloInsomnia 1103 Posted July 16, 2018 Report Share Posted July 16, 2018 This might work but only for normal urls like whatever.com or something.co.uk but not like thisis.awesome and it won't account for other characters like # ? & etc but you can always extend it to try and include these things I suppose but this should get most normal urls at least: set(#mapsListing,$plugin function("HTTP post.dll", "$http get", "https://www.google.com/maps/place/?q=place_id:ChIJ78PxQ60Q1moR8NHDUv_v0gk", "", "", "", ""),"Global") set(#url,$find regular expression(#mapsListing,"(?<=\\,\\\\\\\")[a-zA-Z0-9\\.\\-]+\\.[a-zA-Z]\{2,4\}(|\\.[a-zA-Z]\{2,4\})(?=\\\\\\\"\\,)"),"Global") Quote Link to post Share on other sites
SmileyBot 13 Posted July 16, 2018 Author Report Share Posted July 16, 2018 Thanks Nick, you always come through with the goods 1 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.