I can't believe that no one has mentioned Microsoft's new xml-script that they are apparently developing in conjunction with their new AJAX related offering for ASP.NET codenamed Atlas. So the brilliant idea there is that rather than creating a single control/html tag:
<atlas:ScriptManager runat="server" ID="scriptManager" ><?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p>
<Services><o:p></o:p>
<atlas:ServiceReference Path="HelloWorldService.asmx" Type="text/javascript" /><o:p></o:p>
</Services><o:p></o:p>
</atlas:ScriptManager><o:p></o:p>
and a few lines of JavaScript:
<script type="text/javascript"><o:p></o:p>
function DoSearch()<o:p></o:p>
{<o:p></o:p>
var SrchElem = document.getElementById("SearchKey");<o:p></o:p>
<FONT face="Courier New" size=2>Samples.AspNet.HelloWorldService.HelloWorld(SrchElem.value, OnRequestComplete);</FONT>
}<o:p></o:p>
function OnRequestComplete(result)<o:p></o:p>
{<o:p></o:p>
var RsltElem = document.getElementById("Results");<o:p></o:p>
RsltElem.innerHTML = result;<o:p></o:p>
}<o:p></o:p>
</script><o:p></o:p>
I should instead create the following jumble involving twice the number of lines using this new xml-script:
<script type="text/xml-script"><o:p></o:p>
<page xmlns:script="http://schemas.microsoft.com/xml-script/2005"><o:p></o:p>
<references><o:p></o:p>
</references><o:p></o:p>
<components><o:p></o:p>
<textBox id="SearchKey" /><o:p></o:p>
<serviceMethod id="helloService" url="HelloWorldService.asmx" methodName="HelloWorld"><o:p></o:p>
<bindings><o:p></o:p>
<binding dataContext="SearchKey" dataPath="text" property="parameters"<o:p></o:p>
propertyKey="query" /><o:p></o:p>
</bindings><o:p></o:p>
<completed><o:p></o:p>
<invokeMethod target="resultsBinding" method="evaluateIn" /><o:p></o:p>
</completed><o:p></o:p>
</serviceMethod><o:p></o:p>
<button targetElement="SearchButton"><o:p></o:p>
<click><o:p></o:p>
<invokeMethod target="helloService" method="invoke" /><o:p></o:p>
</click><o:p></o:p>
</button><o:p></o:p>
<label targetElement="Results"><o:p></o:p>
<bindings><o:p></o:p>
<binding id="resultsBinding" dataContext="helloService" <o:p></o:p>
<FONT face="Courier New" size=2>dataPath="response.object" property="text"</FONT>
automatic="false" /><o:p></o:p>
</bindings><o:p></o:p>
</label><o:p></o:p>
</components><o:p></o:p>
</page><o:p></o:p>
</script><o:p></o:p>
To me, the fact that it has Microsoft’s name behind it makes me really scared that this mess might actually get some momentum.