郵便番号から検索

郵便局のWebサイトで郵便番号・住所のデータがダウンロードできる。csvだけど。Webサービスを公開してフリーに使えるようにしてくれないかなー。あ、でも今回はブラウザからJavaScriptで問合せしたいので、Webサービスじゃ無理か・・・。自前でやらないとね。


ちなみにオブジェクト倶楽部WebService同好会には色んなサービスが紹介されてます。
http://objectclub.esm.co.jp/webservice/services.html


それはさておき、大分更新されていないページから手がかり発見。

anyService (Chris Bayes) [Client, JavaScript/XSLT | Win | IE/HTA] 0.3, 2001/05/15
SOAP client for IE 5.0 [not available] (Aaron Skonnard) [Client, JavaScript | Win | IE] ?, 2000/01
WebService Behavior (SOAP client for IE 5 and later) [not supported] (Microsoft) [Client, DHTML | Win | IE | HTC] 2.01, ?
XML Extras with SOAP (mozilla.org) [Client, JavaScript | Win | Mozilla] ?, 2000/12/28

MSDNWebService Behavior

About the WebService BehaviorThe WebService behavior enables client-side script to invoke remote methods exposed by Web Services, or other Web servers, that support the SOAP and Web Services Description Language (WSDL) 1.1. This behavior provides developers the opportunity to use and leverage SOAP, without requiring expert knowledge of its implementation. The WebService behavior supports the use of a wide variety of data types, including intrinsic SOAP data types, arrays, objects, and Extensible Markup Language (XML) data. The WebService behavior is implemented with an HTML Component (HTC) file as an attached behavior, so it can be used in Microsoft Internet Explorer 5 and later versions.

使い方を見てみたらこんな感じだった。

Attaching the WebService BehaviorThe first step in using the WebService behavior is to attach it to an element using the STYLE attribute. It is also necessary to set the id attribute so that this element can be easily referenced in script, as shown in the following example.

<body>
    <div id="service" style="behavior:url(webservice.htc)"></div>
</body>

IE6固有の機能みたいで残念。JavaScriptのみのがいいんだけど。

MozillaXML Extras

The XML Extras module contains several features that allow developers to treat XML as data i.e. not as just another document format. The module is structured as a drop-in component and exposes its XML-as-data features both to JavaScript and C /XPCOM users. The XML Extras module is built by default on all platforms, and is included in the browser installers so it is available in the nightly builds.

うーん、よく分からん。

おまけ

探してみたら、Xangってのを発見。ちょっと魅力的なことが書いてある。でもHibernated projectsに入ってました。残念。

Xang: Rapid development of dynamic server pages in JavaScript