Asp.net web routing. Same url pattern without any constraints -
hi every 1 working on asp.net web routing. need same url pattern without constraints.
i need following multiple url pattern.
"countryroute","{country_name}" "~/country.aspx" => www.abc.com/australia/ "pageroute","{page_url}" "~/page.aspx" => www.abc.com/contact_us/ "keywordroute","{keyword_url}" "~/keyword.aspx" => www.abc.com/keywordname/
i can't apply constraints.
you can't have 1 common url 2 different resources (without magic, is). that's suggesting 1 road take 2 different places.
you know en url kind of address of web page, right? consider similar properties in comparison real address of real house; ok have 2 addresses 1 house, if 2 different houses had same address (in same town, county, country etc.) how postman able tell house letter should delivered to?
if wanted to, build own route handling wouldn't change fact @ 1 point or need job of postman , identify unique feature of request or context, points towards 1 resource or other. querystring, session object, whether call made computer china or germany or whatever -- need decide makes sense in case. "both link going different destination page url same", wrote in answer comment, not.
Comments
Post a Comment