- Timestamp:
- Nov 26, 2014 4:24:07 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pro-violet-viettel/sourcecode/application/libraries/vservices.php
r629 r630 46 46 47 47 public function actionExecute ($action, $aryParams = array(), $module = 'space') { 48 $this->_curlObj->create($this->_apiUrl. $module .'/'.$action); 48 $url = $this->_apiUrl. $module .'/'.$action; 49 50 $this->_curlObj->create($url); 49 51 $this->_curlObj->option(CURLOPT_BUFFERSIZE, 10); 50 $this->_curlObj->options(array(CURLOPT_BUFFERSIZE => 10)); 52 $this->_curlObj->option(CURLOPT_HEADER, 0); 53 $this->_curlObj->option(CURLOPT_FAILONERROR, FALSE); 51 54 52 55 if ($this->_httpUser && $this->_httpPasswd) { … … 59 62 $result = $this->_curlObj->execute(); 60 63 61 $logMsg = date('Y mdHis') .' - File: '. __FILE__ . ' - line:'. __LINE__ .' - API Result: '. var_export($result, true). ' - Action: '. var_export($this->_apiUrl. $module .'/'.$action, true) .' - PARAMS: '. .var_export($aryParams, true);64 $logMsg = date('Y-m-d H:i:s') .' - File: '. __FILE__ . ' - line:'. __LINE__ .' - API Result: '. var_export($result, true). ' - Action: '. var_export($url, true) .' - PARAMS: '. var_export($aryParams, true)."\n"; 62 65 write_file('./log/apicalling.log', $logMsg, FOPEN_WRITE_CREATE); 63 66
Note: See TracChangeset
for help on using the changeset viewer.