Dec 17, 2009

A dummy example of html helper

public static class HtmlHelperExt
{
    public static string GetDebugInfo(this HtmlHelper html)
    {
        return "Hello";
    }

    public static void Debug(this HtmlHelper html)
    {
        var writer = html.ViewContext.HttpContext.Response.Output;
        writer.Write("

hello

"); } }