| Page 1 of 1 | [ 2 posts ] |
|
Hi,
I'm brand new to YUI. Just started today. I've managed to modify one of the examples to display XML data from a local XML database in a DataTable (YUI 3). The code works in IE8 but the datasource request is failing in Chrome 17. Any help would be much appreciated. Please see the code in question below: <script src="http://yui.yahooapis.com/3.4.1/build/yui/yui-min.js"></script> <div id="table" class="yui3-skin-sam dt-example"></div> <script> YUI().use("datasource-io", "datasource-xmlschema", "datatable-datasource", function(Y) { var cols = ["name", "id"]; var dataSource = new Y.DataSource.IO({ source:"http://localhost:8080/exist/rest/" }); dataSource.plug(Y.Plugin.DataSourceXMLSchema, { schema: { resultListLocator: "collectible", resultFields: [{key:"name", locator:"@name"}, {key:"id", locator:"@id"}] } }); var table = new Y.DataTable.Base({ columnset: cols, summary: "Collectibles List", caption: "Collectibles List" }); table.plug(Y.Plugin.DataTableDataSource, { datasource: dataSource, initialRequest: "?_query=for%20$x%20in%20doc('/db/sims/config/database/collectibles.xml')//collectibleitem%20return%20<collectible%20name='%7B$x/@name%7D'%20id='%7B$x/@id%7D'/>&_howmany=1000" }); dataSource.after("response", function() { table.render("#table")} ); }); </script> Many thanks, Adam |
|
I'm presuming this is a security issue. It doesn't work in Firefox either but it is strange that it is working in IE8. Any help or even a nudge in the right direction would be really appreciated.
|
| Page 1 of 1 | [ 2 posts ] |
| You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum |
© 2006-2013 Yahoo! Inc. All rights reserved.
All code on this site is licensed under the BSD License unless stated otherwise.
About This Site · Security Contact Info
Powered by phpBB® Forum Software © phpBB Group