Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'master' into gh-pages

  • Loading branch information...
commit 4ad5e3665bef51594ae7425efb2798249d0adb98 2 parents e08cbd3 + 537154d
Dave Cross authored
60 bin/create_lists
View
@@ -0,0 +1,60 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+use 5.010;
+use lib 'lib';
+
+use TwittElection::Twitter;
+use TwittElection::Schema;
+
+my $sch = TwittElection::Schema->connect(
+ "dbi:mysql:$ENV{TE_DB}", $ENV{TE_USER}, $ENV{TE_PASS},
+) or die;
+
+my $con_rs = $sch->resultset('Constituency');
+
+my $t = TwittElection::Twitter->new(
+ traits => [ 'API::RESTv1_1', 'OAuth' ],
+ ssl => 1,
+ consumer_key => $ENV{TE_TW_API_KEY},
+ consumer_secret => $ENV{TE_TW_API_SEC},
+);
+
+$t->authorise;
+
+foreach my $con ($con_rs->all) {
+ next unless $con->candidates->count;
+ say $con->name;
+
+ eval {
+ if ($con->list_id) {
+ say 'Delete ', $con->list_name;
+ $t->delete_list({
+ list_id => $con->list_id,
+ });
+ }
+ };
+ say 'Create ', $con->name;
+ my $list = $t->create_list({
+ owner_screen_name => 'twittelection',
+ name => $con->name,
+ });
+ say "Created $list->{slug} ($list->{id})";
+ sleep 2;
+
+ $con->update({
+ list_name => $list->{slug},
+ list_id => $list->{id},
+ });
+
+ foreach my $cand ($con->candidates) {
+ next unless $cand->twitter;
+ say ' -> ', $cand->name;
+ $t->add_list_member({
+ list_id => $list->{id},
+ screen_name => $cand->twitter,
+ });
+ sleep 2;
+ }
+}
21 bin/delete_list
View
@@ -0,0 +1,21 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+use 5.010;
+use lib 'lib';
+
+use TwittElection::Twitter;
+
+my $t = TwittElection::Twitter->new(
+ traits => [ 'API::RESTv1_1', 'OAuth' ],
+ ssl => 1,
+ consumer_key => $ENV{TE_TW_API_KEY},
+ consumer_secret => $ENV{TE_TW_API_SEC},
+);
+
+$t->authorise;
+
+$t->delete_list({
+ list_id => +shift,
+});
22 bin/delete_lists
View
@@ -0,0 +1,22 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+use 5.010;
+use lib 'lib';
+
+use TwittElection::Twitter;
+
+my $t = TwittElection::Twitter->new(
+ traits => [ 'API::RESTv1_1', 'OAuth' ],
+ ssl => 1,
+ consumer_key => $ENV{TE_TW_API_KEY},
+ consumer_secret => $ENV{TE_TW_API_SEC},
+);
+
+$t->authorise;
+
+foreach my $list (@{$t->list_ownerships->{lists}}) {
+ say $list->{name}, ' (', $list->{id}, ')';
+ $t->delete_list({ list_id => $list->{id} });
+}
24 bin/list_lists
View
@@ -0,0 +1,24 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+use 5.010;
+use lib 'lib';
+
+use TwittElection::Twitter;
+
+my $t = TwittElection::Twitter->new(
+ traits => [ 'API::RESTv1_1', 'OAuth' ],
+ ssl => 1,
+ consumer_key => $ENV{TE_TW_API_KEY},
+ consumer_secret => $ENV{TE_TW_API_SEC},
+);
+
+$t->authorise;
+
+foreach my $list (@{$t->list_ownerships->{lists}}) {
+ say $list->{name}, ' (', $list->{id}, ')';
+ foreach my $mem (@{$t->list_members({ list_id => $list->{id} })->{users}}) {
+ say "* \@$mem->{screen_name}";
+ }
+}
96 c/aberavon.html
View
@@ -0,0 +1,96 @@
+<!DOCTYPE html>
+<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
+<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
+<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]-->
+<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->
+ <head>
+ <meta charset="utf-8">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+ <title>TwittElection: Aberavon</title>
+ <meta name="description" content="">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+
+ <link rel="stylesheet" href="/css/bootstrap.min.css">
+ <style>
+body {
+ padding-top: 50px;
+ padding-bottom: 20px;
+}
+ </style>
+ <link rel="stylesheet" href="/css/bootstrap-theme.min.css">
+ <link rel="stylesheet" href="/css/main.css">
+
+ <script src="/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js"></script>
+ </head>
+ <body>
+ <!--[if lt IE 7]>
+ <p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
+ <![endif]-->
+ <div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
+ <div class="container">
+ <div class="navbar-header">
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
+ <span class="sr-only">Toggle navigation</span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ </button>
+ <a class="navbar-brand" href="#">TwittElection</a>
+ </div>
+ <div class="navbar-collapse collapse">
+ <!-- form class="navbar-form navbar-right" role="form">
+ <div class="form-group">
+ <input type="text" placeholder="Email" class="form-control">
+ </div>
+ <div class="form-group">
+ <input type="password" placeholder="Password" class="form-control">
+ </div>
+ <button type="submit" class="btn btn-success">Sign in</button>
+ </form -->
+ </div><!--/.navbar-collapse -->
+ </div>
+ </div>
+
+ <!-- Main jumbotron for a primary marketing message or call to action -->
+ <div class="jumbotron">
+ <div class="container">
+ <h1>Aberavon</h1>
+ <div class="row">
+ <div class="col-md-8">
+<a class="twitter-timeline" href="https://twitter.com/TwittElection/lists/aberavon" data-widget-id="464129893937082368" data-list-owner-screen-name="TwittElection" data-list-slug="aberavon">Tweets from https://twitter.com/TwittElection/lists/aberavon</a>
+<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+"://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
+ </div>
+ <div class="col-md-4">
+ <ul>
+ <li>Stephen Kinnock (Labour)<br><a href="https://twitter.com/SKinnock">@SKinnock</a></li>
+ </ul>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div id="footer">
+ <div class="container">
+ <p class="muted">Made by <a href="https://twitter.com/davorg/">@davorg</a></p>
+ </div>
+ </div>
+ <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
+ <script>window.jQuery || document.write('<script src="/js/vendor/jquery-1.11.0.min.js"><\/script>')</script>
+
+ <script src="/js/vendor/bootstrap.min.js"></script>
+
+ <script src="/js/plugins.js"></script>
+ <script src="/js/main.js"></script>
+
+ <!-- Google Analytics: change UA-XXXXX-X to be your site's ID. -->
+ <script>
+ (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
+ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
+ m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
+ })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
+
+ ga('create', 'UA-56332-52', 'twittelection.co.uk');
+ ga('send', 'pageview');
+
+ </script>
+ </body>
+</html>
96 c/aberconwy.html
View
@@ -0,0 +1,96 @@
+<!DOCTYPE html>
+<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
+<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
+<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]-->
+<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->
+ <head>
+ <meta charset="utf-8">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+ <title>TwittElection: Aberconwy</title>
+ <meta name="description" content="">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+
+ <link rel="stylesheet" href="/css/bootstrap.min.css">
+ <style>
+body {
+ padding-top: 50px;
+ padding-bottom: 20px;
+}
+ </style>
+ <link rel="stylesheet" href="/css/bootstrap-theme.min.css">
+ <link rel="stylesheet" href="/css/main.css">
+
+ <script src="/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js"></script>
+ </head>
+ <body>
+ <!--[if lt IE 7]>
+ <p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
+ <![endif]-->
+ <div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
+ <div class="container">
+ <div class="navbar-header">
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
+ <span class="sr-only">Toggle navigation</span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ </button>
+ <a class="navbar-brand" href="#">TwittElection</a>
+ </div>
+ <div class="navbar-collapse collapse">
+ <!-- form class="navbar-form navbar-right" role="form">
+ <div class="form-group">
+ <input type="text" placeholder="Email" class="form-control">
+ </div>
+ <div class="form-group">
+ <input type="password" placeholder="Password" class="form-control">
+ </div>
+ <button type="submit" class="btn btn-success">Sign in</button>
+ </form -->
+ </div><!--/.navbar-collapse -->
+ </div>
+ </div>
+
+ <!-- Main jumbotron for a primary marketing message or call to action -->
+ <div class="jumbotron">
+ <div class="container">
+ <h1>Aberconwy</h1>
+ <div class="row">
+ <div class="col-md-8">
+<a class="twitter-timeline" href="https://twitter.com/TwittElection/lists/aberconwy" data-widget-id="464129893937082368" data-list-owner-screen-name="TwittElection" data-list-slug="aberconwy">Tweets from https://twitter.com/TwittElection/lists/aberconwy</a>
+<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+"://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
+ </div>
+ <div class="col-md-4">
+ <ul>
+ <li>Guto Bebb (Conservative)<br><a href="https://twitter.com/GutoBebb">@GutoBebb</a></li>
+ </ul>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div id="footer">
+ <div class="container">
+ <p class="muted">Made by <a href="https://twitter.com/davorg/">@davorg</a></p>
+ </div>
+ </div>
+ <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
+ <script>window.jQuery || document.write('<script src="/js/vendor/jquery-1.11.0.min.js"><\/script>')</script>
+
+ <script src="/js/vendor/bootstrap.min.js"></script>
+
+ <script src="/js/plugins.js"></script>
+ <script src="/js/main.js"></script>
+
+ <!-- Google Analytics: change UA-XXXXX-X to be your site's ID. -->
+ <script>
+ (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
+ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
+ m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
+ })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
+
+ ga('create', 'UA-56332-52', 'twittelection.co.uk');
+ ga('send', 'pageview');
+
+ </script>
+ </body>
+</html>
96 c/aberdeen-north.html
View
@@ -0,0 +1,96 @@
+<!DOCTYPE html>
+<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
+<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
+<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]-->
+<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->
+ <head>
+ <meta charset="utf-8">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+ <title>TwittElection: Aberdeen North</title>
+ <meta name="description" content="">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+
+ <link rel="stylesheet" href="/css/bootstrap.min.css">
+ <style>
+body {
+ padding-top: 50px;
+ padding-bottom: 20px;
+}
+ </style>
+ <link rel="stylesheet" href="/css/bootstrap-theme.min.css">
+ <link rel="stylesheet" href="/css/main.css">
+
+ <script src="/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js"></script>
+ </head>
+ <body>
+ <!--[if lt IE 7]>
+ <p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
+ <![endif]-->
+ <div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
+ <div class="container">
+ <div class="navbar-header">
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
+ <span class="sr-only">Toggle navigation</span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ </button>
+ <a class="navbar-brand" href="#">TwittElection</a>
+ </div>
+ <div class="navbar-collapse collapse">
+ <!-- form class="navbar-form navbar-right" role="form">
+ <div class="form-group">
+ <input type="text" placeholder="Email" class="form-control">
+ </div>
+ <div class="form-group">
+ <input type="password" placeholder="Password" class="form-control">
+ </div>
+ <button type="submit" class="btn btn-success">Sign in</button>
+ </form -->
+ </div><!--/.navbar-collapse -->
+ </div>
+ </div>
+
+ <!-- Main jumbotron for a primary marketing message or call to action -->
+ <div class="jumbotron">
+ <div class="container">
+ <h1>Aberdeen North</h1>
+ <div class="row">
+ <div class="col-md-8">
+<a class="twitter-timeline" href="https://twitter.com/TwittElection/lists/aberdeen-north" data-widget-id="464129893937082368" data-list-owner-screen-name="TwittElection" data-list-slug="aberdeen-north">Tweets from https://twitter.com/TwittElection/lists/aberdeen-north</a>
+<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+"://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
+ </div>
+ <div class="col-md-4">
+ <ul>
+ <li>Frank Doran (Labour)</li>
+ </ul>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div id="footer">
+ <div class="container">
+ <p class="muted">Made by <a href="https://twitter.com/davorg/">@davorg</a></p>
+ </div>
+ </div>
+ <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
+ <script>window.jQuery || document.write('<script src="/js/vendor/jquery-1.11.0.min.js"><\/script>')</script>
+
+ <script src="/js/vendor/bootstrap.min.js"></script>
+
+ <script src="/js/plugins.js"></script>
+ <script src="/js/main.js"></script>
+
+ <!-- Google Analytics: change UA-XXXXX-X to be your site's ID. -->
+ <script>
+ (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
+ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
+ m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
+ })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
+
+ ga('create', 'UA-56332-52', 'twittelection.co.uk');
+ ga('send', 'pageview');
+
+ </script>
+ </body>
+</html>
96 c/aberdeen-south.html
View
@@ -0,0 +1,96 @@
+<!DOCTYPE html>
+<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
+<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
+<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]-->
+<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->
+ <head>
+ <meta charset="utf-8">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+ <title>TwittElection: Aberdeen South</title>
+ <meta name="description" content="">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+
+ <link rel="stylesheet" href="/css/bootstrap.min.css">
+ <style>
+body {
+ padding-top: 50px;
+ padding-bottom: 20px;
+}
+ </style>
+ <link rel="stylesheet" href="/css/bootstrap-theme.min.css">
+ <link rel="stylesheet" href="/css/main.css">
+
+ <script src="/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js"></script>
+ </head>
+ <body>
+ <!--[if lt IE 7]>
+ <p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
+ <![endif]-->
+ <div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
+ <div class="container">
+ <div class="navbar-header">
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
+ <span class="sr-only">Toggle navigation</span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ </button>
+ <a class="navbar-brand" href="#">TwittElection</a>
+ </div>
+ <div class="navbar-collapse collapse">
+ <!-- form class="navbar-form navbar-right" role="form">
+ <div class="form-group">
+ <input type="text" placeholder="Email" class="form-control">
+ </div>
+ <div class="form-group">
+ <input type="password" placeholder="Password" class="form-control">
+ </div>
+ <button type="submit" class="btn btn-success">Sign in</button>
+ </form -->
+ </div><!--/.navbar-collapse -->
+ </div>
+ </div>
+
+ <!-- Main jumbotron for a primary marketing message or call to action -->
+ <div class="jumbotron">
+ <div class="container">
+ <h1>Aberdeen South</h1>
+ <div class="row">
+ <div class="col-md-8">
+<a class="twitter-timeline" href="https://twitter.com/TwittElection/lists/aberdeen-south" data-widget-id="464129893937082368" data-list-owner-screen-name="TwittElection" data-list-slug="aberdeen-south">Tweets from https://twitter.com/TwittElection/lists/aberdeen-south</a>
+<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+"://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
+ </div>
+ <div class="col-md-4">
+ <ul>
+ <li>Anne Begg (Labour)<br><a href="https://twitter.com/annebegg">@annebegg</a></li>
+ </ul>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div id="footer">
+ <div class="container">
+ <p class="muted">Made by <a href="https://twitter.com/davorg/">@davorg</a></p>
+ </div>
+ </div>
+ <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
+ <script>window.jQuery || document.write('<script src="/js/vendor/jquery-1.11.0.min.js"><\/script>')</script>
+
+ <script src="/js/vendor/bootstrap.min.js"></script>
+
+ <script src="/js/plugins.js"></script>
+ <script src="/js/main.js"></script>
+
+ <!-- Google Analytics: change UA-XXXXX-X to be your site's ID. -->
+ <script>
+ (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
+ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
+ m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
+ })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
+
+ ga('create', 'UA-56332-52', 'twittelection.co.uk');
+ ga('send', 'pageview');
+
+ </script>
+ </body>
+</html>
96 c/airdrie-and-shotts.html
View
@@ -0,0 +1,96 @@
+<!DOCTYPE html>
+<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
+<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
+<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]-->
+<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->
+ <head>
+ <meta charset="utf-8">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+ <title>TwittElection: Airdrie and Shotts</title>
+ <meta name="description" content="">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+
+ <link rel="stylesheet" href="/css/bootstrap.min.css">
+ <style>
+body {
+ padding-top: 50px;
+ padding-bottom: 20px;
+}
+ </style>
+ <link rel="stylesheet" href="/css/bootstrap-theme.min.css">
+ <link rel="stylesheet" href="/css/main.css">
+
+ <script src="/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js"></script>
+ </head>
+ <body>
+ <!--[if lt IE 7]>
+ <p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
+ <![endif]-->
+ <div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
+ <div class="container">
+ <div class="navbar-header">
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
+ <span class="sr-only">Toggle navigation</span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ </button>
+ <a class="navbar-brand" href="#">TwittElection</a>
+ </div>
+ <div class="navbar-collapse collapse">
+ <!-- form class="navbar-form navbar-right" role="form">
+ <div class="form-group">
+ <input type="text" placeholder="Email" class="form-control">
+ </div>
+ <div class="form-group">
+ <input type="password" placeholder="Password" class="form-control">
+ </div>
+ <button type="submit" class="btn btn-success">Sign in</button>
+ </form -->
+ </div><!--/.navbar-collapse -->
+ </div>
+ </div>
+
+ <!-- Main jumbotron for a primary marketing message or call to action -->
+ <div class="jumbotron">
+ <div class="container">
+ <h1>Airdrie and Shotts</h1>
+ <div class="row">
+ <div class="col-md-8">
+<a class="twitter-timeline" href="https://twitter.com/TwittElection/lists/airdrie-and-shotts" data-widget-id="464129893937082368" data-list-owner-screen-name="TwittElection" data-list-slug="airdrie-and-shotts">Tweets from https://twitter.com/TwittElection/lists/airdrie-and-shotts</a>
+<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+"://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
+ </div>
+ <div class="col-md-4">
+ <ul>
+ <li>Pamela Nash (Labour)<br><a href="https://twitter.com/pamela_nash">@pamela_nash</a></li>
+ </ul>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div id="footer">
+ <div class="container">
+ <p class="muted">Made by <a href="https://twitter.com/davorg/">@davorg</a></p>
+ </div>
+ </div>
+ <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
+ <script>window.jQuery || document.write('<script src="/js/vendor/jquery-1.11.0.min.js"><\/script>')</script>
+
+ <script src="/js/vendor/bootstrap.min.js"></script>
+
+ <script src="/js/plugins.js"></script>
+ <script src="/js/main.js"></script>
+
+ <!-- Google Analytics: change UA-XXXXX-X to be your site's ID. -->
+ <script>
+ (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
+ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
+ m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
+ })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
+
+ ga('create', 'UA-56332-52', 'twittelection.co.uk');
+ ga('send', 'pageview');
+
+ </script>
+ </body>
+</html>
96 c/aldershot.html
View
@@ -0,0 +1,96 @@
+<!DOCTYPE html>
+<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
+<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
+<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]-->
+<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->
+ <head>
+ <meta charset="utf-8">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+ <title>TwittElection: Aldershot</title>
+ <meta name="description" content="">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+
+ <link rel="stylesheet" href="/css/bootstrap.min.css">
+ <style>
+body {
+ padding-top: 50px;
+ padding-bottom: 20px;
+}
+ </style>
+ <link rel="stylesheet" href="/css/bootstrap-theme.min.css">
+ <link rel="stylesheet" href="/css/main.css">
+
+ <script src="/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js"></script>
+ </head>
+ <body>
+ <!--[if lt IE 7]>
+ <p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
+ <![endif]-->
+ <div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
+ <div class="container">
+ <div class="navbar-header">
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
+ <span class="sr-only">Toggle navigation</span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ </button>
+ <a class="navbar-brand" href="#">TwittElection</a>
+ </div>
+ <div class="navbar-collapse collapse">
+ <!-- form class="navbar-form navbar-right" role="form">
+ <div class="form-group">
+ <input type="text" placeholder="Email" class="form-control">
+ </div>
+ <div class="form-group">
+ <input type="password" placeholder="Password" class="form-control">
+ </div>
+ <button type="submit" class="btn btn-success">Sign in</button>
+ </form -->
+ </div><!--/.navbar-collapse -->
+ </div>
+ </div>
+
+ <!-- Main jumbotron for a primary marketing message or call to action -->
+ <div class="jumbotron">
+ <div class="container">
+ <h1>Aldershot</h1>
+ <div class="row">
+ <div class="col-md-8">
+<a class="twitter-timeline" href="https://twitter.com/TwittElection/lists/aldershot" data-widget-id="464129893937082368" data-list-owner-screen-name="TwittElection" data-list-slug="aldershot">Tweets from https://twitter.com/TwittElection/lists/aldershot</a>
+<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+"://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
+ </div>
+ <div class="col-md-4">
+ <ul>
+ <li>Gerald Howarth (Conservative)<br><a href="https://twitter.com/geraldhowarth">@geraldhowarth</a></li>
+ </ul>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div id="footer">
+ <div class="container">
+ <p class="muted">Made by <a href="https://twitter.com/davorg/">@davorg</a></p>
+ </div>
+ </div>
+ <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
+ <script>window.jQuery || document.write('<script src="/js/vendor/jquery-1.11.0.min.js"><\/script>')</script>
+
+ <script src="/js/vendor/bootstrap.min.js"></script>
+
+ <script src="/js/plugins.js"></script>
+ <script src="/js/main.js"></script>
+
+ <!-- Google Analytics: change UA-XXXXX-X to be your site's ID. -->
+ <script>
+ (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
+ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
+ m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
+ })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
+
+ ga('create', 'UA-56332-52', 'twittelection.co.uk');
+ ga('send', 'pageview');
+
+ </script>
+ </body>
+</html>
96 c/aldridge-brownhills.html
View
@@ -0,0 +1,96 @@
+<!DOCTYPE html>
+<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
+<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
+<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]-->
+<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->
+ <head>
+ <meta charset="utf-8">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+ <title>TwittElection: Aldridge-Brownhills</title>
+ <meta name="description" content="">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+
+ <link rel="stylesheet" href="/css/bootstrap.min.css">
+ <style>
+body {
+ padding-top: 50px;
+ padding-bottom: 20px;
+}
+ </style>
+ <link rel="stylesheet" href="/css/bootstrap-theme.min.css">
+ <link rel="stylesheet" href="/css/main.css">
+
+ <script src="/js/vendor/modernizr-2.6.2-respond-1.1.0.min.js"></script>
+ </head>
+ <body>
+ <!--[if lt IE 7]>
+ <p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
+ <![endif]-->
+ <div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
+ <div class="container">
+ <div class="navbar-header">
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
+ <span class="sr-only">Toggle navigation</span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ <span class="icon-bar"></span>
+ </button>
+ <a class="navbar-brand" href="#">TwittElection</a>
+ </div>
+ <div class="navbar-collapse collapse">
+ <!-- form class="navbar-form navbar-right" role="form">
+ <div class="form-group">
+ <input type="text" placeholder="Email" class="form-control">
+ </div>
+ <div class="form-group">
+ <input type="password" placeholder="Password" class="form-control">
+ </div>
+ <button type="submit" class="btn btn-success">Sign in</button>
+ </form -->
+ </div><!--/.navbar-collapse -->
+ </div>
+ </div>
+
+ <!-- Main jumbotron for a primary marketing message or call to action -->
+ <div class="jumbotron">
+ <div class="container">
+ <h1>Aldridge-Brownhills</h1>
+ <div class="row">
+ <div class="col-md-8">
+<a class="twitter-timeline" href="https://twitter.com/TwittElection/lists/aldridge-brownhills" data-widget-id="464129893937082368" data-list-owner-screen-name="TwittElection" data-list-slug="aldridge-brownhills">Tweets from https://twitter.com/TwittElection/lists/aldridge-brownhills</a>
+<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+"://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
+ </div>
+ <div class="col-md-4">
+ <ul>
+ <li>Richard Shepherd (Conservative)</li>
+ </ul>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div id="footer">
+ <div class="container">
+ <p class="muted">Made by <a href="https://twitter.com/davorg/">@davorg</a></p>
+ </div>
+ </div>
+ <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
+ <script>window.jQuery || document.write('<script src="/js/vendor/jquery-1.11.0.min.js"><\/script>')</script>
+
+ <script src="/js/vendor/bootstrap.min.js"></script>
+
+ <script src="/js/plugins.js"></script>
+ <script src="/js/main.js"></script>
+
+ <!-- Google Analytics: change UA-XXXXX-X to be your site's ID. -->
+ <script>
+ (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
+ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
+ m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
+ })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
+
+ ga('create', 'UA-56332-52', 'twittelection.co.uk');
+ ga('send', 'pageview');
+
+ </script>
+ </body>
+</html>
7 db/candidate.csv
View
@@ -5,3 +5,10 @@ Will Martindale|WillJMartindale|Labour|Battersea
Sadiq Khan|SadiqKhan|Labour|Tooting
Charlynne Pullen|CharlynnePullen|Labour|Mid Bedfordshire
Douglas Carswell|DouglasCarswell|Conservative|Clacton
+Stephen Kinnock|SKinnock|Labour|Aberavon
+Guto Bebb|GutoBebb|Conservative|Aberconwy
+Frank Doran||Labour|Aberdeen North
+Anne Begg|annebegg|Labour|Aberdeen South
+Pamela Nash|pamela_nash|Labour|Airdrie and Shotts
+Gerald Howarth|geraldhowarth|Conservative|Aldershot
+Richard Shepherd||Conservative|Aldridge-Brownhills
19 db/constituency.dat
View
@@ -16,27 +16,12 @@
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
--
--- Table structure for table `constituency`
---
-
-DROP TABLE IF EXISTS `constituency`;
-/*!40101 SET @saved_cs_client = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `constituency` (
- `id` int(11) NOT NULL AUTO_INCREMENT,
- `name` varchar(200) NOT NULL,
- `list_name` varchar(200) NOT NULL,
- PRIMARY KEY (`id`)
-) ENGINE=InnoDB AUTO_INCREMENT=1947 DEFAULT CHARSET=latin1;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
-- Dumping data for table `constituency`
--
LOCK TABLES `constituency` WRITE;
/*!40000 ALTER TABLE `constituency` DISABLE KEYS */;
-INSERT INTO `constituency` VALUES (1,'Aberavon','aberavon'),(2,'Aberconwy','aberconwy'),(3,'Aberdeen North','aberdeen-n'),(4,'Aberdeen South','aberdeen-s'),(5,'Airdrie and Shotts','airdrie-and-shotts'),(6,'Aldershot','aldershot'),(7,'Aldridge-Brownhills','aldridge-brownhills'),(8,'Altrincham and Sale West','altrincham-and-sale-w'),(9,'Alyn and Deeside','alyn-and-deeside'),(10,'Amber Valley','amber-valley'),(11,'Angus','angus'),(12,'Arfon','arfon'),(13,'Argyll and Bute','argyll-and-bute'),(14,'Arundel and South Downs','arundel-and-s-downs'),(15,'Ashfield','ashfield'),(16,'Ashford','ashford'),(17,'Ashton-under-Lyne','ashton-under-lyne'),(18,'Aylesbury','aylesbury'),(19,'Ayr, Carrick and Cumnock','ayr-carrick-and-cumnock'),(20,'Banbury','banbury'),(21,'Banff and Buchan','banff-and-buchan'),(22,'Barking','barking'),(23,'Barnsley Central','barnsley-central'),(24,'Barnsley East','barnsley-e'),(25,'Barrow and Furness','barrow-and-furness'),(26,'Basildon and Billericay','basildon-and-billericay'),(27,'Basingstoke','basingstoke'),(28,'Bassetlaw','bassetlaw'),(29,'Bath','bath'),(30,'Batley and Spen','batley-and-spen'),(31,'Battersea','battersea'),(32,'Beaconsfield','beaconsfield'),(33,'Beckenham','beckenham'),(34,'Bedford','bedford'),(35,'Belfast East','belfast-e'),(36,'Belfast North','belfast-n'),(37,'Belfast South','belfast-s'),(38,'Belfast West','belfast-w'),(39,'Bermondsey and Old Southwark','bermondsey-and-old-southwark'),(40,'Berwick-upon-Tweed','berwick-upon-tweed'),(41,'Berwickshire, Roxburgh and Selkirk','berwickshire-roxburgh-and-selkirk'),(42,'Bethnal Green and Bow','bethnal-green-and-bow'),(43,'Beverley and Holderness','beverley-and-holderness'),(44,'Bexhill and Battle','bexhill-and-battle'),(45,'Bexleyheath and Crayford','bexleyheath-and-crayford'),(46,'Birkenhead','birkenhead'),(47,'Birmingham, Edgbaston','birmingham-edgbaston'),(48,'Birmingham, Erdington','birmingham-erdington'),(49,'Birmingham, Hall Green','birmingham-hall-green'),(50,'Birmingham, Hodge Hill','birmingham-hodge-hill'),(51,'Birmingham, Ladywood','birmingham-ladywood'),(52,'Birmingham, Northfield','birmingham-northfield'),(53,'Birmingham, Perry Barr','birmingham-perry-barr'),(54,'Birmingham, Selly Oak','birmingham-selly-oak'),(55,'Birmingham, Yardley','birmingham-yardley'),(56,'Bishop Auckland','bishop-auckland'),(57,'Blackburn','blackburn'),(58,'Blackley and Broughton','blackley-and-broughton'),(59,'Blackpool North and Cleveleys','blackpool-n-and-cleveleys'),(60,'Blackpool South','blackpool-s'),(61,'Blaenau Gwent','blaenau-gwent'),(62,'Blaydon','blaydon'),(63,'Blyth Valley','blyth-valley'),(64,'Bognor Regis and Littlehampton','bognor-regis-and-littlehampton'),(65,'Bolsover','bolsover'),(66,'Bolton North East','bolton-n-e'),(67,'Bolton South East','bolton-s-e'),(68,'Bolton West','bolton-w'),(69,'Bootle','bootle'),(70,'Boston and Skegness','boston-and-skegness'),(71,'Bosworth','bosworth'),(72,'Bournemouth East','bournemouth-e'),(73,'Bournemouth West','bournemouth-w'),(74,'Bracknell','bracknell'),(75,'Bradford East','bradford-e'),(76,'Bradford South','bradford-s'),(77,'Bradford West','bradford-w'),(78,'Braintree','braintree'),(79,'Brecon and Radnorshire','brecon-and-radnorshire'),(80,'Brent Central','brent-central'),(81,'Brent North','brent-n'),(82,'Brentford and Isleworth','brentford-and-isleworth'),(83,'Brentwood and Ongar','brentwood-and-ongar'),(84,'Bridgend','bridgend'),(85,'Bridgwater and West Somerset','bridgwater-and-w-somerset'),(86,'Brigg and Goole','brigg-and-goole'),(87,'Brighton, Kemptown','brighton-kemptown'),(88,'Brighton, Pavilion','brighton-pavilion'),(89,'Bristol East','bristol-e'),(90,'Bristol North West','bristol-n-w'),(91,'Bristol South','bristol-s'),(92,'Bristol West','bristol-w'),(93,'Broadland','broadland'),(94,'Bromley and Chislehurst','bromley-and-chislehurst'),(95,'Bromsgrove','bromsgrove'),(96,'Broxbourne','broxbourne'),(97,'Broxtowe','broxtowe'),(98,'Buckingham','buckingham'),(99,'Burnley','burnley'),(100,'Burton','burton'),(101,'Bury North','bury-n'),(102,'Bury South','bury-s'),(103,'Bury St Edmunds','bury-st-edmunds'),(104,'Caerphilly','caerphilly'),(105,'Caithness, Sutherland and Easter Ross','caithness-sutherland-and-easter-ross'),(106,'Calder Valley','calder-valley'),(107,'Camberwell and Peckham','camberwell-and-peckham'),(108,'Camborne and Redruth','camborne-and-redruth'),(109,'Cambridge','cambridge'),(110,'Cannock Chase','cannock-chase'),(111,'Canterbury','canterbury'),(112,'Cardiff Central','cardiff-central'),(113,'Cardiff North','cardiff-n'),(114,'Cardiff South and Penarth','cardiff-s-and-penarth'),(115,'Cardiff West','cardiff-w'),(116,'Carlisle','carlisle'),(117,'Carmarthen East and Dinefwr','carmarthen-e-and-dinefwr'),(118,'Carmarthen West and South Pembrokeshire','carmarthen-w-and-s-pembrokeshire'),(119,'Carshalton and Wallington','carshalton-and-wallington'),(120,'Castle Point','castle-point'),(121,'Central Ayrshire','central-ayrshire'),(122,'Central Devon','central-devon'),(123,'Central Suffolk and North Ipswich','central-suffolk-and-n-ipswich'),(124,'Ceredigion','ceredigion'),(125,'Charnwood','charnwood'),(126,'Chatham and Aylesford','chatham-and-aylesford'),(127,'Cheadle','cheadle'),(128,'Chelmsford','chelmsford'),(129,'Chelsea and Fulham','chelsea-and-fulham'),(130,'Cheltenham','cheltenham'),(131,'Chesham and Amersham','chesham-and-amersham'),(132,'Chesterfield','chesterfield'),(133,'Chichester','chichester'),(134,'Chingford and Woodford Green','chingford-and-woodford-green'),(135,'Chippenham','chippenham'),(136,'Chipping Barnet','chipping-barnet'),(137,'Chorley','chorley'),(138,'Christchurch','christchurch'),(139,'Cities of London and Westminster','cities-of-london-and-westminster'),(140,'City of Chester','city-of-chester'),(141,'City of Durham','city-of-durham'),(142,'Clacton','clacton'),(143,'Cleethorpes','cleethorpes'),(144,'Clwyd South','clwyd-s'),(145,'Clwyd West','clwyd-w'),(146,'Coatbridge, Chryston and Bellshill','coatbridge-chryston-and-bellshill'),(147,'Colchester','colchester'),(148,'Colne Valley','colne-valley'),(149,'Congleton','congleton'),(150,'Copeland','copeland'),(151,'Corby','corby'),(152,'Coventry North East','coventry-n-e'),(153,'Coventry North West','coventry-n-w'),(154,'Coventry South','coventry-s'),(155,'Crawley','crawley'),(156,'Crewe and Nantwich','crewe-and-nantwich'),(157,'Croydon Central','croydon-central'),(158,'Croydon North','croydon-n'),(159,'Croydon South','croydon-s'),(160,'Cumbernauld, Kilsyth and Kirkintilloch East','cumbernauld-kilsyth-and-kirkintilloch-e'),(161,'Cynon Valley','cynon-valley'),(162,'Dagenham and Rainham','dagenham-and-rainham'),(163,'Darlington','darlington'),(164,'Dartford','dartford'),(165,'Daventry','daventry'),(166,'Delyn','delyn'),(167,'Denton and Reddish','denton-and-reddish'),(168,'Derby North','derby-n'),(169,'Derby South','derby-s'),(170,'Derbyshire Dales','derbyshire-dales'),(171,'Devizes','devizes'),(172,'Dewsbury','dewsbury'),(173,'Don Valley','don-valley'),(174,'Doncaster Central','doncaster-central'),(175,'Doncaster North','doncaster-n'),(176,'Dover','dover'),(177,'Dudley North','dudley-n'),(178,'Dudley South','dudley-s'),(179,'Dulwich and West Norwood','dulwich-and-w-norwood'),(180,'Dumfries and Galloway','dumfries-and-galloway'),(181,'Dumfriesshire, Clydesdale and Tweeddale','dumfriesshire-clydesdale-and-tweeddale'),(182,'Dundee East','dundee-e'),(183,'Dundee West','dundee-w'),(184,'Dunfermline and West Fife','dunfermline-and-w-fife'),(185,'Dwyfor Meirionnydd','dwyfor-meirionnydd'),(186,'Ealing Central and Acton','ealing-central-and-acton'),(187,'Ealing North','ealing-n'),(188,'Ealing, Southall','ealing-southall'),(189,'Easington','easington'),(190,'East Antrim','e-antrim'),(191,'East Devon','e-devon'),(192,'East Dunbartonshire','e-dunbartonshire'),(193,'East Ham','e-ham'),(194,'East Hampshire','e-hampshire'),(195,'East Kilbride, Strathaven and Lesmahagow','e-kilbride-strathaven-and-lesmahagow'),(196,'East Londonderry','e-londonderry'),(197,'East Lothian','e-lothian'),(198,'East Renfrewshire','e-renfrewshire'),(199,'East Surrey','e-surrey'),(200,'East Worthing and Shoreham','e-worthing-and-shoreham'),(201,'East Yorkshire','e-yorkshire'),(202,'Eastbourne','eastbourne'),(203,'Eastleigh','eastleigh'),(204,'Eddisbury','eddisbury'),(205,'Edinburgh East','edinburgh-e'),(206,'Edinburgh North and Leith','edinburgh-n-and-leith'),(207,'Edinburgh South','edinburgh-s'),(208,'Edinburgh South West','edinburgh-s-w'),(209,'Edinburgh West','edinburgh-w'),(210,'Edmonton','edmonton'),(211,'Ellesmere Port and Neston','ellesmere-port-and-neston'),(212,'Elmet and Rothwell','elmet-and-rothwell'),(213,'Eltham','eltham'),(214,'Enfield North','enfield-n'),(215,'Enfield, Southgate','enfield-southgate'),(216,'Epping Forest','epping-forest'),(217,'Epsom and Ewell','epsom-and-ewell'),(218,'Erewash','erewash'),(219,'Erith and Thamesmead','erith-and-thamesmead'),(220,'Esher and Walton','esher-and-walton'),(221,'Exeter','exeter'),(222,'Falkirk','falkirk'),(223,'Fareham','fareham'),(224,'Faversham and Mid Kent','faversham-and-mid-kent'),(225,'Feltham and Heston','feltham-and-heston'),(226,'Fermanagh and South Tyrone','fermanagh-and-s-tyrone'),(227,'Filton and Bradley Stoke','filton-and-bradley-stoke'),(228,'Finchley and Golders Green','finchley-and-golders-green'),(229,'Folkestone and Hythe','folkestone-and-hythe'),(230,'Forest of Dean','forest-of-dean'),(231,'Foyle','foyle'),(232,'Fylde','fylde'),(233,'Gainsborough','gainsborough'),(234,'Garston and Halewood','garston-and-halewood'),(235,'Gateshead','gateshead'),(236,'Gedling','gedling'),(237,'Gillingham and Rainham','gillingham-and-rainham'),(238,'Glasgow Central','glasgow-central'),(239,'Glasgow East','glasgow-e'),(240,'Glasgow North','glasgow-n'),(241,'Glasgow North East','glasgow-n-e'),(242,'Glasgow North West','glasgow-n-w'),(243,'Glasgow South','glasgow-s'),(244,'Glasgow South West','glasgow-s-w'),(245,'Glenrothes','glenrothes'),(246,'Gloucester','gloucester'),(247,'Gordon','gordon'),(248,'Gosport','gosport'),(249,'Gower','gower'),(250,'Grantham and Stamford','grantham-and-stamford'),(251,'Gravesham','gravesham'),(252,'Great Grimsby','great-grimsby'),(253,'Great Yarmouth','great-yarmouth'),(254,'Greenwich and Woolwich','greenwich-and-woolwich'),(255,'Guildford','guildford'),(256,'Hackney North and Stoke Newington','hackney-n-and-stoke-newington'),(257,'Hackney South and Shoreditch','hackney-s-and-shoreditch'),(258,'Halesowen and Rowley Regis','halesowen-and-rowley-regis'),(259,'Halifax','halifax'),(260,'Haltemprice and Howden','haltemprice-and-howden'),(261,'Halton','halton'),(262,'Hammersmith','hammersmith'),(263,'Hampstead and Kilburn','hampstead-and-kilburn'),(264,'Harborough','harborough'),(265,'Harlow','harlow'),(266,'Harrogate and Knaresborough','harrogate-and-knaresborough'),(267,'Harrow East','harrow-e'),(268,'Harrow West','harrow-w'),(269,'Hartlepool','hartlepool'),(270,'Harwich and North Essex','harwich-and-n-essex'),(271,'Hastings and Rye','hastings-and-rye'),(272,'Havant','havant'),(273,'Hayes and Harlington','hayes-and-harlington'),(274,'Hazel Grove','hazel-grove'),(275,'Hemel Hempstead','hemel-hempstead'),(276,'Hemsworth','hemsworth'),(277,'Hendon','hendon'),(278,'Henley','henley'),(279,'Hereford and South Herefordshire','hereford-and-s-herefordshire'),(280,'Hertford and Stortford','hertford-and-stortford'),(281,'Hertsmere','hertsmere'),(282,'Hexham','hexham'),(283,'Heywood and Middleton','heywood-and-middleton'),(284,'High Peak','high-peak'),(285,'Hitchin and Harpenden','hitchin-and-harpenden'),(286,'Holborn and St Pancras','holborn-and-st-pancras'),(287,'Hornchurch and Upminster','hornchurch-and-upminster'),(288,'Hornsey and Wood Green','hornsey-and-wood-green'),(289,'Horsham','horsham'),(290,'Houghton and Sunderland South','houghton-and-sunderland-s'),(291,'Hove','hove'),(292,'Huddersfield','huddersfield'),(293,'Huntingdon','huntingdon'),(294,'Hyndburn','hyndburn'),(295,'Ilford North','ilford-n'),(296,'Ilford South','ilford-s'),(297,'Inverclyde','inverclyde'),(298,'Inverness, Nairn, Badenoch and Strathspey','inverness-nairn-badenoch-and-strathspey'),(299,'Ipswich','ipswich'),(300,'Isle of Wight','isle-of-wight'),(301,'Islington North','islington-n'),(302,'Islington South and Finsbury','islington-s-and-finsbury'),(303,'Islwyn','islwyn'),(304,'Jarrow','jarrow'),(305,'Keighley','keighley'),(306,'Kenilworth and Southam','kenilworth-and-southam'),(307,'Kensington','kensington'),(308,'Kettering','kettering'),(309,'Kilmarnock and Loudoun','kilmarnock-and-loudoun'),(310,'Kingston and Surbiton','kingston-and-surbiton'),(311,'Kingston upon Hull East','kingston-upon-hull-e'),(312,'Kingston upon Hull North','kingston-upon-hull-n'),(313,'Kingston upon Hull West and Hessle','kingston-upon-hull-w-and-hessle'),(314,'Kingswood','kingswood'),(315,'Kirkcaldy and Cowdenbeath','kirkcaldy-and-cowdenbeath'),(316,'Knowsley','knowsley'),(317,'Lagan Valley','lagan-valley'),(318,'Lanark and Hamilton East','lanark-and-hamilton-e'),(319,'Lancaster and Fleetwood','lancaster-and-fleetwood'),(320,'Leeds Central','leeds-central'),(321,'Leeds East','leeds-e'),(322,'Leeds North East','leeds-n-e'),(323,'Leeds North West','leeds-n-w'),(324,'Leeds West','leeds-w'),(325,'Leicester East','leicester-e'),(326,'Leicester South','leicester-s'),(327,'Leicester West','leicester-w'),(328,'Leigh','leigh'),(329,'Lewes','lewes'),(330,'Lewisham East','lewisham-e'),(331,'Lewisham West and Penge','lewisham-w-and-penge'),(332,'Lewisham, Deptford','lewisham-deptford'),(333,'Leyton and Wanstead','leyton-and-wanstead'),(334,'Lichfield','lichfield'),(335,'Lincoln','lincoln'),(336,'Linlithgow and East Falkirk','linlithgow-and-e-falkirk'),(337,'Liverpool, Riverside','liverpool-riverside'),(338,'Liverpool, Walton','liverpool-walton'),(339,'Liverpool, Wavertree','liverpool-wavertree'),(340,'Liverpool, West Derby','liverpool-w-derby'),(341,'Livingston','livingston'),(342,'Llanelli','llanelli'),(343,'Loughborough','loughborough'),(344,'Louth and Horncastle','louth-and-horncastle'),(345,'Ludlow','ludlow'),(346,'Luton North','luton-n'),(347,'Luton South','luton-s'),(348,'Macclesfield','macclesfield'),(349,'Maidenhead','maidenhead'),(350,'Maidstone and The Weald','maidstone-and-the-weald'),(351,'Makerfield','makerfield'),(352,'Maldon','maldon'),(353,'Manchester Central','manchester-central'),(354,'Manchester, Gorton','manchester-gorton'),(355,'Manchester, Withington','manchester-withington'),(356,'Mansfield','mansfield'),(357,'Meon Valley','meon-valley'),(358,'Meriden','meriden'),(359,'Merthyr Tydfil and Rhymney','merthyr-tydfil-and-rhymney'),(360,'Mid Bedfordshire','mid-bedfordshire'),(361,'Mid Derbyshire','mid-derbyshire'),(362,'Mid Dorset and North Poole','mid-dorset-and-n-poole'),(363,'Mid Norfolk','mid-norfolk'),(364,'Mid Sussex','mid-sussex'),(365,'Mid Ulster','mid-ulster'),(366,'Mid Worcestershire','mid-worcestershire'),(367,'Middlesbrough','middlesbrough'),(368,'Middlesbrough South and East Cleveland','middlesbrough-s-and-e-cleveland'),(369,'Midlothian','midlothian'),(370,'Milton Keynes North','milton-keynes-n'),(371,'Milton Keynes South','milton-keynes-s'),(372,'Mitcham and Morden','mitcham-and-morden'),(373,'Mole Valley','mole-valley'),(374,'Monmouth','monmouth'),(375,'Montgomeryshire','montgomeryshire'),(376,'Moray','moray'),(377,'Morecambe and Lunesdale','morecambe-and-lunesdale'),(378,'Morley and Outwood','morley-and-outwood'),(379,'Motherwell and Wishaw','motherwell-and-wishaw'),(380,'Na h-Eileanan an Iar','na-h-eileanan-an-iar'),(381,'Neath','neath'),(382,'New Forest East','new-forest-e'),(383,'New Forest West','new-forest-w'),(384,'Newark','newark'),(385,'Newbury','newbury'),(386,'Newcastle upon Tyne Central','newcastle-upon-tyne-central'),(387,'Newcastle upon Tyne East','newcastle-upon-tyne-e'),(388,'Newcastle upon Tyne North','newcastle-upon-tyne-n'),(389,'Newcastle-under-Lyme','newcastle-under-lyme'),(390,'Newport East','newport-e'),(391,'Newport West','newport-w'),(392,'Newry and Armagh','newry-and-armagh'),(393,'Newton Abbot','newton-abbot'),(394,'Normanton, Pontefract and Castleford','normanton-pontefract-and-castleford'),(395,'North Antrim','n-antrim'),(396,'North Ayrshire and Arran','n-ayrshire-and-arran'),(397,'North Cornwall','n-cornwall'),(398,'North Devon','n-devon'),(399,'North Dorset','n-dorset'),(400,'North Down','n-down'),(401,'North Durham','n-durham'),(402,'North East Bedfordshire','n-e-bedfordshire'),(403,'North East Cambridgeshire','n-e-cambridgeshire'),(404,'North East Derbyshire','n-e-derbyshire'),(405,'North East Fife','n-e-fife'),(406,'North East Hampshire','n-e-hampshire'),(407,'North East Hertfordshire','n-e-hertfordshire'),(408,'North East Somerset','n-e-somerset'),(409,'North Herefordshire','n-herefordshire'),(410,'North Norfolk','n-norfolk'),(411,'North Shropshire','n-shropshire'),(412,'North Somerset','n-somerset'),(413,'North Swindon','n-swindon'),(414,'North Thanet','n-thanet'),(415,'North Tyneside','n-tyneside'),(416,'North Warwickshire','n-warwickshire'),(417,'North West Cambridgeshire','n-w-cambridgeshire'),(418,'North West Durham','n-w-durham'),(419,'North West Hampshire','n-w-hampshire'),(420,'North West Leicestershire','n-w-leicestershire'),(421,'North West Norfolk','n-w-norfolk'),(422,'North Wiltshire','n-wiltshire'),(423,'Northampton North','northampton-n'),(424,'Northampton South','northampton-s'),(425,'Norwich North','norwich-n'),(426,'Norwich South','norwich-s'),(427,'Nottingham East','nottingham-e'),(428,'Nottingham North','nottingham-n'),(429,'Nottingham South','nottingham-s'),(430,'Nuneaton','nuneaton'),(431,'Ochil and South Perthshire','ochil-and-s-perthshire'),(432,'Ogmore','ogmore'),(433,'Old Bexley and Sidcup','old-bexley-and-sidcup'),(434,'Oldham East and Saddleworth','oldham-e-and-saddleworth'),(435,'Oldham West and Royton','oldham-w-and-royton'),(436,'Orkney and Shetland','orkney-and-shetland'),(437,'Orpington','orpington'),(438,'Oxford East','oxford-e'),(439,'Oxford West and Abingdon','oxford-w-and-abingdon'),(440,'Paisley and Renfrewshire North','paisley-and-renfrewshire-n'),(441,'Paisley and Renfrewshire South','paisley-and-renfrewshire-s'),(442,'Pendle','pendle'),(443,'Penistone and Stocksbridge','penistone-and-stocksbridge'),(444,'Penrith and The Border','penrith-and-the-border'),(445,'Perth and North Perthshire','perth-and-n-perthshire'),(446,'Peterborough','peterborough'),(447,'Plymouth, Moor View','plymouth-moor-view'),(448,'Plymouth, Sutton and Devonport','plymouth-sutton-and-devonport'),(449,'Pontypridd','pontypridd'),(450,'Poole','poole'),(451,'Poplar and Limehouse','poplar-and-limehouse'),(452,'Portsmouth North','portsmouth-n'),(453,'Portsmouth South','portsmouth-s'),(454,'Preseli Pembrokeshire','preseli-pembrokeshire'),(455,'Preston','preston'),(456,'Pudsey','pudsey'),(457,'Putney','putney'),(458,'Rayleigh and Wickford','rayleigh-and-wickford'),(459,'Reading East','reading-e'),(460,'Reading West','reading-w'),(461,'Redcar','redcar'),(462,'Redditch','redditch'),(463,'Reigate','reigate'),(464,'Rhondda','rhondda'),(465,'Ribble Valley','ribble-valley'),(466,'Richmond (Yorks)','richmond-yorks-'),(467,'Richmond Park','richmond-park'),(468,'Rochdale','rochdale'),(469,'Rochester and Strood','rochester-and-strood'),(470,'Rochford and Southend East','rochford-and-southend-e'),(471,'Romford','romford'),(472,'Romsey and Southampton North','romsey-and-southampton-n'),(473,'Ross, Skye and Lochaber','ross-skye-and-lochaber'),(474,'Rossendale and Darwen','rossendale-and-darwen'),(475,'Rother Valley','rother-valley'),(476,'Rotherham','rotherham'),(477,'Rugby','rugby'),(478,'Ruislip, Northwood and Pinner','ruislip-northwood-and-pinner'),(479,'Runnymede and Weybridge','runnymede-and-weybridge'),(480,'Rushcliffe','rushcliffe'),(481,'Rutherglen and Hamilton West','rutherglen-and-hamilton-w'),(482,'Rutland and Melton','rutland-and-melton'),(483,'Saffron Walden','saffron-walden'),(484,'Salford and Eccles','salford-and-eccles'),(485,'Salisbury','salisbury'),(486,'Scarborough and Whitby','scarborough-and-whitby'),(487,'Scunthorpe','scunthorpe'),(488,'Sedgefield','sedgefield'),(489,'Sefton Central','sefton-central'),(490,'Selby and Ainsty','selby-and-ainsty'),(491,'Sevenoaks','sevenoaks'),(492,'Sheffield Central','sheffield-central'),(493,'Sheffield South East','sheffield-s-e'),(494,'Sheffield, Brightside and Hillsborough','sheffield-brightside-and-hillsborough'),(495,'Sheffield, Hallam','sheffield-hallam'),(496,'Sheffield, Heeley','sheffield-heeley'),(497,'Sherwood','sherwood'),(498,'Shipley','shipley'),(499,'Shrewsbury and Atcham','shrewsbury-and-atcham'),(500,'Sittingbourne and Sheppey','sittingbourne-and-sheppey'),(501,'Skipton and Ripon','skipton-and-ripon'),(502,'Sleaford and North Hykeham','sleaford-and-n-hykeham'),(503,'Slough','slough'),(504,'Solihull','solihull'),(505,'Somerton and Frome','somerton-and-frome'),(506,'South Antrim','s-antrim'),(507,'South Basildon and East Thurrock','s-basildon-and-e-thurrock'),(508,'South Cambridgeshire','s-cambridgeshire'),(509,'South Derbyshire','s-derbyshire'),(510,'South Dorset','s-dorset'),(511,'South Down','s-down'),(512,'South East Cambridgeshire','s-e-cambridgeshire'),(513,'South East Cornwall','s-e-cornwall'),(514,'South Holland and The Deepings','s-holland-and-the-deepings'),(515,'South Leicestershire','s-leicestershire'),(516,'South Norfolk','s-norfolk'),(517,'South Northamptonshire','s-northamptonshire'),(518,'South Ribble','s-ribble'),(519,'South Shields','s-shields'),(520,'South Staffordshire','s-staffordshire'),(521,'South Suffolk','s-suffolk'),(522,'South Swindon','s-swindon'),(523,'South Thanet','s-thanet'),(524,'South West Bedfordshire','s-w-bedfordshire'),(525,'South West Devon','s-w-devon'),(526,'South West Hertfordshire','s-w-hertfordshire'),(527,'South West Norfolk','s-w-norfolk'),(528,'South West Surrey','s-w-surrey'),(529,'South West Wiltshire','s-w-wiltshire'),(530,'Southampton, Itchen','southampton-itchen'),(531,'Southampton, Test','southampton-test'),(532,'Southend West','southend-w'),(533,'Southport','southport'),(534,'Spelthorne','spelthorne'),(535,'St Albans','st-albans'),(536,'St Austell and Newquay','st-austell-and-newquay'),(537,'St Helens North','st-helens-n'),(538,'St Helens South and Whiston','st-helens-s-and-whiston'),(539,'St Ives','st-ives'),(540,'Stafford','stafford'),(541,'Staffordshire Moorlands','staffordshire-moorlands'),(542,'Stalybridge and Hyde','stalybridge-and-hyde'),(543,'Stevenage','stevenage'),(544,'Stirling','stirling'),(545,'Stockport','stockport'),(546,'Stockton North','stockton-n'),(547,'Stockton South','stockton-s'),(548,'Stoke-on-Trent Central','stoke-on-trent-central'),(549,'Stoke-on-Trent North','stoke-on-trent-n'),(550,'Stoke-on-Trent South','stoke-on-trent-s'),(551,'Stone','stone'),(552,'Stourbridge','stourbridge'),(553,'Strangford','strangford'),(554,'Stratford-on-Avon','stratford-on-avon'),(555,'Streatham','streatham'),(556,'Stretford and Urmston','stretford-and-urmston'),(557,'Stroud','stroud'),(558,'Suffolk Coastal','suffolk-coastal'),(559,'Sunderland Central','sunderland-central'),(560,'Surrey Heath','surrey-heath'),(561,'Sutton and Cheam','sutton-and-cheam'),(562,'Sutton Coldfield','sutton-coldfield'),(563,'Swansea East','swansea-e'),(564,'Swansea West','swansea-w'),(565,'Tamworth','tamworth'),(566,'Tatton','tatton'),(567,'Taunton Deane','taunton-deane'),(568,'Telford','telford'),(569,'Tewkesbury','tewkesbury'),(570,'The Cotswolds','the-cotswolds'),(571,'The Wrekin','the-wrekin'),(572,'Thirsk and Malton','thirsk-and-malton'),(573,'Thornbury and Yate','thornbury-and-yate'),(574,'Thurrock','thurrock'),(575,'Tiverton and Honiton','tiverton-and-honiton'),(576,'Tonbridge and Malling','tonbridge-and-malling'),(577,'Tooting','tooting'),(578,'Torbay','torbay'),(579,'Torfaen','torfaen'),(580,'Torridge and West Devon','torridge-and-w-devon'),(581,'Totnes','totnes'),(582,'Tottenham','tottenham'),(583,'Truro and Falmouth','truro-and-falmouth'),(584,'Tunbridge Wells','tunbridge-wells'),(585,'Twickenham','twickenham'),(586,'Tynemouth','tynemouth'),(587,'Upper Bann','upper-bann'),(588,'Uxbridge and South Ruislip','uxbridge-and-s-ruislip'),(589,'Vale of Clwyd','vale-of-clwyd'),(590,'Vale of Glamorgan','vale-of-glamorgan'),(591,'Vauxhall','vauxhall'),(592,'Wakefield','wakefield'),(593,'Wallasey','wallasey'),(594,'Walsall North','walsall-n'),(595,'Walsall South','walsall-s'),(596,'Walthamstow','walthamstow'),(597,'Wansbeck','wansbeck'),(598,'Wantage','wantage'),(599,'Warley','warley'),(600,'Warrington North','warrington-n'),(601,'Warrington South','warrington-s'),(602,'Warwick and Leamington','warwick-and-leamington'),(603,'Washington and Sunderland West','washington-and-sunderland-w'),(604,'Watford','watford'),(605,'Waveney','waveney'),(606,'Wealden','wealden'),(607,'Weaver Vale','weaver-vale'),(608,'Wellingborough','wellingborough'),(609,'Wells','wells'),(610,'Welwyn Hatfield','welwyn-hatfield'),(611,'Wentworth and Dearne','wentworth-and-dearne'),(612,'West Aberdeenshire and Kincardine','w-aberdeenshire-and-kincardine'),(613,'West Bromwich East','w-bromwich-e'),(614,'West Bromwich West','w-bromwich-west'),(615,'West Dorset','w-dorset'),(616,'West Dunbartonshire','w-dunbartonshire'),(617,'West Ham','w-ham'),(618,'West Lancashire','w-lancashire'),(619,'West Suffolk','w-suffolk'),(620,'West Tyrone','w-tyrone'),(621,'West Worcestershire','w-worcestershire'),(622,'Westminster North','westminster-n'),(623,'Westmorland and Lonsdale','westmorland-and-lonsdale'),(624,'Weston-Super-Mare','weston-super-mare'),(625,'Wigan','wigan'),(626,'Wimbledon','wimbledon'),(627,'Winchester','winchester'),(628,'Windsor','windsor'),(629,'Wirral South','wirral-s'),(630,'Wirral West','wirral-w'),(631,'Witham','witham'),(632,'Witney','witney'),(633,'Woking','woking'),(634,'Wokingham','wokingham'),(635,'Wolverhampton North East','wolverhampton-n-e'),(636,'Wolverhampton South East','wolverhampton-s-e'),(637,'Wolverhampton South West','wolverhampton-s-w'),(638,'Worcester','worcester'),(639,'Workington','workington'),(640,'Worsley and Eccles South','worsley-and-eccles-s'),(641,'Worthing West','worthing-w'),(642,'Wrexham','wrexham'),(643,'Wycombe','wycombe'),(644,'Wyre and Preston North','wyre-and-preston-n'),(645,'Wyre Forest','wyre-forest'),(646,'Wythenshawe and Sale East','wythenshawe-and-sale-e'),(647,'Yeovil','yeovil'),(648,'Ynys Môn','ynys-mon'),(649,'York Central','york-central'),(650,'York Outer','york-outer');
+INSERT INTO `constituency` VALUES (1,'Aberavon','aberavon',NULL),(2,'Aberconwy','aberconwy',NULL),(3,'Aberdeen North','aberdeen-north',NULL),(4,'Aberdeen South','aberdeen-south',NULL),(5,'Airdrie and Shotts','airdrie-and-shotts',NULL),(6,'Aldershot','aldershot',NULL),(7,'Aldridge-Brownhills','aldridge-brownhills',NULL),(8,'Altrincham and Sale West','altrincham-and-sale-w',NULL),(9,'Alyn and Deeside','alyn-and-deeside',NULL),(10,'Amber Valley','amber-valley',NULL),(11,'Angus','angus',NULL),(12,'Arfon','arfon',NULL),(13,'Argyll and Bute','argyll-and-bute',NULL),(14,'Arundel and South Downs','arundel-and-s-downs',NULL),(15,'Ashfield','ashfield',NULL),(16,'Ashford','ashford',NULL),(17,'Ashton-under-Lyne','ashton-under-lyne',NULL),(18,'Aylesbury','aylesbury',NULL),(19,'Ayr, Carrick and Cumnock','ayr-carrick-and-cumnock',NULL),(20,'Banbury','banbury',NULL),(21,'Banff and Buchan','banff-and-buchan',NULL),(22,'Barking','barking',NULL),(23,'Barnsley Central','barnsley-central',NULL),(24,'Barnsley East','barnsley-e',NULL),(25,'Barrow and Furness','barrow-and-furness',NULL),(26,'Basildon and Billericay','basildon-and-billericay',NULL),(27,'Basingstoke','basingstoke',NULL),(28,'Bassetlaw','bassetlaw',NULL),(29,'Bath','bath',NULL),(30,'Batley and Spen','batley-and-spen',NULL),(31,'Battersea','battersea',NULL),(32,'Beaconsfield','beaconsfield',NULL),(33,'Beckenham','beckenham',NULL),(34,'Bedford','bedford',NULL),(35,'Belfast East','belfast-e',NULL),(36,'Belfast North','belfast-n',NULL),(37,'Belfast South','belfast-s',NULL),(38,'Belfast West','belfast-w',NULL),(39,'Bermondsey and Old Southwark','bermondsey-and-old-southwark',NULL),(40,'Berwick-upon-Tweed','berwick-upon-tweed',NULL),(41,'Berwickshire, Roxburgh and Selkirk','berwickshire-roxburgh-and-selkirk',NULL),(42,'Bethnal Green and Bow','bethnal-green-and-bow',NULL),(43,'Beverley and Holderness','beverley-and-holderness',NULL),(44,'Bexhill and Battle','bexhill-and-battle',NULL),(45,'Bexleyheath and Crayford','bexleyheath-and-crayford',NULL),(46,'Birkenhead','birkenhead',NULL),(47,'Birmingham, Edgbaston','birmingham-edgbaston',NULL),(48,'Birmingham, Erdington','birmingham-erdington',NULL),(49,'Birmingham, Hall Green','birmingham-hall-green',NULL),(50,'Birmingham, Hodge Hill','birmingham-hodge-hill',NULL),(51,'Birmingham, Ladywood','birmingham-ladywood',NULL),(52,'Birmingham, Northfield','birmingham-northfield',NULL),(53,'Birmingham, Perry Barr','birmingham-perry-barr',NULL),(54,'Birmingham, Selly Oak','birmingham-selly-oak',NULL),(55,'Birmingham, Yardley','birmingham-yardley',NULL),(56,'Bishop Auckland','bishop-auckland',NULL),(57,'Blackburn','blackburn',NULL),(58,'Blackley and Broughton','blackley-and-broughton',NULL),(59,'Blackpool North and Cleveleys','blackpool-n-and-cleveleys',NULL),(60,'Blackpool South','blackpool-s',NULL),(61,'Blaenau Gwent','blaenau-gwent',NULL),(62,'Blaydon','blaydon',NULL),(63,'Blyth Valley','blyth-valley',NULL),(64,'Bognor Regis and Littlehampton','bognor-regis-and-littlehampton',NULL),(65,'Bolsover','bolsover',NULL),(66,'Bolton North East','bolton-n-e',NULL),(67,'Bolton South East','bolton-s-e',NULL),(68,'Bolton West','bolton-w',NULL),(69,'Bootle','bootle',NULL),(70,'Boston and Skegness','boston-and-skegness',NULL),(71,'Bosworth','bosworth',NULL),(72,'Bournemouth East','bournemouth-e',NULL),(73,'Bournemouth West','bournemouth-w',NULL),(74,'Bracknell','bracknell',NULL),(75,'Bradford East','bradford-e',NULL),(76,'Bradford South','bradford-s',NULL),(77,'Bradford West','bradford-w',NULL),(78,'Braintree','braintree',NULL),(79,'Brecon and Radnorshire','brecon-and-radnorshire',NULL),(80,'Brent Central','brent-central',NULL),(81,'Brent North','brent-n',NULL),(82,'Brentford and Isleworth','brentford-and-isleworth',NULL),(83,'Brentwood and Ongar','brentwood-and-ongar',NULL),(84,'Bridgend','bridgend',NULL),(85,'Bridgwater and West Somerset','bridgwater-and-w-somerset',NULL),(86,'Brigg and Goole','brigg-and-goole',NULL),(87,'Brighton, Kemptown','brighton-kemptown',NULL),(88,'Brighton, Pavilion','brighton-pavilion',NULL),(89,'Bristol East','bristol-e',NULL),(90,'Bristol North West','bristol-n-w',NULL),(91,'Bristol South','bristol-s',NULL),(92,'Bristol West','bristol-w',NULL),(93,'Broadland','broadland',NULL),(94,'Bromley and Chislehurst','bromley-and-chislehurst',NULL),(95,'Bromsgrove','bromsgrove',NULL),(96,'Broxbourne','broxbourne',NULL),(97,'Broxtowe','broxtowe',NULL),(98,'Buckingham','buckingham',NULL),(99,'Burnley','burnley',NULL),(100,'Burton','burton',NULL),(101,'Bury North','bury-n',NULL),(102,'Bury South','bury-s',NULL),(103,'Bury St Edmunds','bury-st-edmunds',NULL),(104,'Caerphilly','caerphilly',NULL),(105,'Caithness, Sutherland and Easter Ross','caithness-sutherland-and-easter-ross',NULL),(106,'Calder Valley','calder-valley',NULL),(107,'Camberwell and Peckham','camberwell-and-peckham',NULL),(108,'Camborne and Redruth','camborne-and-redruth',NULL),(109,'Cambridge','cambridge',NULL),(110,'Cannock Chase','cannock-chase',NULL),(111,'Canterbury','canterbury',NULL),(112,'Cardiff Central','cardiff-central',NULL),(113,'Cardiff North','cardiff-n',NULL),(114,'Cardiff South and Penarth','cardiff-s-and-penarth',NULL),(115,'Cardiff West','cardiff-w',NULL),(116,'Carlisle','carlisle',NULL),(117,'Carmarthen East and Dinefwr','carmarthen-e-and-dinefwr',NULL),(118,'Carmarthen West and South Pembrokeshire','carmarthen-w-and-s-pembrokeshire',NULL),(119,'Carshalton and Wallington','carshalton-and-wallington',NULL),(120,'Castle Point','castle-point',NULL),(121,'Central Ayrshire','central-ayrshire',NULL),(122,'Central Devon','central-devon',NULL),(123,'Central Suffolk and North Ipswich','central-suffolk-and-n-ipswich',NULL),(124,'Ceredigion','ceredigion',NULL),(125,'Charnwood','charnwood',NULL),(126,'Chatham and Aylesford','chatham-and-aylesford',NULL),(127,'Cheadle','cheadle',NULL),(128,'Chelmsford','chelmsford',NULL),(129,'Chelsea and Fulham','chelsea-and-fulham',NULL),(130,'Cheltenham','cheltenham',NULL),(131,'Chesham and Amersham','chesham-and-amersham',NULL),(132,'Chesterfield','chesterfield',NULL),(133,'Chichester','chichester',NULL),(134,'Chingford and Woodford Green','chingford-and-woodford-green',NULL),(135,'Chippenham','chippenham',NULL),(136,'Chipping Barnet','chipping-barnet',NULL),(137,'Chorley','chorley',NULL),(138,'Christchurch','christchurch',NULL),(139,'Cities of London and Westminster','cities-of-london-and-westminster',NULL),(140,'City of Chester','city-of-chester',NULL),(141,'City of Durham','city-of-durham',NULL),(142,'Clacton','clacton',NULL),(143,'Cleethorpes','cleethorpes',NULL),(144,'Clwyd South','clwyd-s',NULL),(145,'Clwyd West','clwyd-w',NULL),(146,'Coatbridge, Chryston and Bellshill','coatbridge-chryston-and-bellshill',NULL),(147,'Colchester','colchester',NULL),(148,'Colne Valley','colne-valley',NULL),(149,'Congleton','congleton',NULL),(150,'Copeland','copeland',NULL),(151,'Corby','corby',NULL),(152,'Coventry North East','coventry-n-e',NULL),(153,'Coventry North West','coventry-n-w',NULL),(154,'Coventry South','coventry-s',NULL),(155,'Crawley','crawley',NULL),(156,'Crewe and Nantwich','crewe-and-nantwich',NULL),(157,'Croydon Central','croydon-central',NULL),(158,'Croydon North','croydon-n',NULL),(159,'Croydon South','croydon-s',NULL),(160,'Cumbernauld, Kilsyth and Kirkintilloch East','cumbernauld-kilsyth-and-kirkintilloch-e',NULL),(161,'Cynon Valley','cynon-valley',NULL),(162,'Dagenham and Rainham','dagenham-and-rainham',NULL),(163,'Darlington','darlington',NULL),(164,'Dartford','dartford',NULL),(165,'Daventry','daventry',NULL),(166,'Delyn','delyn',NULL),(167,'Denton and Reddish','denton-and-reddish',NULL),(168,'Derby North','derby-n',NULL),(169,'Derby South','derby-s',NULL),(170,'Derbyshire Dales','derbyshire-dales',NULL),(171,'Devizes','devizes',NULL),(172,'Dewsbury','dewsbury',NULL),(173,'Don Valley','don-valley',NULL),(174,'Doncaster Central','doncaster-central',NULL),(175,'Doncaster North','doncaster-n',NULL),(176,'Dover','dover',NULL),(177,'Dudley North','dudley-n',NULL),(178,'Dudley South','dudley-s',NULL),(179,'Dulwich and West Norwood','dulwich-and-w-norwood',NULL),(180,'Dumfries and Galloway','dumfries-and-galloway',NULL),(181,'Dumfriesshire, Clydesdale and Tweeddale','dumfriesshire-clydesdale-and-tweeddale',NULL),(182,'Dundee East','dundee-e',NULL),(183,'Dundee West','dundee-w',NULL),(184,'Dunfermline and West Fife','dunfermline-and-w-fife',NULL),(185,'Dwyfor Meirionnydd','dwyfor-meirionnydd',NULL),(186,'Ealing Central and Acton','ealing-central-and-acton',NULL),(187,'Ealing North','ealing-n',NULL),(188,'Ealing, Southall','ealing-southall',NULL),(189,'Easington','easington',NULL),(190,'East Antrim','e-antrim',NULL),(191,'East Devon','e-devon',NULL),(192,'East Dunbartonshire','e-dunbartonshire',NULL),(193,'East Ham','e-ham',NULL),(194,'East Hampshire','e-hampshire',NULL),(195,'East Kilbride, Strathaven and Lesmahagow','e-kilbride-strathaven-and-lesmahagow',NULL),(196,'East Londonderry','e-londonderry',NULL),(197,'East Lothian','e-lothian',NULL),(198,'East Renfrewshire','e-renfrewshire',NULL),(199,'East Surrey','e-surrey',NULL),(200,'East Worthing and Shoreham','e-worthing-and-shoreham',NULL),(201,'East Yorkshire','e-yorkshire',NULL),(202,'Eastbourne','eastbourne',NULL),(203,'Eastleigh','eastleigh',NULL),(204,'Eddisbury','eddisbury',NULL),(205,'Edinburgh East','edinburgh-e',NULL),(206,'Edinburgh North and Leith','edinburgh-n-and-leith',NULL),(207,'Edinburgh South','edinburgh-s',NULL),(208,'Edinburgh South West','edinburgh-s-w',NULL),(209,'Edinburgh West','edinburgh-w',NULL),(210,'Edmonton','edmonton',NULL),(211,'Ellesmere Port and Neston','ellesmere-port-and-neston',NULL),(212,'Elmet and Rothwell','elmet-and-rothwell',NULL),(213,'Eltham','eltham',NULL),(214,'Enfield North','enfield-n',NULL),(215,'Enfield, Southgate','enfield-southgate',NULL),(216,'Epping Forest','epping-forest',NULL),(217,'Epsom and Ewell','epsom-and-ewell',NULL),(218,'Erewash','erewash',NULL),(219,'Erith and Thamesmead','erith-and-thamesmead',NULL),(220,'Esher and Walton','esher-and-walton',NULL),(221,'Exeter','exeter',NULL),(222,'Falkirk','falkirk',NULL),(223,'Fareham','fareham',NULL),(224,'Faversham and Mid Kent','faversham-and-mid-kent',NULL),(225,'Feltham and Heston','feltham-and-heston',NULL),(226,'Fermanagh and South Tyrone','fermanagh-and-s-tyrone',NULL),(227,'Filton and Bradley Stoke','filton-and-bradley-stoke',NULL),(228,'Finchley and Golders Green','finchley-and-golders-green',NULL),(229,'Folkestone and Hythe','folkestone-and-hythe',NULL),(230,'Forest of Dean','forest-of-dean',NULL),(231,'Foyle','foyle',NULL),(232,'Fylde','fylde',NULL),(233,'Gainsborough','gainsborough',NULL),(234,'Garston and Halewood','garston-and-halewood',NULL),(235,'Gateshead','gateshead',NULL),(236,'Gedling','gedling',NULL),(237,'Gillingham and Rainham','gillingham-and-rainham',NULL),(238,'Glasgow Central','glasgow-central',NULL),(239,'Glasgow East','glasgow-e',NULL),(240,'Glasgow North','glasgow-n',NULL),(241,'Glasgow North East','glasgow-n-e',NULL),(242,'Glasgow North West','glasgow-n-w',NULL),(243,'Glasgow South','glasgow-s',NULL),(244,'Glasgow South West','glasgow-s-w',NULL),(245,'Glenrothes','glenrothes',NULL),(246,'Gloucester','gloucester',NULL),(247,'Gordon','gordon',NULL),(248,'Gosport','gosport',NULL),(249,'Gower','gower',NULL),(250,'Grantham and Stamford','grantham-and-stamford',NULL),(251,'Gravesham','gravesham',NULL),(252,'Great Grimsby','great-grimsby',NULL),(253,'Great Yarmouth','great-yarmouth',NULL),(254,'Greenwich and Woolwich','greenwich-and-woolwich',NULL),(255,'Guildford','guildford',NULL),(256,'Hackney North and Stoke Newington','hackney-n-and-stoke-newington',NULL),(257,'Hackney South and Shoreditch','hackney-s-and-shoreditch',NULL),(258,'Halesowen and Rowley Regis','halesowen-and-rowley-regis',NULL),(259,'Halifax','halifax',NULL),(260,'Haltemprice and Howden','haltemprice-and-howden',NULL),(261,'Halton','halton',NULL),(262,'Hammersmith','hammersmith',NULL),(263,'Hampstead and Kilburn','hampstead-and-kilburn',NULL),(264,'Harborough','harborough',NULL),(265,'Harlow','harlow',NULL),(266,'Harrogate and Knaresborough','harrogate-and-knaresborough',NULL),(267,'Harrow East','harrow-e',NULL),(268,'Harrow West','harrow-w',NULL),(269,'Hartlepool','hartlepool',NULL),(270,'Harwich and North Essex','harwich-and-n-essex',NULL),(271,'Hastings and Rye','hastings-and-rye',NULL),(272,'Havant','havant',NULL),(273,'Hayes and Harlington','hayes-and-harlington',NULL),(274,'Hazel Grove','hazel-grove',NULL),(275,'Hemel Hempstead','hemel-hempstead',NULL),(276,'Hemsworth','hemsworth',NULL),(277,'Hendon','hendon',NULL),(278,'Henley','henley',NULL),(279,'Hereford and South Herefordshire','hereford-and-s-herefordshire',NULL),(280,'Hertford and Stortford','hertford-and-stortford',NULL),(281,'Hertsmere','hertsmere',NULL),(282,'Hexham','hexham',NULL),(283,'Heywood and Middleton','heywood-and-middleton',NULL),(284,'High Peak','high-peak',NULL),(285,'Hitchin and Harpenden','hitchin-and-harpenden',NULL),(286,'Holborn and St Pancras','holborn-and-st-pancras',NULL),(287,'Hornchurch and Upminster','hornchurch-and-upminster',NULL),(288,'Hornsey and Wood Green','hornsey-and-wood-green',NULL),(289,'Horsham','horsham',NULL),(290,'Houghton and Sunderland South','houghton-and-sunderland-s',NULL),(291,'Hove','hove',NULL),(292,'Huddersfield','huddersfield',NULL),(293,'Huntingdon','huntingdon',NULL),(294,'Hyndburn','hyndburn',NULL),(295,'Ilford North','ilford-n',NULL),(296,'Ilford South','ilford-s',NULL),(297,'Inverclyde','inverclyde',NULL),(298,'Inverness, Nairn, Badenoch and Strathspey','inverness-nairn-badenoch-and-strathspey',NULL),(299,'Ipswich','ipswich',NULL),(300,'Isle of Wight','isle-of-wight',NULL),(301,'Islington North','islington-n',NULL),(302,'Islington South and Finsbury','islington-s-and-finsbury',NULL),(303,'Islwyn','islwyn',NULL),(304,'Jarrow','jarrow',NULL),(305,'Keighley','keighley',NULL),(306,'Kenilworth and Southam','kenilworth-and-southam',NULL),(307,'Kensington','kensington',NULL),(308,'Kettering','kettering',NULL),(309,'Kilmarnock and Loudoun','kilmarnock-and-loudoun',NULL),(310,'Kingston and Surbiton','kingston-and-surbiton',NULL),(311,'Kingston upon Hull East','kingston-upon-hull-e',NULL),(312,'Kingston upon Hull North','kingston-upon-hull-n',NULL),(313,'Kingston upon Hull West and Hessle','kingston-upon-hull-w-and-hessle',NULL),(314,'Kingswood','kingswood',NULL),(315,'Kirkcaldy and Cowdenbeath','kirkcaldy-and-cowdenbeath',NULL),(316,'Knowsley','knowsley',NULL),(317,'Lagan Valley','lagan-valley',NULL),(318,'Lanark and Hamilton East','lanark-and-hamilton-e',NULL),(319,'Lancaster and Fleetwood','lancaster-and-fleetwood',NULL),(320,'Leeds Central','leeds-central',NULL),(321,'Leeds East','leeds-e',NULL),(322,'Leeds North East','leeds-n-e',NULL),(323,'Leeds North West','leeds-n-w',NULL),(324,'Leeds West','leeds-w',NULL),(325,'Leicester East','leicester-e',NULL),(326,'Leicester South','leicester-s',NULL),(327,'Leicester West','leicester-w',NULL),(328,'Leigh','leigh',NULL),(329,'Lewes','lewes',NULL),(330,'Lewisham East','lewisham-e',NULL),(331,'Lewisham West and Penge','lewisham-w-and-penge',NULL),(332,'Lewisham, Deptford','lewisham-deptford',NULL),(333,'Leyton and Wanstead','leyton-and-wanstead',NULL),(334,'Lichfield','lichfield',NULL),(335,'Lincoln','lincoln',NULL),(336,'Linlithgow and East Falkirk','linlithgow-and-e-falkirk',NULL),(337,'Liverpool, Riverside','liverpool-riverside',NULL),(338,'Liverpool, Walton','liverpool-walton',NULL),(339,'Liverpool, Wavertree','liverpool-wavertree',NULL),(340,'Liverpool, West Derby','liverpool-w-derby',NULL),(341,'Livingston','livingston',NULL),(342,'Llanelli','llanelli',NULL),(343,'Loughborough','loughborough',NULL),(344,'Louth and Horncastle','louth-and-horncastle',NULL),(345,'Ludlow','ludlow',NULL),(346,'Luton North','luton-n',NULL),(347,'Luton South','luton-s',NULL),(348,'Macclesfield','macclesfield',NULL),(349,'Maidenhead','maidenhead',NULL),(350,'Maidstone and The Weald','maidstone-and-the-weald',NULL),(351,'Makerfield','makerfield',NULL),(352,'Maldon','maldon',NULL),(353,'Manchester Central','manchester-central',NULL),(354,'Manchester, Gorton','manchester-gorton',NULL),(355,'Manchester, Withington','manchester-withington',NULL),(356,'Mansfield','mansfield',NULL),(357,'Meon Valley','meon-valley',NULL),(358,'Meriden','meriden',NULL),(359,'Merthyr Tydfil and Rhymney','merthyr-tydfil-and-rhymney',NULL),(360,'Mid Bedfordshire','mid-bedfordshire',NULL),(361,'Mid Derbyshire','mid-derbyshire',NULL),(362,'Mid Dorset and North Poole','mid-dorset-and-n-poole',NULL),(363,'Mid Norfolk','mid-norfolk',NULL),(364,'Mid Sussex','mid-sussex',NULL),(365,'Mid Ulster','mid-ulster',NULL),(366,'Mid Worcestershire','mid-worcestershire',NULL),(367,'Middlesbrough','middlesbrough',NULL),(368,'Middlesbrough South and East Cleveland','middlesbrough-s-and-e-cleveland',NULL),(369,'Midlothian','midlothian',NULL),(370,'Milton Keynes North','milton-keynes-n',NULL),(371,'Milton Keynes South','milton-keynes-s',NULL),(372,'Mitcham and Morden','mitcham-and-morden',NULL),(373,'Mole Valley','mole-valley',NULL),(374,'Monmouth','monmouth',NULL),(375,'Montgomeryshire','montgomeryshire',NULL),(376,'Moray','moray',NULL),(377,'Morecambe and Lunesdale','morecambe-and-lunesdale',NULL),(378,'Morley and Outwood','morley-and-outwood',NULL),(379,'Motherwell and Wishaw','motherwell-and-wishaw',NULL),(380,'Na h-Eileanan an Iar','na-h-eileanan-an-iar',NULL),(381,'Neath','neath',NULL),(382,'New Forest East','new-forest-e',NULL),(383,'New Forest West','new-forest-w',NULL),(384,'Newark','newark',NULL),(385,'Newbury','newbury',NULL),(386,'Newcastle upon Tyne Central','newcastle-upon-tyne-central',NULL),(387,'Newcastle upon Tyne East','newcastle-upon-tyne-e',NULL),(388,'Newcastle upon Tyne North','newcastle-upon-tyne-n',NULL),(389,'Newcastle-under-Lyme','newcastle-under-lyme',NULL),(390,'Newport East','newport-e',NULL),(391,'Newport West','newport-w',NULL),(392,'Newry and Armagh','newry-and-armagh',NULL),(393,'Newton Abbot','newton-abbot',NULL),(394,'Normanton, Pontefract and Castleford','normanton-pontefract-and-castleford',NULL),(395,'North Antrim','n-antrim',NULL),(396,'North Ayrshire and Arran','n-ayrshire-and-arran',NULL),(397,'North Cornwall','n-cornwall',NULL),(398,'North Devon','n-devon',NULL),(399,'North Dorset','n-dorset',NULL),(400,'North Down','n-down',NULL),(401,'North Durham','n-durham',NULL),(402,'North East Bedfordshire','n-e-bedfordshire',NULL),(403,'North East Cambridgeshire','n-e-cambridgeshire',NULL),(404,'North East Derbyshire','n-e-derbyshire',NULL),(405,'North East Fife','n-e-fife',NULL),(406,'North East Hampshire','n-e-hampshire',NULL),(407,'North East Hertfordshire','n-e-hertfordshire',NULL),(408,'North East Somerset','n-e-somerset',NULL),(409,'North Herefordshire','n-herefordshire',NULL),(410,'North Norfolk','n-norfolk',NULL),(411,'North Shropshire','n-shropshire',NULL),(412,'North Somerset','n-somerset',NULL),(413,'North Swindon','n-swindon',NULL),(414,'North Thanet','n-thanet',NULL),(415,'North Tyneside','n-tyneside',NULL),(416,'North Warwickshire','n-warwickshire',NULL),(417,'North West Cambridgeshire','n-w-cambridgeshire',NULL),(418,'North West Durham','n-w-durham',NULL),(419,'North West Hampshire','n-w-hampshire',NULL),(420,'North West Leicestershire','n-w-leicestershire',NULL),(421,'North West Norfolk','n-w-norfolk',NULL),(422,'North Wiltshire','n-wiltshire',NULL),(423,'Northampton North','northampton-n',NULL),(424,'Northampton South','northampton-s',NULL),(425,'Norwich North','norwich-n',NULL),(426,'Norwich South','norwich-s',NULL),(427,'Nottingham East','nottingham-e',NULL),(428,'Nottingham North','nottingham-n',NULL),(429,'Nottingham South','nottingham-s',NULL),(430,'Nuneaton','nuneaton',NULL),(431,'Ochil and South Perthshire','ochil-and-s-perthshire',NULL),(432,'Ogmore','ogmore',NULL),(433,'Old Bexley and Sidcup','old-bexley-and-sidcup',NULL),(434,'Oldham East and Saddleworth','oldham-e-and-saddleworth',NULL),(435,'Oldham West and Royton','oldham-w-and-royton',NULL),(436,'Orkney and Shetland','orkney-and-shetland',NULL),(437,'Orpington','orpington',NULL),(438,'Oxford East','oxford-e',NULL),(439,'Oxford West and Abingdon','oxford-w-and-abingdon',NULL),(440,'Paisley and Renfrewshire North','paisley-and-renfrewshire-n',NULL),(441,'Paisley and Renfrewshire South','paisley-and-renfrewshire-s',NULL),(442,'Pendle','pendle',NULL),(443,'Penistone and Stocksbridge','penistone-and-stocksbridge',NULL),(444,'Penrith and The Border','penrith-and-the-border',NULL),(445,'Perth and North Perthshire','perth-and-n-perthshire',NULL),(446,'Peterborough','peterborough',NULL),(447,'Plymouth, Moor View','plymouth-moor-view',NULL),(448,'Plymouth, Sutton and Devonport','plymouth-sutton-and-devonport',NULL),(449,'Pontypridd','pontypridd',NULL),(450,'Poole','poole',NULL),(451,'Poplar and Limehouse','poplar-and-limehouse',NULL),(452,'Portsmouth North','portsmouth-n',NULL),(453,'Portsmouth South','portsmouth-s',NULL),(454,'Preseli Pembrokeshire','preseli-pembrokeshire',NULL),(455,'Preston','preston',NULL),(456,'Pudsey','pudsey',NULL),(457,'Putney','putney',NULL),(458,'Rayleigh and Wickford','rayleigh-and-wickford',NULL),(459,'Reading East','reading-e',NULL),(460,'Reading West','reading-w',NULL),(461,'Redcar','redcar',NULL),(462,'Redditch','redditch',NULL),(463,'Reigate','reigate',NULL),(464,'Rhondda','rhondda',NULL),(465,'Ribble Valley','ribble-valley',NULL),(466,'Richmond (Yorks)','richmond-yorks-',NULL),(467,'Richmond Park','richmond-park',NULL),(468,'Rochdale','rochdale',NULL),(469,'Rochester and Strood','rochester-and-strood',NULL),(470,'Rochford and Southend East','rochford-and-southend-e',NULL),(471,'Romford','romford',NULL),(472,'Romsey and Southampton North','romsey-and-southampton-n',NULL),(473,'Ross, Skye and Lochaber','ross-skye-and-lochaber',NULL),(474,'Rossendale and Darwen','rossendale-and-darwen',NULL),(475,'Rother Valley','rother-valley',NULL),(476,'Rotherham','rotherham',NULL),(477,'Rugby','rugby',NULL),(478,'Ruislip, Northwood and Pinner','ruislip-northwood-and-pinner',NULL),(479,'Runnymede and Weybridge','runnymede-and-weybridge',NULL),(480,'Rushcliffe','rushcliffe',NULL),(481,'Rutherglen and Hamilton West','rutherglen-and-hamilton-w',NULL),(482,'Rutland and Melton','rutland-and-melton',NULL),(483,'Saffron Walden','saffron-walden',NULL),(484,'Salford and Eccles','salford-and-eccles',NULL),(485,'Salisbury','salisbury',NULL),(486,'Scarborough and Whitby','scarborough-and-whitby',NULL),(487,'Scunthorpe','scunthorpe',NULL),(488,'Sedgefield','sedgefield',NULL),(489,'Sefton Central','sefton-central',NULL),(490,'Selby and Ainsty','selby-and-ainsty',NULL),(491,'Sevenoaks','sevenoaks',NULL),(492,'Sheffield Central','sheffield-central',NULL),(493,'Sheffield South East','sheffield-s-e',NULL),(494,'Sheffield, Brightside and Hillsborough','sheffield-brightside-and-hillsborough',NULL),(495,'Sheffield, Hallam','sheffield-hallam',NULL),(496,'Sheffield, Heeley','sheffield-heeley',NULL),(497,'Sherwood','sherwood',NULL),(498,'Shipley','shipley',NULL),(499,'Shrewsbury and Atcham','shrewsbury-and-atcham',NULL),(500,'Sittingbourne and Sheppey','sittingbourne-and-sheppey',NULL),(501,'Skipton and Ripon','skipton-and-ripon',NULL),(502,'Sleaford and North Hykeham','sleaford-and-n-hykeham',NULL),(503,'Slough','slough',NULL),(504,'Solihull','solihull',NULL),(505,'Somerton and Frome','somerton-and-frome',NULL),(506,'South Antrim','s-antrim',NULL),(507,'South Basildon and East Thurrock','s-basildon-and-e-thurrock',NULL),(508,'South Cambridgeshire','s-cambridgeshire',NULL),(509,'South Derbyshire','s-derbyshire',NULL),(510,'South Dorset','s-dorset',NULL),(511,'South Down','s-down',NULL),(512,'South East Cambridgeshire','s-e-cambridgeshire',NULL),(513,'South East Cornwall','s-e-cornwall',NULL),(514,'South Holland and The Deepings','s-holland-and-the-deepings',NULL),(515,'South Leicestershire','s-leicestershire',NULL),(516,'South Norfolk','s-norfolk',NULL),(517,'South Northamptonshire','s-northamptonshire',NULL),(518,'South Ribble','s-ribble',NULL),(519,'South Shields','s-shields',NULL),(520,'South Staffordshire','s-staffordshire',NULL),(521,'South Suffolk','s-suffolk',NULL),(522,'South Swindon','s-swindon',NULL),(523,'South Thanet','s-thanet',NULL),(524,'South West Bedfordshire','s-w-bedfordshire',NULL),(525,'South West Devon','s-w-devon',NULL),(526,'South West Hertfordshire','s-w-hertfordshire',NULL),(527,'South West Norfolk','s-w-norfolk',NULL),(528,'South West Surrey','s-w-surrey',NULL),(529,'South West Wiltshire','s-w-wiltshire',NULL),(530,'Southampton, Itchen','southampton-itchen',NULL),(531,'Southampton, Test','southampton-test',NULL),(532,'Southend West','southend-w',NULL),(533,'Southport','southport',NULL),(534,'Spelthorne','spelthorne',NULL),(535,'St Albans','st-albans',NULL),(536,'St Austell and Newquay','st-austell-and-newquay',NULL),(537,'St Helens North','st-helens-n',NULL),(538,'St Helens South and Whiston','st-helens-s-and-whiston',NULL),(539,'St Ives','st-ives',NULL),(540,'Stafford','stafford',NULL),(541,'Staffordshire Moorlands','staffordshire-moorlands',NULL),(542,'Stalybridge and Hyde','stalybridge-and-hyde',NULL),(543,'Stevenage','stevenage',NULL),(544,'Stirling','stirling',NULL),(545,'Stockport','stockport',NULL),(546,'Stockton North','stockton-n',NULL),(547,'Stockton South','stockton-s',NULL),(548,'Stoke-on-Trent Central','stoke-on-trent-central',NULL),(549,'Stoke-on-Trent North','stoke-on-trent-n',NULL),(550,'Stoke-on-Trent South','stoke-on-trent-s',NULL),(551,'Stone','stone',NULL),(552,'Stourbridge','stourbridge',NULL),(553,'Strangford','strangford',NULL),(554,'Stratford-on-Avon','stratford-on-avon',NULL),(555,'Streatham','streatham',NULL),(556,'Stretford and Urmston','stretford-and-urmston',NULL),(557,'Stroud','stroud',NULL),(558,'Suffolk Coastal','suffolk-coastal',NULL),(559,'Sunderland Central','sunderland-central',NULL),(560,'Surrey Heath','surrey-heath',NULL),(561,'Sutton and Cheam','sutton-and-cheam',NULL),(562,'Sutton Coldfield','sutton-coldfield',NULL),(563,'Swansea East','swansea-e',NULL),(564,'Swansea West','swansea-w',NULL),(565,'Tamworth','tamworth',NULL),(566,'Tatton','tatton',NULL),(567,'Taunton Deane','taunton-deane',NULL),(568,'Telford','telford',NULL),(569,'Tewkesbury','tewkesbury',NULL),(570,'The Cotswolds','the-cotswolds',NULL),(571,'The Wrekin','the-wrekin',NULL),(572,'Thirsk and Malton','thirsk-and-malton',NULL),(573,'Thornbury and Yate','thornbury-and-yate',NULL),(574,'Thurrock','thurrock',NULL),(575,'Tiverton and Honiton','tiverton-and-honiton',NULL),(576,'Tonbridge and Malling','tonbridge-and-malling',NULL),(577,'Tooting','tooting',NULL),(578,'Torbay','torbay',NULL),(579,'Torfaen','torfaen',NULL),(580,'Torridge and West Devon','torridge-and-w-devon',NULL),(581,'Totnes','totnes',NULL),(582,'Tottenham','tottenham',NULL),(583,'Truro and Falmouth','truro-and-falmouth',NULL),(584,'Tunbridge Wells','tunbridge-wells',NULL),(585,'Twickenham','twickenham',NULL),(586,'Tynemouth','tynemouth',NULL),(587,'Upper Bann','upper-bann',NULL),(588,'Uxbridge and South Ruislip','uxbridge-and-s-ruislip',NULL),(589,'Vale of Clwyd','vale-of-clwyd',NULL),(590,'Vale of Glamorgan','vale-of-glamorgan',NULL),(591,'Vauxhall','vauxhall',NULL),(592,'Wakefield','wakefield',NULL),(593,'Wallasey','wallasey',NULL),(594,'Walsall North','walsall-n',NULL),(595,'Walsall South','walsall-s',NULL),(596,'Walthamstow','walthamstow',NULL),(597,'Wansbeck','wansbeck',NULL),(598,'Wantage','wantage',NULL),(599,'Warley','warley',NULL),(600,'Warrington North','warrington-n',NULL),(601,'Warrington South','warrington-s',NULL),(602,'Warwick and Leamington','warwick-and-leamington',NULL),(603,'Washington and Sunderland West','washington-and-sunderland-w',NULL),(604,'Watford','watford',NULL),(605,'Waveney','waveney',NULL),(606,'Wealden','wealden',NULL),(607,'Weaver Vale','weaver-vale',NULL),(608,'Wellingborough','wellingborough',NULL),(609,'Wells','wells',NULL),(610,'Welwyn Hatfield','welwyn-hatfield',NULL),(611,'Wentworth and Dearne','wentworth-and-dearne',NULL),(612,'West Aberdeenshire and Kincardine','w-aberdeenshire-and-kincardine',NULL),(613,'West Bromwich East','w-bromwich-e',NULL),(614,'West Bromwich West','w-bromwich-west',NULL),(615,'West Dorset','w-dorset',NULL),(616,'West Dunbartonshire','w-dunbartonshire',NULL),(617,'West Ham','w-ham',NULL),(618,'West Lancashire','w-lancashire',NULL),(619,'West Suffolk','w-suffolk',NULL),(620,'West Tyrone','w-tyrone',NULL),(621,'West Worcestershire','w-worcestershire',NULL),(622,'Westminster North','westminster-n',NULL),(623,'Westmorland and Lonsdale','westmorland-and-lonsdale',NULL),(624,'Weston-Super-Mare','weston-super-mare',NULL),(625,'Wigan','wigan',NULL),(626,'Wimbledon','wimbledon',NULL),(627,'Winchester','winchester',NULL),(628,'Windsor','windsor',NULL),(629,'Wirral South','wirral-s',NULL),(630,'Wirral West','wirral-w',NULL),(631,'Witham','witham',NULL),(632,'Witney','witney',NULL),(633,'Woking','woking',NULL),(634,'Wokingham','wokingham',NULL),(635,'Wolverhampton North East','wolverhampton-n-e',NULL),(636,'Wolverhampton South East','wolverhampton-s-e',NULL),(637,'Wolverhampton South West','wolverhampton-s-w',NULL),(638,'Worcester','worcester',NULL),(639,'Workington','workington',NULL),(640,'Worsley and Eccles South','worsley-and-eccles-s',NULL),(641,'Worthing West','worthing-w',NULL),(642,'Wrexham','wrexham',NULL),(643,'Wycombe','wycombe',NULL),(644,'Wyre and Preston North','wyre-and-preston-n',NULL),(645,'Wyre Forest','wyre-forest',NULL),(646,'Wythenshawe and Sale East','wythenshawe-and-sale-e',NULL),(647,'Yeovil','yeovil',NULL),(648,'Ynys Môn','ynys-mon',NULL),(649,'York Central','york-central',NULL),(650,'York Outer','york-outer',NULL);
/*!40000 ALTER TABLE `constituency` ENABLE KEYS */;
UNLOCK TABLES;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
@@ -49,4 +34,4 @@ UNLOCK TABLES;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
--- Dump completed on 2014-08-16 21:35:52
+-- Dump completed on 2014-08-17 16:10:40
3  db/twittelect.sql
View
@@ -8,7 +8,8 @@ create table party (
create table constituency (
id integer primary key auto_increment,
name varchar(200) not null,
- list_name varchar(200) not null
+ list_name varchar(200) not null,
+ list_id varchar(20)
);
create table candidate (
12 lib/TwittElection/Schema/Result/Constituency.pm
View
@@ -58,6 +58,12 @@ __PACKAGE__->table("constituency");
is_nullable: 0
size: 200
+=head2 list_id
+
+ data_type: 'varchar'
+ is_nullable: 1
+ size: 20
+
=cut
__PACKAGE__->add_columns(
@@ -67,6 +73,8 @@ __PACKAGE__->add_columns(
{ data_type => "varchar", is_nullable => 0, size => 200 },
"list_name",
{ data_type => "varchar", is_nullable => 0, size => 200 },
+ "list_id",
+ { data_type => "varchar", is_nullable => 1, size => 20 },
);
=head1 PRIMARY KEY
@@ -99,8 +107,8 @@ __PACKAGE__->has_many(
);
-# Created by DBIx::Class::Schema::Loader v0.07039 @ 2014-08-16 15:57:37
-# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Hnn6Yg3WzYjCUHlas6197g
+# Created by DBIx::Class::Schema::Loader v0.07039 @ 2014-08-17 15:45:17
+# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:yRFppsscDpDeK/hlKiEkkw
# You can replace this text with custom code or comments, and it will be preserved on regeneration
45 lib/TwittElection/Twitter.pm
View
@@ -0,0 +1,45 @@
+package TwittElection::Twitter;
+
+use Moose;
+extends 'Net::Twitter';
+
+sub authorise {
+ my $self = shift;
+
+ my($access_token, $access_token_secret) = restore_tokens();
+
+ if ($access_token && $access_token_secret) {
+ $self->access_token($access_token);
+ $self->access_token_secret($access_token_secret);
+ }
+
+ unless ( $self->authorized ) {
+ # The client is not yet authorized: Do it now
+ print "Authorize this app at ", $self->get_authorization_url,
+ " and enter the PIN#\n";
+
+ my $pin = <STDIN>; # wait for input
+ chomp $pin;
+
+ my($access_token, $access_token_secret, $user_id, $screen_name) =
+ $self->request_access_token(verifier => $pin);
+ save_tokens($access_token, $access_token_secret); # if necessary
+ }
+}
+
+sub save_tokens {
+ my ($access_token, $access_token_secret) = @_;
+
+ open my $tw_fh, '>', '.te_tokens' or die $!;
+ print $tw_fh "$access_token $access_token_secret";
+}
+
+sub restore_tokens {
+ open my $tw_fh, '<', '.te_tokens' or die $!;
+
+ my $tokens = <$tw_fh>;
+
+ return split / /, $tokens;
+}
+
+1;
BIN  twittelection.png
View
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Please sign in to comment.
Something went wrong with that request. Please try again.