Kazi Manzur Rashid's Blog
Sharing Thoughts and Learning
-
Blog moved to kazimanzurrashid.com
I have moved my blog to my own domain http://kazimanzurrashid.com. See you over there.
-
Integrate Html5 Form in ASP.NET MVC
This article is divided into three parts. In the first, part I will show you how you can add Html5 forms in your ASP.NET MVC application with very minimum effort. In the second part, I will show you how to implement client side validation which will trigger automatically even when the browser does not have the html5 client side validation support and in the last part I will show widgetify the form in the client side with jQuery for the older browser that does not have support for Html5 form.
-
Microsoft WebPage/WebMatrix and Ruby Sinatra
This is a continuation of my previous post. In this post, I will do a side by side comparison of Microsoft WebMatrix/WebPage with Ruby Sinatra. The reason I picked Sinatra because both Sinatra and WebMatrix can be used to develop web sites with very minimal effort.
-
Back to Basic - Writing meaningful, accessible and semantic markup in Html5
Unless you are living in a cave, I expect you heard Html5 and know that most of the modern browsers has the reasonable support to render html5 pages. In this post, I will take the tiny sample “Bakery” which comes with the Microsoft WebMatrix as a site template and truly upgrade it to html5. The reason I mentioned “truly” because it is already using html5
doctypebut the markup is still in xhtml. You can click here if you want to see a screenshot of this website. -
Use Razor as ASP.NET MVC ViewEngine
Since the release of Razor I could not manage time to give a deep dive into this new framework. Last night, I started to explore, the idea was to create ASP.NET MVC View Engine, yes I know the official version is coming up end of this month, but it will give me enough details of the Razor internals in the mean time. Part of the goal was to port the default ASP.NET MVC application in Razor. And here is the basic version:
-
Create a Build Script with Rake in Iron Ruby that Integrates StyleCop, Simian, FxCop, MSpec and NCover
With the release of Iron Ruby we are no more tide up with the xml based build script like NAnt and MSBuild, we can now use Rake with Iron Ruby to build our .NET based projects. In this post, I will show you a very basic build script in rake that will integrate StyleCop, Simian, FxCop, MSpec and NCover. I will use the same fund transfer project that I used in my previous post.
-
Write your Tests in RSpec with IronRuby
[Note: This is not a continuation of my previous post, treat it as an experiment out in the wild. ]
-
Start Learning Ruby with IronRuby – Setting up the Environment
Recently I have decided to learn Ruby and for last few days I am playing with IronRuby. Learning a new thing is always been a fun and when it comes to adorable language like Ruby it becomes more entertaining.
-
Localization with ASP.NET MVC ModelMetadata
When using the
DisplayFor/EditorForthere has been built-in support in ASP.NET MVC to show localized validation messages, but no support to show the associate label in localized text, unless you are using the .NET 4.0 with Mvc Future. Lets a say you are creating a create form for Product where you have support both English and German like the following. -
MvcExtensions - ActionFilter
One of the thing that people often complains is dependency injection in Action Filters. Since the standard way of applying action filters is to either decorate the Controller or the Action methods, there is no way you can inject dependencies in the action filter constructors. There are quite a few posts on this subject, which shows the property injection with a custom action invoker, but all of them suffers from the same small bug (you will find the
BuildUpis called more than once if the filter implements multiple interface e.g. bothIActionFilterandIResultFilter). The MvcExtensions supports both property injection as well as fluent filter configuration api. There are a number of benefits of this fluent filter configuration api over the regular attribute based filter decoration.