DCSIMG
Prototype - Rotem Bloom's Blog

Rotem Bloom's Blog

Share knowledge on .NET and web development

News

About Me

Glad to help and share knowledge on .NET and also huge fan of Dream Theater.

Contact me via messenger

View Rotem Bloom's profile on LinkedIn

Dream Theater Pics

Blogs I Read

Browse by Tags

All Tags » Prototype (RSS)
Cross site Ajax plugin for Prototype
Thierry Schellenbach has implemented a Prototype plugin that allows you to do cross site remoting using the dynamic script tag method that other frameworks such as Dojo and jQuery have supported for awhile. You can implement this by simply setting crossSite: true as a config parameter to Ajax.Request. Code example: new Ajax.Request('myurl', { method: 'GET', crossSite: true , parameters: Form.serialize(obj), onLoading: function() { //things to do at the start }, onSuccess: function...
JS Script Get Element Position With Scroll Support
Well, I was looking on the web for JavaScript fuction that return any DOM element position and also consider browser scroll. I finally came up with the solution and wanted to share it with you. In order that the script will work you need reference to Prototype JavaScript Framework. Well here is the JavaScript code: function getDocumentWindow(doc) { return (doc.parentWindow || doc.defaultView); } function getPosRelativeToWindow(element, topWindow, considerScrollOffset) { var l = 0, t = 0; var pos...