#$this->pdef('header',$this->show_header);
if (isset($_GET['rows.header'])) $this->show_header = $_GET['rows.header'];
- $this->pdef('header',$this->show_header);
- $this->show_header = (bool)$this->p('header',$this->show_header);
+ #$this->pdef('header',$this->show_header);
+ #$this->show_header = (bool)$this->p('header',$this->show_header);
#bye($this->show_header);
#$this->show_header = (bool)$this->show_header;
#$this->db()->out->header($this->show_header);
public $default_limit = '30';
public $limits = ['30','100','500','1000'];
public $formats = [ 'html','csv','xml','json','yaml','sh','sql','php' ];
+ public $is_html;
# Page
public $css = '/default'.(PRODUCTION ? '.min' : '').'.css';
'db' => $this->db,
'show_hidden_params' => false,
'show_buttons' => false,
- 'show_header' => ($this->params['format'] == 'html'),
- #'params' => [],
- #'params' => [ 'limit' ],
+ 'show_header' => $this->is_html,
],$param));
$this->table->base = $this->db->base.'/'.$this->table->name;
if ($password=='') {
if ($password=='') $password = $this->params['table'];
if ($password=='' and !empty($_POST['password'])) $password = $_POST['password'];
- if ($this->db->is_html) echo <<<EOF
+ if ($this->is_html) echo <<<EOF
<form action="$this->uri" method="post">
<label>Password</label><input type="text" name="password" value="$password" />
<input type="submit" />
if ($format == 'html') $format = $this->format_html;
$this->params['format'] = $format;
$this->db->format = $format;
- $this->db->is_html = strpos($content_type,'html') ? true : false;
+ $this->is_html = strpos($content_type,'html') ? true : false;
+ $this->db->is_html = $this->is_html;
}