Chapter 3: Develop the user experience
Plan for search engine optimization and accessibility
- 使用analytical tools分析HTML,如SEO toolkit from MS, Webmaster Tools from Google, W3C Markup Validation Service
- 使用Browser插件观察结构,如IE的F12可打开developer Toolbar。
- WAI-ARIA for accessibility
Plan and implement globalization and localization
- planning a localization strategy
- 从HTTP头的Accept-Language取得browser的preferred language,但要设置<system.web>的<globalization culture="auto" uiculture="auto" enableclientbasedculture="true" />
- 使用resource到UI
- 使用resx file
- 在client端使用globalize.js
- client端主动设置culture
- 使用satellite assemblies,使用al.exe生成satellite dlls.
Design and implement MVC controllers and actions
- attributes和filters
- RequireHttpsAttribute
- ValidateAntiForgeryTokenAttribute
- ValidateInputAttribute
- AuthorizeAttribute
- ChildActionOnlyAction
- ActionFilterAttribute
- OnActionExecuting
- OnActionExecuted
- OnResultExecuting
- OnResultExecuted
- 使用attributes
- on the action iteslf
- on controller level
- through global filters,如filters.Add(new RequireHttpsAttribute());
- 实现action的行为
- 实现action的result
- ContentResult
- EmptyResult
- FileResult
- JavaScriptResult
- JsonResult
- PartialViewResult
- RedirectResult
- RedirectToRouteResult
- ViewResult
- 实现model binding
- DefaultModelBinder
- LinqBinaryModelBinder
- ModelBinderAttribute
- ModelBinderDictionary
weakly-typed style,如@Html.TextBox("login.UserName")
使用Bind attribute,
如public ActionResult Login([Bind(Prefix="login")]LoginUser user)
public ActionResult Save([Bind(Exclude="Salary")]Employee emp)
使用value provider取model
- FormsValueProvider
- QueryStringProvider
- HttpFileCollectionValueProvider
- RouteDataValueProvider
Design and implement routes
- 使用MapRoute定义一个route
- 使用route的限制,如 new {id=@"\d+"}
- ignore一个route
- Adding custom route parameters
- 使用area
Control application behavior by using MVC extensibility points
- 使用filter和controller factory
- Authorization
- Action
- Result
- Exception
- 通过action result控制,override ExecuteResult() of System.Web.Mvc.ActionResult
- 通过view engine
- 通过model binder
- 通过route handler
Chapter 3: Develop the user experience的更多相关文章
- Chapter 2: Design the user experience
Apply the user interface design for a web application 介绍了Css的常用属性和html5的新element,以及Htmlhelper的简单方法,如 ...
- halcon算子
halcon的算子列表 Chapter 1 :Classification 1.1 Gaussian-Mixture-Models 1.add_sample_class_gmm 功能:把一个训练样 ...
- halcon的算子列表
Chapter 1 :Classification 1.1 Gaussian-Mixture-Models 1.add_sample_class_gmm 功能:把一个训练样本添加到一个高斯混合模型的训 ...
- Halcon 常用算子使用场合
Chapter 1 :Classification 1.1 Gaussian-Mixture-Models 1.add_sample_class_gmm 功能:把一个训练样本添加到一个高斯混合模型的训 ...
- Halcon算子解释
Halcon算子解释大全 Halcon/Visionpro视频教程和资料,请访问 重码网,网址: http://www.211code.com Chapter 1 :Classification 1. ...
- [eBook]Inside Microsoft Dynamics AX 2012 R3发布
最近一本关于Microsoft Dynamics AX 2012开发的书<Inside Microsoft Dynamics AX 2012 R3> 发布. Book Descriptio ...
- Halcon算子含义
1.1 Gaussian-Mixture-Models 1.add_sample_class_gmm 功能:把一个训练样本添加到一个高斯混合模型的训练数据上. 2.classify_class_gmm ...
- Girl Develop It Chapter Leaders at 2015 Annual Leadership Summit
Girl Develop It Chapter Leaders at 2015 Annual Leadership Summit Corinne Warnshuis, Executive Direct ...
- Android Programming: Pushing the Limits -- Chapter 4: Android User Experience and Interface Design
User Stories Android UI Design 附加资源 User Stories: @.通过写故事来设计应用. @.每个故事只关注一件事. @.不同的故事可能使用相同的组件,因此尽早地 ...
随机推荐
- SQLSERVER如何获取一个数据库中的所有表的名称、一个表中所有字段的名称
1.查询数据库中的所有数据库名: SELECT Name FROM Master..SysDatabases ORDER BY Name 2.查询某个数据库中所有的表名: SELECT Name FR ...
- Theoretical comparison between the Gini Index and Information Gain criteria
Knowledge Discovery in Databases (KDD) is an active and important research area with the promise for ...
- Spark MLlib 之 Basic Statistics
Spark MLlib提供了一些基本的统计学的算法,下面主要说明一下: 1.Summary statistics 对于RDD[Vector]类型,Spark MLlib提供了colStats的统计方法 ...
- Consistent hashing —— 一致性哈希
原文地址:http://www.codeproject.com/Articles/56138/Consistent-hashing 基于BSD License What is libconhash l ...
- 《java集合概述》
JAVA集合概述: Collection: |---List有序的:通过索引就可以精确的操作集合中的元素.元素是可以重复的. List提供了增删改查的动作. 增加add(element) add(in ...
- iOS 3D Touch 适配开发
3D Touch的主要应用 文档给出的应用介绍主要有两块: 1.A user can now press your Home screen icon to immediately access fun ...
- Quartz Core框架之core animation
1.时间功能 (1)CFTimeIntervalCACurrentMediaTime ( void ); :返回当前的绝对时间 2.转换功能 (1)bool CATransform3DIsIdenti ...
- MVC SSO登陆 的麻烦事~
前段时间用MVC + Redis 做session搞了个简单的单点登录Web站.真是日了狗的问题多. 今天正好睡不着,做个备忘笔记>_< 实现方法很简单,无非就是从重载个Controlle ...
- 简单C程序生成的汇编代码分析
首先给出完整的C代码: int g(int x) { ; } int f(int x) { return g(x); } int main(void) { )+; } 使用命令:gcc –S –o h ...
- WCF XmlSerializer GetType 反射类型 报错 解决方案
为图省事,用现有的EF,和web一起使用一个Model类 当进行到 XmlSerializer xmlSerializer = new XmlSerializer(obj.GetType()); 会报 ...