我在asp.net mvc中创建了一个详细信息页面 . 并为此示例问题工作,如堆栈网址 . Replacement of a JPanel element without adding to the end of the panel?
在顶部网址36003787中是id并且更换了一个jpanel-element-without-to-the-the-the-panel是detalis页面的 Headers . 现在我不打算创建这个网址 . 我有一个关于generete网址的问题 . 但是如果你将堆栈网址更改为Replacement of a JPanel element without adding to the end of the panel? *或 . 要么 !等等...堆栈找到这个网址,然后刷新页面并删除无效字符 . (返回真实网址) . 但我的网址是http://localhost:11148/Content/GetContent/347/Samsung-apple,它是正确的工作 . 但我手动将浏览器地址栏网址更改为http://localhost:11148/Content/GetContent/347/Samsung-apple . 或&& etc页面刷新,未在内容控制器中找到GetContent操作 . plase view stack url并改变这一点 . 我的项目需要这个secanario .
和我的路由配置代码public static void RegisterRoutes(RouteCollection routes){routes.IgnoreRoute(“ .axd / {* pathInfo}”);
routes.MapRoute(
name: "NewsTitleRoute",
url: "Content/GetContent/ContentId/{title}",
defaults: new
{
controller = "Content",
action = "GetContent",
id = UrlParameter.Optional,
title = UrlParameter.Optional
});
routes.MapRoute(
name: "Default",
url: "{controller}/{action}/{id}",
defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional }
);
}
和控制器public ActionResult GetContent(int ContentId,string title)请帮帮我 .