DCSIMG
JavaScript - 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 » JavaScript (RSS)
firefox not executing javascript on back button
Hi, firefox has a cache behavior that uses in-memory caching for entire Web pages, including their JavaScript states, for a single browser session. This can cause to unexpected javascript and HTML behavior when pressing on the browser back button. For example: PageLoad will not fired javascript code will not executed DHTML that was created by JavaScript will be shown and more... In case firefox cache is something you want to prevent, Below are some common programmatic reasons that a page will not...
ASP.NET MVC Razor CSS and Javascript Compress and Manager
Hi, If you are ASP.NET MVC Razor developer and you are looking for a nice solution to Combine, Compress and Manage your CSS and JavaScript files, Well SquishIt can fit your needs. Razor Code Sample: @ MvcHtmlString . Create ( SquishIt . Framework . Bundle . Css () . Add ( "~/media/css/reset.css" ) . Add ( "~/media/css/style.less" ) . Add ( "~/media/css/handheld.css" ) . Render ( "~/media/css/combined_#.css" )) @ MvcHtmlString . Create ( SquishIt . Framework...
Jquery TreeView with RTL support
Hi All, Well after month of silent (7 I think) I got back with a new post on Jquery TreeView. First you can download the plugin from here . I must say this plugin is amazing very fast even with large trees. The problem of Jquery TreeView is the lack of RTL (Right To Left) support for languages like: Hebrew, Arabic etc... If you got the same problem I have and you need Jquery TreeView RTL version you can download it from my blog right here . To the AJAX fans I also add a nice cool ajax application...
How to change ASP.NET CheckBox control Enabled property using javascript. bug or behavior?
Changing status to enabled\disabled for regular input type checkbox in javascript is very simple. You just need to use the javascript code: var checkBox = document.getElementById( "chkToTest" ); checkBox.disabled = true\false; Well try to use this javascript code above on ASP.NET checkbox web control when you set the server side Enabled property to false like below: chkToTest.Enabled = false ; I'm telling you it will not work!!!! Do you ask how to solve this bug or behavior? You just...
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...