derive agencyID and disclog url from filename
derive agencyID and disclog url from filename


Former-commit-id: eddf90809214ee502e593c769c4bd0b0b2fafc3a

[submodule "couchdb/couchdb-lucene"] [submodule "couchdb/couchdb-lucene"]
path = couchdb/couchdb-lucene path = couchdb/couchdb-lucene
url = https://github.com/rnewson/couchdb-lucene.git url = https://github.com/rnewson/couchdb-lucene.git
[submodule "couchdb/settee"] [submodule "couchdb/settee"]
path = couchdb/settee path = couchdb/settee
url = https://github.com/inadarei/settee.git url = https://github.com/inadarei/settee.git
[submodule "lib/php-diff"] [submodule "lib/php-diff"]
path = lib/php-diff path = lib/php-diff
url = https://github.com/chrisboulton/php-diff.git url = https://github.com/chrisboulton/php-diff.git
[submodule "lib/Requests"] [submodule "lib/Requests"]
path = lib/Requests path = lib/Requests
url = https://github.com/rmccue/Requests.git url = https://github.com/rmccue/Requests.git
[submodule "js/flotr2"] [submodule "js/flotr2"]
path = js/flotr2 path = js/flotr2
url = https://github.com/HumbleSoftware/Flotr2.git url = https://github.com/HumbleSoftware/Flotr2.git
[submodule "lib/phpquery"] [submodule "lib/phpquery"]
path = lib/phpquery path = lib/phpquery
url = https://github.com/TobiaszCudnik/phpquery.git url = https://github.com/TobiaszCudnik/phpquery.git
[submodule "js/sigma"] [submodule "js/sigma"]
path = js/sigma path = js/sigma
url = https://github.com/jacomyal/sigma.js.git url = https://github.com/jacomyal/sigma.js.git
[submodule "js/bubbletree"] [submodule "js/bubbletree"]
path = js/bubbletree path = js/bubbletree
url = https://github.com/okfn/bubbletree.git url = https://github.com/okfn/bubbletree.git
[submodule "lib/querypath"] [submodule "lib/querypath"]
path = lib/querypath path = lib/querypath
url = https://github.com/technosophos/querypath.git url = https://github.com/technosophos/querypath.git
[submodule "lib/amon-php"] [submodule "lib/amon-php"]
path = lib/amon-php path = lib/amon-php
url = https://github.com/martinrusev/amon-php.git url = https://github.com/martinrusev/amon-php.git
  [submodule "documents/lib/parsedatetime"]
  path = documents/lib/parsedatetime
  url = git://github.com/bear/parsedatetime.git
   
<?php  
 
include_once('../include/common.inc.php');  
include_header('Webserver and Accessiblity');  
 
echo "<table>  
<tr><th>name</th><th>disclog</th><th>scraper?</th></tr>";  
$agenciesdb = $server->get_db('disclosr-agencies');  
$docsdb = $server->get_db('disclosr-documents');  
try {  
$rows = $agenciesdb->get_view("app", "byCanonicalName", null, true)->rows;  
 
 
if ($rows) {  
foreach ($rows as $row) {  
 
echo "<tr><td>" . $row->value->name . " (".$row->id.")</td>\n";  
echo "<td>";  
if (isset($row->value->FOIDocumentsURL)) {  
echo '<a href="viewDocument.php?hash='.md5($row->value->FOIDocumentsURL).'">'  
.$row->value->FOIDocumentsURL.'</a>';  
} else {  
echo "<font color='red'>✘</font>";  
}  
echo "</td>\n<td>";  
if (isset($row->value->FOIDocumentsURL)) {  
if (file_exists("./scrapers/".$row->id.'.py')) {  
echo "<font color='green'>✔</font>";  
} else if (file_exists("./scrapers/".$row->id.'.txt')){  
echo "pass";  
} else {  
echo "<font color='red'>✘</font>";  
}  
}  
echo "</td></tr>\n";  
}  
}  
} catch (SetteeRestClientException $e) {  
setteErrorHandler($e);  
}  
include_footer();  
?>  
  /*!
  * Bootstrap Responsive v2.2.1
  *
  * Copyright 2012 Twitter, Inc
  * Licensed under the Apache License v2.0
  * http://www.apache.org/licenses/LICENSE-2.0
  *
  * Designed and built with all the love in the world @twitter by @mdo and @fat.
  */
 
  .clearfix {
  *zoom: 1;
  }
 
  .clearfix:before,
  .clearfix:after {
  display: table;
  line-height: 0;
  content: "";
  }
 
  .clearfix:after {
  clear: both;
  }
 
  .hide-text {
  font: 0/0 a;
  color: transparent;
  text-shadow: none;
  background-color: transparent;
  border: 0;
  }
 
  .input-block-level {
  display: block;
  width: 100%;
  min-height: 30px;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  }
 
  .hidden {
  display: none;
  visibility: hidden;
  }
 
  .visible-phone {
  display: none !important;
  }
 
  .visible-tablet {
  display: none !important;
  }
 
  .hidden-desktop {
  display: none !important;
  }
 
  .visible-desktop {
  display: inherit !important;
  }
 
  @media (min-width: 768px) and (max-width: 979px) {
  .hidden-desktop {
  display: inherit !important;
  }
  .visible-desktop {
  display: none !important ;
  }
  .visible-tablet {
  display: inherit !important;
  }
  .hidden-tablet {
  display: none !important;
  }
  }
 
  @media (max-width: 767px) {
  .hidden-desktop {
  display: inherit !important;
  }
  .visible-desktop {
  display: none !important;
  }
  .visible-phone {
  display: inherit !important;
  }
  .hidden-phone {
  display: none !important;
  }
  }
 
  @media (min-width: 1200px) {
  .row {
  margin-left: -30px;
  *zoom: 1;
  }
  .row:before,
  .row:after {
  display: table;
  line-height: 0;
  content: "";
  }
  .row:after {
  clear: both;
  }
  [class*="span"] {
  float: left;
  min-height: 1px;
  margin-left: 30px;
  }
  .container,
  .navbar-static-top .container,
  .navbar-fixed-top .container,
  .navbar-fixed-bottom .container {
  width: 1170px;
  }
  .span12 {
  width: 1170px;
  }
  .span11 {
  width: 1070px;
  }
  .span10 {
  width: 970px;
  }
  .span9 {
  width: 870px;
  }
  .span8 {
  width: 770px;
  }
  .span7 {
  width: 670px;
  }
  .span6 {
  width: 570px;
  }
  .span5 {
  width: 470px;
  }
  .span4 {
  width: 370px;
  }
  .span3 {
  width: 270px;
  }
  .span2 {
  width: 170px;
  }
  .span1 {
  width: 70px;
  }
  .offset12 {
  margin-left: 1230px;
  }
  .offset11 {
  margin-left: 1130px;
  }
  .offset10 {
  margin-left: 1030px;
  }
  .offset9 {
  margin-left: 930px;
  }
  .offset8 {
  margin-left: 830px;
  }
  .offset7 {
  margin-left: 730px;
  }
  .offset6 {
  margin-left: 630px;
  }
  .offset5 {
  margin-left: 530px;
  }
  .offset4 {
  margin-left: 430px;
  }
  .offset3 {
  margin-left: 330px;
  }
  .offset2 {
  margin-left: 230px;
  }
  .offset1 {
  margin-left: 130px;
  }
  .row-fluid {
  width: 100%;
  *zoom: 1;
  }
  .row-fluid:before,
  .row-fluid:after {
  display: table;
  line-height: 0;
  content: "";
  }
  .row-fluid:after {
  clear: both;
  }
  .row-fluid [class*="span"] {
  display: block;
  float: left;
  width: 100%;
  min-height: 30px;
  margin-left: 2.564102564102564%;
  *margin-left: 2.5109110747408616%;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  }
  .row-fluid [class*="span"]:first-child {
  margin-left: 0;
  }
  .row-fluid .controls-row [class*="span"] + [class*="span"] {
  margin-left: 2.564102564102564%;
  }
  .row-fluid .span12 {
  width: 100%;
  *width: 99.94680851063829%;
  }
  .row-fluid .span11 {
  width: 91.45299145299145%;
  *width: 91.39979996362975%;
  }
  .row-fluid .span10 {
  width: 82.90598290598291%;
  *width: 82.8527914166212%;
  }
  .row-fluid .span9 {
  width: 74.35897435897436%;
  *width: 74.30578286961266%;
  }
  .row-fluid .span8 {
  width: 65.81196581196582%;
  *width: 65.75877432260411%;
  }
  .row-fluid .span7 {
  width: 57.26495726495726%;
  *width: 57.21176577559556%;
  }
  .row-fluid .span6 {
  width: 48.717948717948715%;
  *width: 48.664757228587014%;
  }
  .row-fluid .span5 {
  width: 40.17094017094017%;
  *width: 40.11774868157847%;
  }
  .row-fluid .span4 {
  width: 31.623931623931625%;
  *width: 31.570740134569924%;
  }
  .row-fluid .span3 {
  width: 23.076923076923077%;
  *width: 23.023731587561375%;
  }
  .row-fluid .span2 {
  width: 14.52991452991453%;
  *width: 14.476723040552828%;
  }
  .row-fluid .span1 {
  width: 5.982905982905983%;
  *width: 5.929714493544281%;
  }
  .row-fluid .offset12 {
  margin-left: 105.12820512820512%;
  *margin-left: 105.02182214948171%;
  }
  .row-fluid .offset12:first-child {
  margin-left: 102.56410256410257%;
  *margin-left: 102.45771958537915%;
  }
  .row-fluid .offset11 {
  margin-left: 96.58119658119658%;
  *margin-left: 96.47481360247316%;
  }
  .row-fluid .offset11:first-child {
  margin-left: 94.01709401709402%;
  *margin-left: 93.91071103837061%;
  }
  .row-fluid .offset10 {
  margin-left: 88.03418803418803%;
  *margin-left: 87.92780505546462%;
  }
  .row-fluid .offset10:first-child {
  margin-left: 85.47008547008548%;
  *margin-left: 85.36370249136206%;
  }
  .row-fluid .offset9 {
  margin-left: 79.48717948717949%;
  *margin-left: 79.38079650845607%;
  }
  .row-fluid .offset9:first-child {
  margin-left: 76.92307692307693%;
  *margin-left: 76.81669394435352%;
  }
  .row-fluid .offset8 {
  margin-left: 70.94017094017094%;
  *margin-left: 70.83378796144753%;
  }
  .row-fluid .offset8:first-child {
  margin-left: 68.37606837606839%;
  *margin-left: 68.26968539734497%;
  }
  .row-fluid .offset7 {
  margin-left: 62.393162393162385%;
  *margin-left: 62.28677941443899%;
  }
  .row-fluid .offset7:first-child {
  margin-left: 59.82905982905982%;
  *margin-left: 59.72267685033642%;
  }
  .row-fluid .offset6 {
  margin-left: 53.84615384615384%;
  *margin-left: 53.739770867430444%;
  }
  .row-fluid .offset6:first-child {
  margin-left: 51.28205128205128%;
  *margin-left: 51.175668303327875%;
  }
  .row-fluid .offset5 {
  margin-left: 45.299145299145295%;
  *margin-left: 45.1927623204219%;
  }
  .row-fluid .offset5:first-child {
  margin-left: 42.73504273504273%;
  *margin-left: 42.62865975631933%;
  }
  .row-fluid .offset4 {
  margin-left: 36.75213675213675%;
  *margin-left: 36.645753773413354%;
  }
  .row-fluid .offset4:first-child {
  margin-left: 34.18803418803419%;
  *margin-left: 34.081651209310785%;
  }
  .row-fluid .offset3 {
  margin-left: 28.205128205128204%;
  *margin-left: 28.0987452264048%;
  }
  .row-fluid .offset3:first-child {
  margin-left: 25.641025641025642%;
  *margin-left: 25.53464266230224%;
  }