--- a/getAgency.php +++ b/getAgency.php @@ -2,17 +2,18 @@ include_once('common.inc.php'); include_header(); - -$sag->setDatabase("disclosr-agencies", true); +$db = $server->get_db('disclosr-agencies'); //get an agency record as json/html, search by name/abn/id // by name = startkey="Ham"&endkey="Ham\ufff0" // edit? -$rows = $sag->get('/_design/app/_view/byABN?include_docs=true')->body->rows; // &endkey='.$searchVar +$rows = $db->get_view("app","byABN")->rows; +//print_r($rows); foreach ($rows as $row) { + echo "
' . $row->doc->agencyName . " | |
' . $row->value->name . " | |
Field Name | Field Value |
---|---|
$key | ".var_dump($value,true)." |
$key | $value |