routing

Id with / causes problems with routing

I'm playing around with Raven DB and MVC 2. By default, the id in Raven will be e.g. "suggestions/1234" for an entity called Suggestion. This causes problems with routing when I write like this: <%: Url.Action("Delete", "Suggestion", new { id = suggestion.Id }) %> The url will be /Suggestion/Delete/suggestions/14337 which won't work....

How to define route & controller structure for 2 controllers?

I want to create an MVC app to generate factsheets, but I'm not sure how to structure the routing and controllers. It consists of an index page, which acts as a template for the layout of a number of independent panels, each of which contains different types of data. I want to have a the route template like the following: /Factsheets/...

Rails landing pages

I've decided to put a landing page on my website goldhat.org. I want users to be able to go directly to this page if they are logged in and be directed to a landing page if they aren't logged in. The landing page is currently sitting here. If one clicks on the "browse website" link at the top, it will go to what is currently the home pag...

Routing to an anchor on another page

I am using Web Forms Routing in ASP.NET 4 and I am trying to route to a specific location on a page. On that page I have an element like <div id="3"> and I'd like to jump to this anchor from another page. For this purpose I have defined a Route in global.asax: RouteTable.Routes.MapPageRoute("MyRoute", "Path/SubPath/{PageAnchor}", "~...

Routing with sub domains

I have an MVC website which has 3 main components Member area which has the path /Member/{controller}/{action}/{id} Individual pages which will respond to any subdomain, e.g. user1.example.com/{controller}/{action}/{id}, user2.example.com/{controller}/{action}/{id} Main website which will respond to any url under www.example.com/{contr...

symfony routing question?

Hi all, I think this is a routing question. For SEO reasons, I need urls like the following: www.domain.com/acme-pump.html www.domain.com/beta-pump.html www.domain.com/boyden-pump.html ... and also: www.domain.com/acme-pumps.html www.domain.com/beta-pumps.html www.domain.com/boyden-pumps.html (Note the "s" on pumps). There are abo...

Routing IN RUBY on RAILS

So for example, if I give like this map.root :controller => "pages", :action => 'show', :slug => "**homepage**" map.connect '*slug', :controller => 'pages', :action => 'show' what will happen? ...

Rails - Failing Routes in deployment

I have an app that has the following in the routes file: namespace "admin" do # ADMINISTRATIVE ROUTES ONLY root :to => 'home#index' resources :comments do member do get :approve get :reject end end resources :users do member do get :block get :unblock ...

ASP.NET 4 - URL Routing not working

Hi all, I have a asp.net 3.5 web site.I changed framework version from 3.5 to 4 for URL routing but routing doesn't work.I'm getting http 404 error.My codes are like this (In Global.asax) void Application_Start(object sender, EventArgs e) { RouteTable.Routes.Add("product", new Route("product/{kind}", new PageRouteHandler("~/produ...

blank pages/routing issue with asp.net mvc 2 iis7 integrated windows7 vs2010

I've been searching though a number of posts and still can't seem to get a straight answer or at least one that works for me. From what I can tell is is some kind of routing issue. In fact I'm pretty certain of it. When I visit any of my web pages it comes back as a blank page with no data. Also I am using VS2010 asp.net mvc2 on window7...

ASP.NET routing: http://mywebapp/##ID## to http://mywebapp/Custs/Customer.aspx?id=##ID##

I'd like to redirect the URL hxxp://mywebapp/##ID## to hxxp://mywebapp/Custs/Customer.aspx?id=##ID##. What is the easiest way using ASP.NET 3.5 routing to do it? Thanks. ...

ASP.NET MVC MOBILE Controller Route to Subdomain

I currently have an ASP.NET MVC application that exists. I want to add a small mobile friendly section to the site. I want to keep it extremely simple and integrate http://mdbf.codeplex.com/ into my project. Then on Home/Index check if the are mobile, then forward them on to the Mobile Controller (http://mysite.com/mobile/index). H...

Route always goes to the first maproute

I'm trying to create URIs that look a little something like this: http://hostname/mobile/en/controller/action for mobiles OR http://hostnamem/en/controller/action for desktop (non mobiles) My Route table currently looks like this (Global.asax.cs) ` routes.IgnoreRoute("{resource}.axd/{*pathInfo}"); routes.MapRoute( ...

Best method for URI Routing this in CodeIgniter?

Hi folks! So, here's an example on Forrst, a CodeIgniter website: http://forrst.com/posts/PHP_Nano_Framework_WIP_Just_throwing_some_ideas_o-mU8 Look at that nice URL. You've got the root site, then posts, then the post title and a short extract. This is pretty cool for user experience. However, my CodeIgniter site's URLs just plain s...

.htaccess routing

I want to create my own routing system with .htaccess, but I have some problems. My folder structure is: .htaccess |- system |- controller |- theme | -- domain.dk | --- gfx | --- style | --- html How can I make my .htaccess right? Using routing too? My .htaccess looks like this: RewriteEngine On php_value zlib.out...

Directing a request in IIS

I have a set of web services written in classic asp. I want to convert them to asp.net, but this will be a long process. I want to convert a couple functions at a time, and use some sort of routing mechanism to select which version the requests go to (classic asp, or asp.net). Changing the url used to access the web service and functio...

WebForm routing and cyrillic

Hello I'm using .net 4 webform routing i have a rout like this routes.MapPageRoute("JobPreview", "jobs/{jobId}/{pg}/{Position}", "~/default.aspx") When the position is in Latin letters there is no problem, the resulted Url is like this "http://mydomain.com/jobs/1/1/programer" But when the position is in Cyrillic letters, it's not d...

ASP.NET MVC2: Can't find controller

I have an MVC 2.0 web site that is using Areas. When I go to the default page (localhost/mywebsite/default.aspx), it correctly routes to the correct action in the correct controller and renders the default view correctly. But on the page I have several Html.ActionLinks, and these do not seem to be able to find the Controller. When I c...

C++ windows32 winsock UDP routing?

In C++ using Windows32 using windows socket library using UDP is there a way to give a client routing information to another client to establish a connection between clients without having to route through the server Clarification: server - waits for computers and gives routing info - a detached server client - sends a ack request and ...

User-defined routing

Hi everyone! I have three relevant models: Companies, Projects, and Links, and I am trying to create a system where we generate routes according to the Links they create, for example: www.site.com/the_company's_specific_path/one_of_company's_links One company has_many :projects, one project has_many :links. Summary of the structure:...