From 6ea190542bf54664c05761527198d9798fb15386 Mon Sep 17 00:00:00 2001 From: "duncan.parkes" Date: Wed, 4 Apr 2007 02:08:07 +0000 Subject: [PATCH] add three more scrapers --- trunk/CGI/Dundee.cgi | 31 +++++++++++++++++++++ trunk/CGI/Milton Keynes.cgi | 31 +++++++++++++++++++++ trunk/CGI/Northumberland.cgi | 31 +++++++++++++++++++++ trunk/python_scrapers/PublicAccessSites.csv | 3 ++ 4 files changed, 96 insertions(+) create mode 100755 trunk/CGI/Dundee.cgi create mode 100755 trunk/CGI/Milton Keynes.cgi create mode 100755 trunk/CGI/Northumberland.cgi diff --git a/trunk/CGI/Dundee.cgi b/trunk/CGI/Dundee.cgi new file mode 100755 index 0000000..f3238a1 --- /dev/null +++ b/trunk/CGI/Dundee.cgi @@ -0,0 +1,31 @@ +#!/usr/bin/python + +# This is the parser for Dundee City Council. +# it is generated from the file CGITemplate + +import cgi +import cgitb +#cgitb.enable(display=0, logdir="/tmp") + + +form = cgi.FieldStorage() +day = form.getfirst('day') +month = form.getfirst('month') +year = form.getfirst('year') + + +authority_name = "Dundee City Council" +authority_short_name = "Dundee" +base_url = "http://bwarrant.dundeecity.gov.uk/publicaccess/tdc/" + +import PublicAccess + +parser = PublicAccess.PublicAccessParser(authority_name, + authority_short_name, + base_url) + +xml = parser.getResults(day, month, year) + +print "Content-Type: text/xml" # XML is following +print +print xml # print the xml diff --git a/trunk/CGI/Milton Keynes.cgi b/trunk/CGI/Milton Keynes.cgi new file mode 100755 index 0000000..4772bdf --- /dev/null +++ b/trunk/CGI/Milton Keynes.cgi @@ -0,0 +1,31 @@ +#!/usr/bin/python + +# This is the parser for Milton Keynes Council. +# it is generated from the file CGITemplate + +import cgi +import cgitb +#cgitb.enable(display=0, logdir="/tmp") + + +form = cgi.FieldStorage() +day = form.getfirst('day') +month = form.getfirst('month') +year = form.getfirst('year') + + +authority_name = "Milton Keynes Council" +authority_short_name = "Milton Keynes" +base_url = "http://publicaccess.milton-keynes.gov.uk/tdc/" + +import PublicAccess + +parser = PublicAccess.PublicAccessParser(authority_name, + authority_short_name, + base_url) + +xml = parser.getResults(day, month, year) + +print "Content-Type: text/xml" # XML is following +print +print xml # print the xml diff --git a/trunk/CGI/Northumberland.cgi b/trunk/CGI/Northumberland.cgi new file mode 100755 index 0000000..e2e8634 --- /dev/null +++ b/trunk/CGI/Northumberland.cgi @@ -0,0 +1,31 @@ +#!/usr/bin/python + +# This is the parser for Northumberland County Council. +# it is generated from the file CGITemplate + +import cgi +import cgitb +#cgitb.enable(display=0, logdir="/tmp") + + +form = cgi.FieldStorage() +day = form.getfirst('day') +month = form.getfirst('month') +year = form.getfirst('year') + + +authority_name = "Northumberland County Council" +authority_short_name = "Northumberland" +base_url = "http://planning.northumberland.gov.uk/publicaccess/tdc/" + +import PublicAccess + +parser = PublicAccess.PublicAccessParser(authority_name, + authority_short_name, + base_url) + +xml = parser.getResults(day, month, year) + +print "Content-Type: text/xml" # XML is following +print +print xml # print the xml diff --git a/trunk/python_scrapers/PublicAccessSites.csv b/trunk/python_scrapers/PublicAccessSites.csv index c028fa0..588ccf0 100644 --- a/trunk/python_scrapers/PublicAccessSites.csv +++ b/trunk/python_scrapers/PublicAccessSites.csv @@ -51,3 +51,6 @@ "Torbay Council", "Torbay", "http://www.torbay.gov.uk/publicaccess/tdc/" "South Ribble Borough Council", "South Ribble", "http://publicaccess.southribble.gov.uk/publicaccess/tdc/" "Peterborough City Council", "Peterborough", "http://194.72.246.15/publicaccess/dc/" +"Dundee City Council", "Dundee", "http://bwarrant.dundeecity.gov.uk/publicaccess/tdc/" +"Northumberland County Council", "Northumberland", "http://planning.northumberland.gov.uk/publicaccess/tdc/" +"Milton Keynes Council", "Milton Keynes", "http://publicaccess.milton-keynes.gov.uk/tdc/"