Esempio n. 1
0
 public function del()
 {
     $model = new apiModel();
     $model->headerServer = $_SERVER;
     $model->resquest = $_REQUEST;
     $model->get = $this->getParam();
     $model->execute();
 }
Esempio n. 2
0
 function isAssociativeArray($array)
 {
     return parent::isAssociativeArray($array);
 }
Esempio n. 3
0
 private function getResources($url, $html = '')
 {
     if (empty($html)) {
         $response_data = apiModel::getRequestInfo($url);
         $html = $response_data['html'];
     }
     if ($html) {
         $resources = $this->collectResources($html);
         for ($i = 0; $i < count($resources); $i++) {
             if (preg_match('/^\\/\\/[^\\.]+\\..+/', $resources[$i])) {
                 $resources[$i] = 'http:' . $resources[$i];
             }
             if (!preg_match('/^http:\\/\\/[^\\/]+\\/.+/', $resources[$i])) {
                 preg_match('/^(https{0,1}:\\/\\/[^\\/]+\\/{0,1}[^\\?]*)/', $url, $mch);
                 $resources[$i] = preg_replace('/(?<!:)\\/\\//', '/', $mch[1] . '/' . $resources[$i]);
             }
         }
         return $resources;
     } else {
         apiModel::$errors[] = __METHOD__ . ': no html.';
     }
     return false;
 }