MVC路由配置原则
摘要:基本原则:精确匹配的靠前;缩略路径靠后。具体来说:routes.MapRoute( "PhotoDetail", // Route name "Photos/Detail/{albumId}/{photoId}/{commentPageIndex}", // URL with parameters new { controller = "Photos", action = "Detail", albumId = UrlParameter.Optional, photoId = UrlParameter.Option
阅读全文
发现个EF的疑似Bug
摘要:定义下述实体,跟SQL语句交互的过程中,发现EF始终Map不上NickName属性,排查后发现注释掉LastTimestamp后居然就可以了……在我的网站项目中一直都是如此。后来新建了个测试项目、新建了个测试表,发现无法重现,汗~~~~~~初步推测,感觉像是EF底层用的是C++直接按照对象在内存中的布局信息去映射,而不是C#的反射来赋值。具体怎么搞的目前还不知道,先记录下来,以后有机会的话看看吧。 publicclassComment{publiclongCommentId{get;set;}publiclongPhotoId{get;set;}publicintCommentator{g..
阅读全文
猜猜这个是哪句话的编码
摘要:"%5b%22%27%c3%dc%c2%eb%27+%b3%a4%b6%c8%d3%a6%d4%da+6+%b5%bd+16+%d6%ae%bc%e4%a1%a3%22%2c%22%d1%e9%d6%a4%c2%eb%b4%ed%ce%f3%22%5d"^_^,你会喜欢的。
阅读全文
IO hello,world 2
摘要:Io> Verhicle Description := "This is first test"==> This is first testIo> vchTest Description==> This is first test
阅读全文
IO hello,world:
摘要:Io 20110905Io> Verhicle := Object clone==> Verhicle_0x204fec0: type = "Verhicle"Io> vchTest := Verhicle clone==> Verhicle_0x2051db0:有意思,哈哈。
阅读全文