1
0
mirror of https://github.com/e107inc/e107.git synced 2025-04-21 05:02:02 +02:00

Form Handler pagination() now accepts text for simple 'back' buttons etc.

This commit is contained in:
Cameron 2015-06-17 20:17:00 -07:00
parent fa69e274c4
commit aba237d826
2 changed files with 20 additions and 4 deletions

View File

@ -1197,6 +1197,13 @@ class e_form
*/
public function pagination($url='', $total=0, $from=0, $perPage=10, $options=array())
{
if(!is_numeric($total))
{
return '<ul class="pager"><li><a href="'.$url.'">'.$total.'</a></li></ul>';
}
require_once(e_CORE."shortcodes/single/nextprev.php");
$nextprev = array(
@ -1223,10 +1230,16 @@ class e_form
*/
public function progressBar($name,$value,$options=array())
{
if(!deftrue('BOOTSTRAP'))
if(!deftrue('BOOTSTRAP')) // Legacy ProgressBar.
{
return;
}
$barl = (file_exists(THEME.'images/barl.png') ? THEME_ABS.'images/barl.png' : e_PLUGIN_ABS.'poll/images/barl.png');
$barr = (file_exists(THEME.'images/barr.png') ? THEME_ABS.'images/barr.png' : e_PLUGIN_ABS.'poll/images/barr.png');
$bar = (file_exists(THEME.'images/bar.png') ? THEME_ABS.'images/bar.png' : e_PLUGIN_ABS.'poll/images/bar.png');
return "<div style='background-image: url($barl); width: 5px; height: 14px; float: left;'></div>
<div style='background-image: url($bar); width: ".intval($value)."%; height: 14px; float: left;'></div>
<div style='background-image: url($barr); width: 5px; height: 14px; float: left;'></div>";
}
$class = vartrue($options['class'],'');
$target = $this->name2id($name);

View File

@ -1200,7 +1200,10 @@ class e_db_mysql
return FALSE;
}
}
/**
* @deprecated use count()
*/
function db_Count($table, $fields = '(*)', $arg = '', $debug = FALSE, $log_type = '', $log_remark = '')
{
return $this->count($table, $fields, $arg, $debug, $log_type, $log_remark);