public function __getConfig() { //获取mediaserver的里面视频类型的配置 if ($this->settings['App_mediaserver']) { $curl = new curl($this->settings['App_mediaserver']['host'], $this->settings['App_mediaserver']['dir'] . 'admin/'); $curl->setReturnFormat('json'); $curl->initPostData(); $curl->addRequestData('a', '__getConfig'); $m_config = $curl->request('index.php'); } if ($m_config && is_array($m_config)) { $video_type = $m_config[0]['video_type']['allow_type']; } else { $video_type = $this->default_type; } $video_type_arr = explode(',', $video_type); $flash_video_type = ''; foreach ($video_type_arr as $k => $v) { $flash_video_type .= '*' . $v . ';'; } $video_types = str_replace('.', '', $video_type); $this->settings['flash_video_type'] = $flash_video_type; $this->settings['video_type'] = $video_types; parent::__getConfig(); }