| 发表于:2007-04-26 16:42:494楼 得分:0 |
在ie中,可以把xml作为table的数据源的,直接显示出来 datasrc attribute ¦ datasrc property internet development index -------------------------------------------------------------------------------- sets or retrieves the source of the data for data binding. syntax html <element datasrc = sid... > scripting object.datasrc [ = sid ] possible values sid string that specifies or receives the identifier of the data source. the property is read/write. the property has no default value. expressions can be used in place of the preceding value(s), as of microsoft® internet explorer 5. for more information, see about dynamic properties. remarks tabular and single-valued data consumers use the datasrc property to specify a binding. the property takes a string that corresponds to the unique identifier of a data source object (dso) on the page. the string must be prefixed by a number sign (#). when the datasrc property is applied to a tabular data consumer, the entire data set is repeated by the consuming elements. when the datasrc property is applied to a table, any contained single-valued consumer objects that specify a datafld property are repeated for each record in the supplied data set. to complete the binding, the binding agent interrogates the enclosing table for its data source. a tabular data consumer contained within another tabular data consumer (table) must specify an explicit datasrc. example in this example, a text box is bound to the customer_name field of a data source object with an id of "customer ". because the text box is located within a data-bound table, the text box is repeated to display each of the records provided by the data source. <table datasrc= "#customer "> <tr> <td> <input type=textbox datafld= "customer_name "> <td> <tr> </table> standards information there is no public standard that applies to this property. | | |
|