ASP.NET MVC 1.0 Quickly


ASP.NET MVC 1.0 Quickly
eBook: $20.99
Formats: PDF, PacktLib, ePub and Mobi formats
$17.84
save 15%!
Print + free eBook + free PacktLib access to the book: $55.98    Print cover: $34.99
$34.99
save 37%!
Free Shipping!
UK, US, Europe and selected countries in Asia.
Also available on:
Overview
Table of Contents
Author
Reviews
Support
Sample Chapters
  • Rapid guide to building powerful web applications with ASP.NET MVC framework
  • Covers all facets of web application development including requirement analysis, design, building, testing, and deployment
  • Explore the ASP.NET MVC framework with several newly released features including WebForms, Script Combining, jQuery integration, and ASP.Net MVC AJAX helpers
  • Rich with example code, clear explanations, and interesting examples – a truly hands-on book for ASP.NET developers

Book Details

Language : English
Paperback : 256 pages [ 235mm x 191mm ]
Release Date : March 2009
ISBN : 184719754X
ISBN 13 : 9781847197542
Author(s) : Maarten Balliauw
Topics and Technologies : All Books, Application Development, Microsoft Development , Microsoft, .NET


Table of Contents

Preface
Chapter 1: ASP.NET MVC
Chapter 2: Your First ASP.NET MVC Application
Chapter 3: Handling Interactions
Chapter 4: Components in the ASP.NET MVC framework
Chapter 5: Routing
Chapter 6: Customizing and Extending the ASP.NET MVC Framework
Chapter 7: Using Existing ASP.NET Features
Chapter 8: AJAX and ASP.NET MVC
Chapter 9: Testing an Application
Chapter 10: Hosting and Deployment
Appendix A: Reference Application— CarTrackr
Appendix B: ASP.NET MVC Mock Helpers
Appendix C: Useful Links and Open Source Projects Providing Additional Features
Index
  • Chapter 1: ASP.NET MVC
    • Model-view-controller
      • View
      • Controller
    • The ASP.NET MVC framework
      • Driving goals of the ASP.NET MVC framework
      • Comparing ASP.NET MVC and ASP.NET Webforms
      • Choosing between ASP.NET MVC and ASP.NET Webforms
    • Summary
  • Chapter 3: Handling Interactions
    • Creating a form
      • Creating a form using HTML
      • Creating a form using HtmlHelper
    • Handling posts
      • Request variables
      • Updating objects from request variables
      • Action method parameters
    • Handling file uploads
      • Creating an upload form
      • Creating an upload controller action
    • Using the ModelBinder attribute
      • Using the default ModelBinder
      • Creating a custom ModelBinder
    • Validating data
    • Summary
  • Chapter 4: Components in the ASP.NET MVC framework
    • The ASP.NET MVC request life cycle
      • The RouteTable is created
      • The UrlRoutingModule intercepts the request
      • The routing engine determines the route
      • The route handler creates the associated IHttpHandler
      • The IHttpHandler determines the controller
      • The controller executes
      • A ViewEngine is created
      • The view is rendered
    • Extensibility
      • Route objects
      • MvcRouteHandler
      • ControllerFactory
      • Controller
      • ViewEngine
      • View
    • The model in depth
      • Creating a model
      • Enabling validation on the model
    • The controller in depth
      • Creating a controller
      • Rendering data on the response
      • Reading data from the request
      • Action method selection
      • Handling unknown controller actions
      • Action method attributes
    • The view in depth
      • Location of views
      • Creating a view
      • Master pages
      • View markup
      • Partial views
    • Action filters
      • IAuthorizationFilter
      • IActionFilter
      • IResultFilter
      • IExceptionFilter
    • Summary
  • Chapter 5: Routing
    • What is ASP.NET routing?
    • ASP.NET routing versus URL rewriting
    • UrlRoutingModule
    • Route patterns
    • Defining routes
      • Parameter constraints
      • Catch-all routes
      • Routing namespaces
      • Combining ASP.NET MVC and ASP.NET in one web application
    • Creating URLs from routes
    • Summary
  • Chapter 7: Using Existing ASP.NET Features
    • Session State
      • Reading and writing session data
      • Configuring session state
      • TempData
    • Membership, authentication, and authorization
      • Configuring web site security
      • Implementing user and role based security in a controller
      • Configurable authentication options
    • Caching
    • Globalization
      • Resources
        • Using local resources
        • Using global resources
      • Setting language and culture preferences
    • Mixing ASP.NET Webforms and ASP.NET MVC
      • Plugging ASP.NET MVC into an existing ASP.NET application
      • Plugging ASP.NET into an existing ASP.NET MVC application
      • Sharing data between ASP.NET and ASP.NET MVC
    • Building views at compile time
    • Summary
  • Chapter 8: AJAX and ASP.NET MVC
    • Different AJAX frameworks
      • XMLHttpRequest
      • JavaScript Object Notation (JSON)
    • ASP.NET AJAX
      • ASP.NET MVC AJAX helper
      • Working with JsonResult
    • jQuery
      • jQuery syntax
      • Using jQuery with ASP.NET MVC
      • Working with JsonResult
      • Using jQuery UI
    • Summary
  • Chapter 9: Testing an Application
    • Unit testing
      • Unit testing frameworks
      • Hello, unit testing!
      • Generating unit tests
      • Testing the action method
      • Mocking frameworks
      • Testing the Login action method
    • Mocking ASP.NET components
    • Testing routes
    • Testing UpdateModel scenarios
    • Summary
  • Chapter 10: Hosting and Deployment
    • Platforms that can be used
    • Differences between IIS 7.0 integrated and classic mode
    • Hosting an ASP.NET MVC web application
      • Creating a wildcard script map in IIS 7.0
      • Creating a wildcard script map in IIS 6.0
      • Modifying the route table to use file extensions
    • Summary
  • Appendix A: Reference Application— CarTrackr
    • CarTrackr functionality
      • Home page
      • Login screen
      • List of cars
      • Car details
      • Refuellings list
    • Data layer
      • Linq to SQL model
      • Repository pattern
    • Dependency injection
      • How CarTrackr controllers are built
      • Using Unity for dependency injection
    • ASP.NET MVC Membership Starter Kit
    • Form validation
    • ASP.NET provider model
    • Unit testing CarTrackr
      • Unit tests in CarTrackr
      • Mock repository
    • Summary
  • Appendix C: Useful Links and Open Source Projects Providing Additional Features
    • Information portals
      • ASP.NET/MVC
      • Aspdotnetmvc.com
      • DotNetKicks.com: Articles tagged with ASP.NET MVC
    • Blogs
    • Open source projects providing additional features for the ASP.NET MVC framework
      • ASP.NET MVC Design Gallery
      • MVC Contrib
      • xVal validation framework
      • ASP.NET MVC Membership Starter Kit
      • XForms
      • jQuery for ASP.NET MVC
      • Simple ASP.NET MVC controls
    • Alternative view engines
      • Spark view engine
      • NHaml view engine
      • NVelocity view engine
    • Example ASP.NET MVC applications
      • MVC storefront
      • FlickrExplorer
      • Yonkly
      • Kigg
      • CarTrackr

Maarten Balliauw

Maarten Balliauw has a Bachelor's Degree in Software Engineering and has
about eight years of experience in software development. He started his career
during his studies where he founded a company that did web development in PHP
and ASP.NET. After graduation, he sold his shares and joined one of the largest
ICT companies in Belgium, RealDolmen, where he continued web application
development in ASP.NET and application life cycle management in Visual Studio
Team System. He is a Microsoft Certifi ed Technology Specialist in ASP.NET and
works with the latest Microsoft technologies such as LINQ and ASP.NET 3.5. He has
published many articles in both .NET and PHP literature, such as MSDN magazine
Belgium, and PHP Architect. Ever since the fi rst announcement of the ASP.NET MVC
framework, he has been following all its developments and features.

Code Downloads

Download the code and support files for this book.


Submit Errata

Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.


Errata

- 11 submitted: last submission 28 May 2013

Errata type: Technical | Page number: 26 |

In the first paragraph, the sentence reads "Alternatively, this can be done by stating Model = employee prior top returning the view". It should read "Alternatively, this can be done by stating ViewData.Model = employee prior top returning the view".

 

Errata type: Typo | Page number: 33 |

The code snippet should have 'Model.Contact.ID', 'Model.Contact.Name', and 'Model.Contact.Email' instead of 'Model..ID', 'Model..Name', and 'Model..Email'.

 

Errata type: Code | Page number: 34 |

In the code snippet near the end of the page, <%=Html.Hidden("Id" does not have a closing tag. It should be <%=Html.Hidden("Id")%>

 

Errata type: Typo | Page number: 35 |

In the table listing the HtmlHelper methods, RouteLink is listed twice, once on each page. It should be listed just once.

 

Errata type: Technical | Page number: 36 |

The sentence "The strong-typed HtmlHelper methods are currently only available in the ASP.NET MVC Futures assembly (Microsoft.Web.Mvc.dll), which can be downloaded from http://aspnet.codeplex.com" has been added to the paragraph just below the table, before the code snippet.

Errata type: Code | Page number: 36 |

In the code snippet after the table, <%=Html.TextBox( x => x.Email )%> should be: <%=Html.TextBoxFor( x => x.Email )%>

 

Errata type: Typo | Page number: 39 |

Under the heading 'Handling file uploads', the fourth sentence reads "old skool HTML form". It should be "old school HTML form".

 

Errata type: Code | Page number: 73 |

In the upper code snippet, <% foreach (Task task inModel.Task) { %> should be: <% foreach (Task task in Model.Task) { %>

 

Errata type: Code | Page number: 105 |

Currently the code snippet under the heading 'Creating a ViewEngine' reads: public interface IViewEngine { ViewEngineResult FindPartialView(ControllerContext controllerContext, string partialViewName); ViewEngineResult FindView(ControllerContext controllerContext, string viewName, string masterName); } It should read: public interface IViewEngine { ViewEngineResult FindPartialView(ControllerContext controllerContext, string partialViewName); ViewEngineResult FindView(ControllerContext controllerContext, string viewName, string masterName); void ReleaseView(ControllerContext controllerContext, IView view); }

 

Errata type: Typo | Page number: 118 |

The first entry in the attributes table is currently "timeout". It should be "mode".

 

Errata type: Typo | Page number: 130 |

The graphical representation of the folder structure under the heading "Using local resources" has a typo. "Views" has been misspelled as "Vews"

 

Sample chapters

You can view our sample chapters and prefaces of this title on PacktLib or download sample chapters in PDF format.

Frequently bought together

ASP.NET MVC 1.0 Quickly +    Building Websites with the ASP.NET Community Starter Kit =
50% Off
the second eBook
Price for both: $24.00

Buy both these recommended eBooks together and get 50% off the cheapest eBook.

What you will learn from this book

  • Learn about the architecture of ASP.NET MVC framework
  • Integrate AJAX and ASP.NET MVC and use ASP.NET AJAX and jQuery to build powerful database-driven web applications
  • Customize the ASP.NET MVC request lifecycle
  • Give your application clean URLs and a direct coupling between URL and application logic
  • Create mock objects to improve the design of code within Test-Driven deployment
  • Get familiar with unit testing in a web application, including advanced unit testing concepts such as mocking

In Detail

Using WebForms has led to problems for ASP.NET developers, such as low testability and inconsistent code. These problems become increasingly relevant when trying to develop or maintain anything but the simplest web site.

This book takes you through the ASP.NET MVC framework to help you simplify and build web applications quickly. With example applications built on best practices and with clear explanations, you will get started in no time.

The MVC pattern is widely accepted as one of the best approaches for building modern web applications and Microsoft's new ASP.NET MVC Framework offers a fully supported way for developers to implement MVC in ASP.NET.

This book takes you through the essential tasks to create powerful web applications as fast as possible. These essential tasks are explained clearly, with well-structured instructions. The book does not cover every single feature in detail; it provides precise information for you to get started, and takes you through the creation of an example application that covers MVC application design techniques.

In addition to helping you write code, this book covers unit testing, to improve the stability and quality of the application you are building. It provides a quick reference to the MOQ framework to aid in unit testing. With this book, you will soon have the skills that will make you an ASP.NET developer to be reckoned with, and you will be creating applications with a speed that will astonish your colleagues and boss!

Simplify and build web applications with the ASP.NET MVC framework quickly

Approach

The book walks through the main concepts of the MVC framework to help ASP.NET developers to move on to a higher level. It includes clear instructions and lots of code examples. It takes a simple approach, thereby allowing you to work with all facets of web application development: requirements, designing, testing, and deployment.

Who this book is for

This book is for ASP.NET developers who want a fast-paced guide to building powerful web applications using the ASP.NET MVC framework. All the code examples are in C#.

Code Download and Errata
Packt Anytime, Anywhere
Register Books
Print Upgrades
eBook Downloads
Video Support
Contact Us
Awards Voting Nominations Previous Winners
Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
Resources
Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software