* object 要素 classid 属性 (HTML, XHTML 1) [1] [[HTML]] の [CODE(HTMLe)[[[object]]]] 要素の [DFN[[CODE(HTMLa)[classid]] 属性]]は、物体の実装の場所を指定します。 [2] 仕様書: - [[HTML 4]] -- [CITE[13.3 Generic inclusion: the [CODE(HTMLe)[OBJECT]] element]] -- [CODE(HTMLe)[object]] 要素 [CODE(HTMLa)[classid]] 属性 -- [CITE[13.3.3 Global naming schemes for objects]] -- [CITE[HTML 4 Changes]] [10] HTML 4 DTD の注釈 (参考) には [Q[identifies an implementation]] と書かれています。 [[#comment]] ** 属性値 [3] この属性の値は [CODE(SGML)[%[[URI]]]] です。 [[SGML]] 的には [CODE(SGML)[[[CDATA]]] です。]] [4] この属性は省略できます。 [[#comment]] *** URI scheme [5] この属性の値に使われる [[URI参照]]は、ほとんどの場合 [CODE(URI)[[[clsid]]:]] scheme です。 というか、 [CODE(HTMLa)[classid]] が使われるのはほとんど [[ActiveX Control]] でのみです。 [[Java]] applet では [CODE(URI)[[[java]]:]] scheme を使うですが [SRC[HTML 4 13.3]]、本当に使われているのでしょうか? 見たことがありません。 他の使用例・実装例があったら教えてください。 [11] >>5 [CODE(URI)@en[[[java]]:]] [[URI]] も一応実装はされているみたいです。。。 ([[名無しさん]] [sage] [WEAK[2005-12-25 09:26:47 +00:00]]) [12] >>11 [[MacIE]] 5, [[Firefox]], [[Safari]] で実装されているらしいです。 ([[名無しさん]] [sage]) [14] [[HTML 4]] 仕様書には >>13 の例 ([CODE(URI)@en[[[http]]:]] [[URI]]) があり、ためしに検索してみる () とそれを引いたらしい例が大量に出てきますが、実装されているものなのかどうかは不明です。 ;; [[HTML 4]] 仕様書には [[Python]] とか [[Tcl]] とか怪しい例がたくさん載っているw ([[名無しさん]] [sage]) [16] [CODE(URI)@en[[[x-oma-application]]:]] というのも ([[名無しさん]]) [19] >>18 によると [[NN4]] では [CODE(URI)@en[[[javabean]]:]] が実装されていたようです。 [[#comment]] ** 他との関係 [6] 物体の種類により、 [CODE(HTMLa)[[[data]]]] 属性 (データ) と [CODE(HTMLa)[classid]] 属性 (実装) の一方または両方を指定できます。 ただし、両方があるときの挙動は規定されていません。 可搬性のため、実装が追加のデータを取り寄せる必要があるときには [CODE(HTMLe)[[[param]]]] を使うべきです。 [SRC[HTML 4.01 13.3]] [7] この属性の値が[[相対URI参照]]であれば、 [CODE(HTMLa)[[[codebase]]]] 属性によって解決されます ([[HTML//基底URI]] を参照)。 [CODE(HTMLa)[code]] の型のヒントとして [CODE(HTMLa)[[[codetype]]]] 属性と [CODE(HTMLa)[[[type]]]] 属性が使われます。 [CODE(HTMLa)[code]] の資源は [CODE(HTMLa)[[[archive]]]] の URI 参照で指定された資源に含まれているかもしれません。 [[#comment]] ** 例 [8] Java applet の例 [PRE(HTML)[ ]PRE] [WEAK[(HTML 4 仕様書より、改)]] [9] ActiveX control の例 [PRE(HTML)[

Clock: This application is not supported. ]PRE] [WEAK[(HTML 4 仕様書より、改)]] [13] [[Python]] [[プログラム]]を埋込む例 [SRC@en[HTML 4 13.3.1]] [PRE(HTML example code)[

]PRE] ([[名無しさん]] [sage]) [15] [PRE(HTML example code)[ ]PRE] ;; [CITE[Microsoft Java 仮想マシン 移行ガイド バージョン 1.3.2]] (2003年付) ([[名無しさん]] [sage]) [[#comment]] ** メモ [17] [CITE[Bug 46569 – Flash Publish codes OBJECT element with IE specific classid attribute]] ([CODE[2008-01-27 11:24:07 +09:00]] 版) ([[名無しさん]]) [18] [CITE[Bug 208024 – Mozilla does not support javabean scheme for OBJECT CLASSID]] ([CODE[2008-01-27 11:32:32 +09:00]] 版) [20] [CITE@en[MAMA: Plug-ins - Opera Developer Community]] ([TIME[2008-12-08 23:14:26 +09:00]] 版) [21] [CITE[Re: element feedback]] ([[Ian Hickson ]] 著, [TIME[2008-11-20 23:43:48 +09:00]] 版) > [PRE[ On Thu, 20 Nov 2008, Michael A. Puls II wrote: > > The spec currently says that Opera, Firefox and Safari can use the > classid attribute to load the plugin if they want. This might be done by > mapping a classid to a plugin handler. They just need to fall back if > that fails, instead of then trying type and data. > > The danger of mapping classid for non-activex browsers is that sometimes > an that uses classid="" might be meant for an activeX plugin > that uses a different API than the NPAPI version of the plugin. This > where vendors would have to be careful before deciding what classids to > support. > > If that's not the handling intended by the spec and classid is meant to > be IE-only, the spec should be clarified. classid isn't a valid > attribute, so maybe that doesn't matter. What you describe is what I intended. There's a commented list of IDs that maybe they should support (based on what they do support) but I don't know whether to make it formal or not. So far I've opted to not make it formal. I think it might depend on a platform-by-platform basis. ]PRE] [22] [CITE[Re: element feedback]] ([[Michael A. Puls II ]] 著, [TIME[2008-11-21 00:01:28 +09:00]] 版) > clsid:6BF52A52-394A-11D3-B153-00C04F79FAA6 is for the WMP 7+ api. It uses a different API than the 6.4 API that's used by the NPAPI 6.4 wmp plugin (npdsplay.dll) that uses application/x-mplayer2. > So, mapping the classid in this case can break things, like volume, file loading, autostart etc and others things, including scripting. > However, clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95 is the 6.4 classid. It's still meant for the activeX 6.4 plugin, but it's pretty compatible with the NPAPI 6.4 wmp plugin. [23] [CITE[Re: element feedback]] ([[Ian Hickson ]] 著, [TIME[2008-11-21 00:36:31 +09:00]] 版) >Yeah... I think I'll leave this unspecified. [24] [CITE[IRC logs: freenode / #whatwg / 20090610]] ([TIME[2009-08-29 19:19:58 +09:00]] 版)