"URL");
protected $uiproperty;
protected function __construct()
{
$this->uiproperty = new UIProperty();
}
protected function confform_start()
{
$formaction = $this->uiproperty->Get(UIProperty::FLD_FORM_ACTION);
$buf = '
';
return $buf;
}
protected function print_conf_page($disp, $page)
{
$this->uiproperty->Set(UIProperty::FLD_FORM_ACTION, '#view/confMgr.php');
$disp->InitUIProps($this->uiproperty);
$icontitle = $disp->Get(DInfo::FLD_ICONTITLE);
echo $this->content_header($icontitle[0], $icontitle[1], $page->GetLabel());
echo $this->confform_start();
echo $this->main_tabs();
echo '';
$page->PrintHtml($disp);
echo "
\n";
echo $this->confform_end();
}
protected function main_tabs()
{
$tabs = $this->uiproperty->Get(UIProperty::FLD_TABS);
$buf = '';
foreach ( $tabs as $name => $uri ) {
$buf .= '- ' . substr($name, 1) . '
';
}
$buf .= "
\n";
return $buf;
}
public static function content_header($icon, $title, $subtitle='')
{
$serverload = implode(', ', sys_getloadavg());
$pid = Service::ServiceData(SInfo::DATA_PID);
if ($subtitle != '')
$title .= ' > ' . $subtitle . '';
$buf = '
' . $title . '
-
LSWS PID ' . $pid . '
-
' . DMsg::UIStr('note_loadavg') . ' ' . $serverload . '
';
return $buf;
}
public static function GetActionButtons($actdata, $type)
{
$buf = '';
return $buf;
}
public static function GetTblTips($tips)
{
$buf = '';
foreach( $tips as $tip )
{
if($tip != '') {
$buf .= "- $tip
\n";
}
}
$buf .= "
\n";
return $buf;
}
public static function message($title="", $msg="", $type = "normal")
{
return '' . $msg .'
';
}
public static function error_divmesg($msg)
{
return '' . $msg .'
';
}
public static function info_divmesg($msg)
{
return '' . $msg .'
';
}
public static function warn_divmesg($msg)
{
return '' . $msg .'
';
}
public static function genOptions($options, $selValue, $keyIsValue=false)
{
$o = '';
if ( $options )
{
foreach ( $options as $key => $value )
{
if ($keyIsValue)
$key = $value;
$o .= '