function check_value($name)
{
- return (empty($_POST[$name]) ? 0 : 1);
+ if (is_array($name)) {
+ $ret = array();
+ foreach($name as $key)
+ $ret[$key] = check_value($key);
+ return $ret;
+ } else
+ return (empty($_POST[$name]) ? 0 : 1);
}
function checkbox($label, $name, $value=null, $submit_on_change=false, $title=false)
if ($value === null)
$value = get_post($name,0);
- $str .= "<input"
- .($value == 1 ? ' checked':'')
- ." type='checkbox' name='$name' value='1'"
+ $str .= "<input class=check"
+ .($value != 0 ? ' checked':'')
+ ." type='checkbox' name='$name' value='".$value."'"
.($submit_on_change ? " onclick='$submit_on_change'" : '')
.($title ? " title='$title'" : '')
." >\n";
$bal = get_balance_before_for_bank_account($bank_acc, $to);
label_row( _("Bank Balance:"),
"<a target='_blank' " . ($bal<0 ? 'class="redfg"' : '')
- ."href='$path_to_root/gl/inquiry/bank_inquiry.php?bank_account=".$bank_acc."&no_header=1"."'"
+ ."href='$path_to_root/gl/inquiry/bank_inquiry.php?bank_account=".$bank_acc."'"
." onclick=\"javascript:openWindow(this.href,this.target); return false;\" > "
. price_format($bal)
."</a>", $parms);