quguofeng 1 vuosi sitten
vanhempi
commit
4e6ffb737d
1 muutettua tiedostoa jossa 1 lisäystä ja 1 poistoa
  1. 1 1
      application/api/controller/Subscribe.php

+ 1 - 1
application/api/controller/Subscribe.php

@@ -44,7 +44,7 @@ class Subscribe extends Base
             $this->error('参数错误');
         }
         $file_name = explode('/',$url);
-        $import_path = $_SERVER['DOCUMENT_ROOT'].'/upload/excel/'.$file_name;
+        $import_path = $_SERVER['DOCUMENT_ROOT'].'/upload/excel/'.end($file_name);
         echo $import_path;exit();
         $objReader =\PHPExcel_IOFactory::createReader('Excel2007');
         $objExcel = $objReader->load($import_path);