随笔分类 -  asp.net

摘要:最近有个项目要调用客户用java写的带https的webservice,对方提供了证书文件 test.pfx,我这里调用方式如下://webservice代理类SvcService svc = new SvcService();//证书文件路径string filePath = ConfigurationManager.AppSettings["pfxUrl"];X509Certificate cert = new System.Security.Cryptography.X509Certificates.X509Certificate(filePath, "12 阅读全文
posted @ 2013-08-20 15:52 自由_ 阅读(36614) 评论(9) 推荐(2)
摘要:Razor引擎下载地址:http://github.com/Antaris/RazorEngine解析Model: string template = "Hello @Model.Name! Welcome to Razor!"; string result = Razor.Parse(template, new { Name = "World" });使用Helper:string template = @"@helper MyMethod(string name) { Hello @name } @MyMethod(Model.Name)! 阅读全文
posted @ 2013-07-09 20:22 自由_ 阅读(1149) 评论(0) 推荐(1)