[mvc2inaction-discuss] Chapter 3

瀏覽次數:0 次
跳到第一則未讀訊息

br...@surewinsolutions.com

未讀,
2010年5月11日 上午10:50:222010/5/11
收件者:mvc2inaction-discuss
In section 3.5.3 "Selecting Templates"

There is a section that reads:

If a template isn’t found in these folders, or if the view isn’t in an
area, the default view search locations are used:
 <ControllerName>/EditorTemplates/<TemplateName>.ascx (or .aspx)
 Shared/EditorTemplates/<TemplateName>.ascx (or .aspx)


I think this might be more clear if it specified that this was in the
Views sub-folder, i.e.

If a template isn’t found in these folders, or if the view isn’t in an
area, the default view search locations are used:
 Views/<ControllerName>/EditorTemplates/<TemplateName>.ascx
(or .aspx)
 Views/Shared/EditorTemplates/<TemplateName>.ascx (or .aspx)

It took me a bit to discover why my template wasn't working.

--
--------------------
Please feel free to comment on the progress of the book, the content, and the code samples. All code and text is available on the book's GitHub site at http://github.com/jeffreypalermo/mvc2inaction. We hope developing this book out in the open and with your feedback makes it a great book for the community.

Jeffrey Palermo

未讀,
2010年5月11日 上午11:31:162010/5/11
收件者:mvc2inacti...@googlegroups.com
Brian,
Really good idea.  We'll have to peg that for the next edition as the book is already at the printer now.  Thanks for posting it here, though because at least it is searchable.

Best regards,
Jeffrey Palermo
回覆所有人
回覆作者
轉寄
0 則新訊息