public static MvcHtmlString RenderAuthStylesheet(this HtmlHelper htmlHelper) { var inlineStyles = new HtmlTag("style") .Attr("type", "text/css") .Text(@".largeBtn { background-image: url(" + WebResource(typeof(AbstractAuthHandler), "SimpleSocialAuth.MVC3.Images.auth_logos.png") + "); }"); var includedStyles = new HtmlTag("link") .Attr("rel", "stylesheet") .Attr("href", WebResource(typeof(AbstractAuthHandler), "SimpleSocialAuth.MVC3.Stylesheets.auth.css")) .Attr("type", @"text/css"); return new MvcHtmlString( inlineStyles .After(includedStyles) .ToHtmlString()); }