block->getByID($blockID); if(empty($block)) return false; $this->app->loadLang('client'); $now = helper::now(); $polling = empty($this->config->xuanxuan->pollingInterval) ? $this->lang->client->noData : $this->config->xuanxuan->pollingInterval . 's'; $lastPoll = $this->loadModel('setting')->getItem("owner=system&module=common§ion=xxd&key=lastPoll"); $xxdStatus = $this->loadModel('im')->getXxdStatus(); $onlineUserCount = $xxdStatus == 'offline' ? 0 : count($this->loadModel('im')->userGetList('online')); $setServerBtn = html::a(helper::createLink('setting', 'xuanxuan', 'type=edit'), $this->lang->client->set, 'class="btn"'); $xxdStartDate = zget($this->config->xxd, 'start', $this->lang->client->noData); if(!empty($lastPoll) && $xxdStatus == 'online' && !empty($this->config->xxd) && $polling < 600) { $xxdRunTime = $xxdStartDate === $this->lang->client->noData ? $this->lang->client->noData : $this->im->getXxdRunTime(strtotime($now) - strtotime($xxdStartDate)); $xxdRunHtml = "

{$this->lang->client->xxdRunTime}

{$xxdRunTime}

"; } else { $xxdRunHtml = "

{$this->lang->client->xxdStartDate}

{$xxdStartDate}

"; } $html = '
'; $html = '
'; $html .= "

{$this->lang->client->xxdStatus}

{$this->lang->client->xxdStatusList[$xxdStatus]}

"; $html .= $xxdRunHtml; $html .= "

{$this->lang->client->polling}

{$polling}

"; $html .= "

{$this->lang->client->countUsers}

{$onlineUserCount}

"; $html .= "
"; $html .= "

{$this->lang->client->setServer}

{$setServerBtn}

"; $html .= '
'; die($html); } }