[Xsltforms-support] Improving XSLTForms performance in IE
Brought to you by:
alain-couthures
From: Stephen C. <Ste...@ut...> - 2010-05-24 10:02:13
|
Hello, I recently had feed-back from some users and the main issue was slow form loading in IE. I am wondering if there may be ways to get around this. I think that I am mainly having problems due to large XML files being included as external xform instances, that are then parsed into 'XDocument' javascript objects by XSLTForms. I previously asked Alain if these could be natively parsed as DOMDocument objects by the browser and then used as such by XSLTForms. I think that the reason why this could not work is the lack of XPath support in browsers. However, I now wonder if a half-way house solution might work. That is XNodes are wrapper objects for DOMNodes and the XSLTForms Xpath evaluations are actually using the DOMNode name, values (or childNodes) behind the scenes. So the XDocument.parse() method would, in the case of external instances, build a tree of XNodes each holding a reference to a DOMNode and for each evaluation of such an XNode, the node itself would have to decide if it was purely javascript based or DOMNode based. If this mechanism might possibly work, I'd be happy to have a go at trying it out. I think XSLTforms has a niche only because all browsers do not support the Xforms standard natively. If you are an organisation using Xforms then there is no problem to use a plugin (though I've not tried one), so XSLTforms is filling the opportunity for a cross-browser solution but it hasn't quite got there yet in my view due to the current slowness in IE. Realistically, trying to add more feature support is not a good use of time whilst this problem exists. Browsers are very fast at parsing XML and also transforming using XSLT, it seems to me that XSLTForms is making good use of the later but ignoring the potential of the former. Not using IE is an option perhaps, but you have to ask what is XForms competing against and is the competion working OK in IE? For me at least the competition is AJAX frameworks that can auto-generate a web-app from a relational database schema and do client-side validation. There are plenty of options in this space and all work well in IE I'd say (we use ZK framework). My intention is not to put down XSLTforms at all, just to state my concerns about priorities. Cheers Steve Cameron |