ASP.NET MVC Returning Partial View as a full View Page

谁说胖子不能爱 提交于 2019-12-11 14:51:16

问题


I have a number of partial views that are used to render media in different formats (embedded video mainly). I now have a requirement that has me displaying these videos inside an iframe. Is there a way that I can return a minimal HTML page with the partial views embedded in it?


回答1:


Check out these discussion about how to render a partial view to string.

RenderPartial to String in ASP.NET MVC Beta

RenderPartial to string



来源:https://stackoverflow.com/questions/767722/asp-net-mvc-returning-partial-view-as-a-full-view-page

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!