Subversion Repositories php-qbpwcf

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
14 liveuser 1
<?php
2
 
3
/*
4
 
5
	QBPWCF, Quick Build PHP website Component base on Fedora Linux.
6
    Copyright (C) 2015~2016 Min-Jhin,Chen
7
 
8
    This file is part of QBPWCF.
9
 
10
    QBPWCF is free software: you can redistribute it and/or modify
11
    it under the terms of the GNU General Public License as published by
12
    the Free Software Foundation, either version 3 of the License, or
13
    (at your option) any later version.
14
 
15
    QBPWCF is distributed in the hope that it will be useful,
16
    but WITHOUT ANY WARRANTY; without even the implied warranty of
17
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18
    GNU General Public License for more details.
19
 
20
    You should have received a copy of the GNU General Public License
21
    along with QBPWCF.  If not, see <http://www.gnu.org/licenses/>.
22
 
23
*/
24
 
25
#使用命名空間qbpwcf
26
namespace qbpwcf{
27
 
28
	#匯入外部套件
29
	include("../allInOneForSOAP.php");
30
 
31
	#提示執行的函數
32
	echo "<hr>soap::callService=>local=>app::defaultMode<p>";
33
 
34
	#/*
35
 
36
	#涵式說明:
37
	#呼叫WebService
38
	#回傳的結果
39
	#$result["status"],執行是否正常,"true"代表正常,"false"代表不正常.
40
	#$reuslt["error"],執行不正常結束的錯訊息陣列.
41
	#$result["function"],當前執行的函式名稱.
42
	#$result["content"],呼叫完WebService所得回傳結果.
43
	#$result["info"],取得webService的要求資訊.
44
	#必填的參數:
45
	#$conf["servicePhpFile"],字串,提供服務內容的php檔案的完整絕對位置,裏面要有1個名爲 $conf["serviceClassName"] 類別
46
	$conf["servicePhpFile"]="~qbpwcf/samplePage/phplib/qbpwcf/app-soap.php";
47
	#$conf["soapMethod"],字串,要呼叫的方法
48
	$conf["soapMethod"]="defaultMode";
49
	#$conf["argv"],字串陣列,呼叫方法時所要用到的參數內容
50
	$conf["argv"]=array(array("test"));
51
	#可省略的參數:
52
	#$conf["ssl"],字串,是否使用ssl,"true"代表要使用;"false"代表不使用,預設爲"false"
53
	#$conf["ssl"]="false";
54
	#$conf["serverIp"],字串,服務提供的主機ip位置,預設爲本機"127.0.0.1"
55
	#$conf["serverIp"]="127.0.0.1";
56
	#$conf["port"],port通常不用ssl時為80,用ssl時為443.
57
	#$conf["port"]="443";
58
	#備註:
59
	#若$conf["ssl"]設為"true"將會呼叫失敗.
60
	#目前無法用非80port呼叫主機的服務.
61
	#參考資料:
62
	#http://www.cnblogs.com/chance1/archive/2009/04/08/1431949.html
63
	#http://www.php.net/manual/en/soapclient.soapcall.php
64
	var_dump(soap::callService($conf));
65
	unset($conf);
66
 
67
	#*/
68
 
69
	}#namespace qbpwcf end
70
 
71
?>