<?vsp 
--  
--  $Id: asmx_tutorial.vsp,v 1.2 2006/08/15 19:30:34 source Exp $
--  
--  This file is part of the OpenLink Software Virtuoso Open-Source (VOS)
--  project.
--  
--  Copyright (C) 1998-2006 OpenLink Software
--  
--  This project is free software; you can redistribute it and/or modify it
--  under the terms of the GNU General Public License as published by the
--  Free Software Foundation; only version 2 of the License, dated June 1991.
--  
--  This program is distributed in the hope that it will be useful, but
--  WITHOUT ANY WARRANTY; without even the implied warranty of
--  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
--  General Public License for more details.
--  
--  You should have received a copy of the GNU General Public License along
--  with this program; if not, write to the Free Software Foundation, Inc.,
--  51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
--  
--  


  declare res, _host varchar;

  res := '';

  if (atoi ({?'SOAP_CALL'}) = 1)
    res := asmx_tutorial_soap_call ();

  _host := http_request_header (lines, 'Host');

?>
<html>
 <HEAD>
 <link rel="stylesheet" type="text/css" href="../demo.css" />
  <STYLE>
  .filelist {
    font-family: Tahoma, sans-serif;
    background-color: #eeeeee;
    color: Black;
    border: 1px #dddddd solid;
  }
  </STYLE>
  </HEAD>
 <body>
  <H4>HOSTING .NET WEB SERVICES ON VIRTUOSO SAMPLE.</H4>
  Hit links to call web service. <BR />
  <table class="tableentry">

  <tr>
    <td><p><a href="http://<?=_host?>/asmx_tutorial/Service1.asmx">Call Web service main page</a></p></td>
  </tr>
  <?vsp
    if (__proc_exists ('clr_runtime_name', 2) is null or clr_runtime_name () <> 'Mono')
      {
  ?>

  <tr>
    <td><p><a href="http://<?=_host?>/asmx_tutorial/Service1.asmx?op=HelloWorld">Call Web service operation list</a></p></td>
  </tr>
  <tr>
    <td><p><a href="http://<?=_host?>/asmx_tutorial/Service1.asmx?WSDL">Call Web service WSDL</a></p></td>
  </tr>
<?vsp
     }
    else
     {
?>
  <tr>
    <td><p><a href="http://<?=_host?>/asmx_tutorial/Service1.asmx?page=op&op=HelloWorld&bnd=Service1Soap&tab=main">Call Web service operation list</a></p></td>
  </tr>
  <tr>
    <td><p><a href="http://<?=_host?>/asmx_tutorial/Service1.asmx?wsdl=0">Call Web service WSDL</a></p></td>
  </tr>
<?vsp
     }
?>
  <tr>
    <td><p><a href="http://<?=_host?>/asmx_tutorial/Service1.asmx/HelloWorld">HTTP call</a></p></td>
  </tr>
  <tr>
    <td><p><a href="http://<?=_host?><?=http_path()?>?SOAP_CALL=1">SOAP call</a></p></td>
  </tr>
  </table>
<?vsp if (res <> '')
  	{
?>
  <table>
       <tr>
	 <td>
	<table class="tableresult">
	  <tr>
	  	<td>Result:</td>
		<td><?=res?></td> </tr>
	</table>
	</td>
	</tr>
  </table>
<?vsp
  	}
?>
 </body>
</html>
