JsHttpRequest: Low level Ajax library
- Friday Jan 19,2007 09:48 PM
- By R2D2
- In AJAX Frameworks, JavaScript
Dmitriy Koterov has written JsHttpRequest a light wrapper on top of XHR and friends that features:
- Cross-browser compatibility. Library works with IE5.0+, Mozilla 1.7+, FireFox 1.0+, Opera 7.3+, Safari (”+” means “in specified and newer versions”). By this token, code could work without ActiveX and XMLHttpRequest support (but if these capabilities are available, they are used automatically).
- File uploads from user browser to the server without page reloading.
- Full support of PHP debug features. If server-side script fails on an error (including fatal error, e.g., call of undefined function), client-side script can handle it correctly and show diagnostics. Besides response data, it is passed the output flow of server-side script which contains PHP error messages.
- Multi-dimensional data structures exchange (JSON analog) in client request and server response. At that, are used the standard PHP instruments — multi-dimensional associative arrays (request data available at $_REQUEST, response data may be saved to $_RESULT), as well as JavaScript standard capabilities — nested objects and properties. No XML in the level of API: you work with “native” language variables.
- PHP session support using usual way.
- Optimal data loading method choosing (XMLHttpRequest, Microsoft.XMLHTTP,
- Interface is compatible with XMLHttpRequest.
Downloads
Leave a reply
You must be logged in to post a comment.