routing

ASP.NET MVC Routing with a controller named "PropertiesController"

I'm having a tricky issue (bear with me as I'm new to MVC) with trying to use a controller (and a route subsequently) with the name PropertiesController. I believe this is because there is a directory (which I can't really remove) called "Properties" in my solution. Is there a way round this? The route setup is just one simple route: ...

Windows 2003 routing/firewall/dhcp/... problem ?

I have a problem with the availability of server from the outside (from local network all works perfect). A key problem is the http, where the requests are carried out but only if the response is less than a certain number of KB. - if accessed via browser from the outside, only the request less than or equal to 4KB are responsed - if acc...

CategoryRouteHandler() reference

Here is the example I see everywhere for routing without mvc. public static void RegisterRoutes(RouteCollection routes) { routes.Add(new System.Web.Routing.Route ( "Category/{action}/{categoryName}" , new CategoryRouteHandler() )); } Problem: CategoryRouteHandler assemble can n...

Keep :format in Ruby on Rails URL helpers

Suppose I use a custom :format to implement a gadget-oriented version of my site. The general idea is that I can reuse controllers with custom, gadget-oriented views. Is there any way to make all URL helpers called from that particular format keep the same format, without hardcoding it into all helpers? I'd like to keep controllers un...

ASP.NET Routing Question

Why is this: http://MySite.com/Project/24/Search/32/Edit/49 preferred over this? http://MySite.com/Project/24?Search=32&Edit=49 ...

Django: serving ADMIN media files

Hi all, I've been successfully serving media files for the normal MEDIA files, but when I tried serving admin media files, I failed. please kindly help me locating the problem, as I've tried to troubleshoot the problem for several hours already with no luck (been googling too and read the django doc about serving static files as well). ...

Generating urls form MVC Routes in a Management layer...

So... I have a business object/manager which is going to generate emails. These emails will contain links to various content on the website... and therefore needs to understand about MVC routing.. or at least how to generate URLs for the website... However my business object will not have access to a RequestContext etc and the email ge...

Routing depending on optional action value in url

Being rather new to ASP.MVC I'm looking for a solution to the following routing problem. I want these Url's to lead to the shown pages: /Member/123/A+Strange+Username -> page with members details /Member/123 -> as above /Member/Connections/123 -> page with list of members connections /Member/Connections/123/A+Strange+Username -> as abo...

Can someone please tell me what is wrong with this code...?

Hi All, I have a section of code in a controller that replaces existing HTML with an IMG tag. The code is as follows: render :update do |page| page.replace_html "chart-div", "<img src=\"#{chart.chart_file}\"/>" #chart.chart_file is a path end For whatever reason, I keep receiving the following error: ActionController::Routi...

Asp.net MVC AcceptVerbs

Hi folks, Here the RedirectToAction() doesn't call the ActionResult Index. Do I need to register a route for this? [ActionName("onchange")] [AcceptVerbs(HttpVerbs.Post)] public ActionResult OnChange(int i) { m_NumberOfVisibleItems = i; return RedirectToAction("Index"); } ...

Does map.namespace falls back in case if there is no matching controller?

Today I am observing a peculiar behavior in my rails app. I have defined the following route in routes.rb map.namespace :admin do |admin| admin.resources :users end and when I use rake:routes, I see the following routes as expected: admin_users GET /admin/users {:action => 'index, :controller => 'admin/users'} .... .... which are...

Validate no routing overlap when creating new resources in Ruby on Rails

I've got a RESTful setup for the routes in a Rails app using text permalinks as the ID for resources. In addition, there are a few special named routes as well which overlap with the named resource e.g.: # bunch of special URLs for one off views to be exposed, not RESTful map.connect '/products/specials', :controller => 'products', :ac...

ASP.net MVC Routing Throws Exceptions as Normal Behavour?

I was debugging my current project (ASP.net MVC 1.0 project) and stumbled upon slightly disturbing behavour. It seems that when the router is hunting for a referenced partial view aka <%Html.RenderPartial("AccountListControl", ViewData["AccountList"]); %> It cycles through it's default locations until it finds the correct spot. So i...

Which open source OSPF-Routing implementations are available?

Hi there I am searching for an open source OSPF-Routing implementation. Does anyone know a few implementations which I could compare? OSPF is Open Shortest Path First for those who are wondering. (Link: http://en.wikipedia.org/wiki/Open_Shortest_Path_First) ...

Any way to declare routing strategy for an WPF element?

Suppose we have a WPF element, for instance StackPanel with Buttons, Textboxes etc. inside. Is there any way to say directly in XAML that I want a tunneling strategy? <StackPanel RoutinStrategy="Tunneling" ... ...

ASP.NET MVC Custom Controller directory

Hello, I'm making an ASP.NET MVC website and I have a certain group of forms that are related (let's called them Foo). My first attempt to organized them was to have this structure: Controllers/FooController.cs ...and to have routes like this: Foo/{type}/{action}/{id} Unfortunately, since there are about 8 Foo sub-types, the FooC...

Cucumber default_url_options[:host] everytime "www.example.com" even if specified in environtemnts/test.rb

Hello, I specified the default_url_options in my environments/test.rb with config.action_mailer.default_url_options = { :host => "www.xyu.at" } This is quite ok and in my cucumber story, where i test registration of users, the user-activation link gets generated right invitation_activation_url(1) => "www.xyu.at/signup/1231hj23jh23" ...

Simplest way to define a route that returns a 404.

Hi, I've got a requirement to specify a named route in a Ruby on Rails project that returns the public/404.html page along with the 404 server response code. Leaving it blank is not an option, please don't question why, it just is :) It absolutely must be a named route, or a map.connect entry would do. Something like this would be g...

Find HTML verb for actions in rails

Is there a way to look up the HTML for a given controller action? For example, I would like to be able to associate GET with index and PUT with update. I want to be able to do this dynamically based on the routes. I can get the action methods for each controller using Controller.action_methods, but this returns a set of strings of acti...

Adding Redundant Information to a MVC Route

As you come to this question you'll notice the title of the question is in the address bar and the link you clicked on to get here. I am not sure the exact terminology so found it difficult to search for but how can I do something similar? That is, How can I add data to the address bar which is purely for show/search engines. Thanks ...