<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- 
This sample shows how to use a generated AJAX proxy for a WCF 
AJAX-enabled service directly as dataProvider for an Ajax DataView control.

Since this is an HTML page, not a Web form, the AJAX proxy is 
obtained by adding a script reference to the service, 
with '/jsdebug' or '/js' appended to the URL.
-->
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title>DataView.dataProvider and Service Proxy</title>
    <link href="../styles/Images.css" rel="stylesheet" type="text/css"/>

    <script type="text/javascript" src="../Scripts/MicrosoftAjax/MicrosoftAjax.debug.js"></script>
    <script type="text/javascript" src="../Scripts/MicrosoftAjax/MicrosoftAjaxTemplates.debug.js"></script>
 
    <!--Get Web service proxy-->
    <script src="../Services/ImagesWcfService.svc/jsdebug" type="text/javascript"></script>
</head>

<body xmlns:dataview="javascript:Sys.UI.DataView" xmlns:sys="javascript:Sys">

    <!--DataView calls service directly. No code-->
    <div id="imagesListView" class="imageslist sys-template"
        sys:attach="dataview"
        dataview:autofetch="true"
        dataview:dataprovider="{{ Uc.ImagesWcfService }}"
        dataview:fetchoperation="GetImages"
        dataview:fetchparameters="{{ {orderby: 'Name'} }}"
    >
        <span class="namedlistitem">
            <img sys:src="{{ Uri }}"/>
            <div>{{ Name }}</div>
        </span>
    </div>

</body>
</html>
