~ubuntu-branches/ubuntu/precise/kompozer/precise

« back to all changes in this revision

Viewing changes to mozilla/extensions/webservices/wsdl/tests/void.html

  • Committer: Bazaar Package Importer
  • Author(s): Anthony Yarusso
  • Date: 2007-08-27 01:11:03 UTC
  • Revision ID: james.westby@ubuntu.com-20070827011103-2jgf4s6532gqu2ka
Tags: upstream-0.7.10
ImportĀ upstreamĀ versionĀ 0.7.10

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<html><head>
 
2
<link rel="stylesheet" type="text/css" href="stylesheet.css"><title></title>
 
3
 
 
4
<script>
 
5
    var proxy    = null;
 
6
    var wsdl_uri = "http://www.pocketsoap.com/services/ilab.wsdl";
 
7
 
 
8
    function Translate (aValue)
 
9
    {
 
10
 
 
11
        if (!proxy)
 
12
      {
 
13
         var listener = {
 
14
          onLoad: function (aProxy)
 
15
          {
 
16
            proxy = aProxy;
 
17
            proxy.setListener(listener);
 
18
            requestTranslation(aValue);
 
19
          },
 
20
 
 
21
          onError: function (aError)
 
22
          {
 
23
             //alert("Error-" + aError);
 
24
            resdiv = document.getElementById("result");
 
25
            resdiv.innerHTML  = "Result from server:"+"Error-" + aError ;
 
26
          },
 
27
 
 
28
          echoVoidCallback : function (aTranslatedValue)
 
29
          {
 
30
            //alert(aTranslatedValue);
 
31
            resdiv = document.getElementById("result");
 
32
            resdiv.innerHTML  = "Result from server:" + aTranslatedValue ;
 
33
          }
 
34
        };
 
35
        createProxy(listener);
 
36
      }
 
37
      else {
 
38
        requestTranslation(aValue);
 
39
      }
 
40
    }
 
41
 
 
42
    function createProxy(aCreationListener)
 
43
    {
 
44
      try {
 
45
        var factory = new WebServiceProxyFactory();
 
46
        //alert(factory);
 
47
        factory.createProxyAsync(wsdl_uri, "interopTestPort", "", true, aCreationListener);
 
48
      }
 
49
      catch (ex) {
 
50
        alert(ex);
 
51
      }
 
52
    }
 
53
 
 
54
    function requestTranslation (value)
 
55
    {
 
56
      if (proxy) {
 
57
        //alert("Wait...");
 
58
        netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead");
 
59
        proxy.echoVoid();
 
60
      }
 
61
      else {
 
62
        alert("Error: Proxy set up not complete!");
 
63
      }
 
64
    }
 
65
</script>
 
66
 
 
67
</head>
 
68
<body>
 
69
<div id="banner">
 
70
    <a name="top"></a>
 
71
 
 
72
  WSDL Testcase: Void
 
73
  </div>
 
74
 
 
75
  <div id="main">
 
76
    <p>This page tests simple type void operation. Calls a method which does not require any parameter</p>
 
77
 
 
78
<div style="border: 1px dotted black;">
 
79
<div style="padding: 20px;">
 
80
<table>
 
81
<tbody>
 
82
<tr>
 
83
<td>
 
84
<br>
 
85
<input id="Send" type="button" value="Call Void Method" onclick="Translate();">
 
86
<br>
 
87
<br>
 
88
<div id="result">Result from server:</div>
 
89
<br>
 
90
</td>
 
91
 
 
92
<td valign="bottom">
 
93
<div id="myWizard" style="position: relative;"></div>
 
94
</td>
 
95
</tr>
 
96
</tbody>
 
97
</table>
 
98
</div>
 
99
</div>
 
100
<p></p>
 
101
</div></div>
 
102
 
 
103
</body></html>
 
 
b'\\ No newline at end of file'