Archive

Posts Tagged ‘asp.net mvc’

ASP.NET MVC 2 released!

March 14th, 2010 No comments

Quick note that ASP.NET MVC 2.0 was released on Friday, still yet to play with the RTM, but don’t let me stop you. Go for it!

Link dump – mostly from Scott Hanselman’s announcement:

Exciting and just in time for a fairly large project we’re working on right now 🙂

{lang: 'en-GB'}
Share

QuickFix: jQuery $.getJSON() fails in IE6 & IE7

October 27th, 2009 15 comments

Had a nasty issue with jQuery + jSON + IEx just now – still at work because of it!

This bit of code works perfectly fine on Firefox and Chrome:

function onUnitsModified() {
            $.getJSON("<%=Url.Action("GetTotalUnitCount", "ProjectReaper")%>", null, function(result) {
                if(result > 0)
                  // Do stuffs here
                }
            });
            return true;
}

But in IE we’ve come to realise that the first hit is successful, future json requests ones are not hitting the ASP.NET MVC actions (I put a breakpoint). You could append a time stamp to get rid of this annoying caching bug, but alternatively you can use the ajaxSetup options to disable caching.

function onUnitsModified() {
            $.ajaxSetup ({ cache: false}); 
            $.getJSON("<%=Url.Action("GetTotalUnitCount", "ProjectReaper")%>", null, function(result) {
                if(result > 0)
                  // Do stuffs here
                }
            });
            return true;
}

Darnit! Hope someone else doesn’t waste their time trying to fix this now 🙂

{lang: 'en-GB'}
Share

Hot Panties: ASP.NET MVC Released!

March 19th, 2009 No comments

Microsoft ASP.NET

JIT for a deployment of UAT for a project we’re working on, Microsoft have released ASP.NET MVC framework as a final RTM only hours ago.

I’ve been working with the framework for the past couple of months and I have to admit its been a burst of fresh air from the standard webforms model.

Download a copy of the RTM and give the samples ago, its bootilicious and hopefully will bring a new cleaner way to write your ASP.NET sites in the future – not that you couldn’t do this before.

The other cool addition is the MVCContrib project which is a complimentary tidbit to help you.

See the ASP.NET MVC site for more information including the ASP.NET MVC Source and dont forget about the free eBook chapter from the upcoming book Professional ASP.NET MVC 1.0.

Ah, memories of Struts without the tears and the pain.

{lang: 'en-GB'}
Share