xsl-list
[Top] [All Lists]

Re: [xsl] [XSL] XSL Browser Integration

2007-09-13 15:28:12
On Thu, 13 Sep 2007 13:01:23 -0600, Alain <alainb06(_at_)free(_dot_)fr> wrote:

- users preferences such as : preferred languages (or the http header accept_language string, for internationalisation purpose)
- navigation items such as : referrer, history (tainted)
- computer environment : screen resolution, colour width, OS, browser, initial canvas size, etc...

Whatever has been sent from the client to the server as part of the HTTP header can easily be wrapped in an XML envelope and echoed back to the client, the easiest of which is to use the document function to access a URI who's only purpose is to echo back the header information which has been parsed and XML'ized. Dependent upon the information you are looking for, parsing the header string might be a faster task for client, or in other words wrapping the entire text string in an XML envelope instead of parsing it and returning each property in a separate <property>value</property> element.

There are some other options: Using an onload event to trigger and asynchronous call back to the server with the desired (property=value)* accessed via Javascript which can then be cached as part of the client session and returned with each subsequent request as part of the XML data and/or as part of a request to a URI via the document function who's only task is to return the cached XML data file for each session. The latter will be the cheapest overall solution, though you will incur an additional HTTP GET which could be avoided if the data was dynamically embedded with each request.

It really is dependent on your server side resources. If they're limited, the less dynamically generated content the better. If you're underutilizing your available server side resources then embedding that data with each subsequent request will provide a faster overall browsing experience for your customers.

--
/M:D

M. David Peterson
http://mdavid.name | http://www.oreillynet.com/pub/au/2354 | http://dev.aol.com/blog/3155

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--