We all know how hip it is to make our Ajax calls using address routing and HTTP-Get with parameters in the URL because the client side can cache those calls and thus server load is reduced, but where do you guys think the line is between "a neat way to address resources" and "disclosure vulnerability"? I'll give some examples-
Let's say...
Hello!
If I have a website at myFirstDomain.com/dir/, is it possible to get mySecondDomain.com to point to myFirstDomain.com/dir/ so that when users browse at the directed site, they only see mySecondDomain.com/potentialSubDirFromMyFirstDomain/ or how does it work?
...
I am trying to figure out how to successfully use the same controller name in the URL, but route different controllers. Dependant on the existence of a subdomain.
Example.
http://www.mysite.com/pages/1
Routes to the SitePages Controller
http://anyothersubdomain.mysite.com/pages/1
Routes to the UserPages Controller
Up until now, I ha...
I am getting this error only SOMETIMES (apparently randomly, though I know there's really no such thing in computers).
I'm working on an MVC (release 1) site in VS 2008. The machine is running Windows 7 with IIS 7, but this instance is running under the Webserver built into VS (Cassini?). When I do an F5 to start running it, I will some...
Hi,
I need generate action links outside controllers.
I can use Html.Action in Views, Url.Action in Controllers. That's fine but...
I have my own class where I want generate HTML code for site menu, which is used in site.master. But how can I generate action links in my own class? Possible solution is to generate this HTML code in Bas...
Due to factors outside my control, I need to handle urls like this:
http://www.bob.com/dosomething.asp?val=42
I would like to route them to a specific controller/action with the val already parsed and bound (i.e. an argument to the action).
Ideally my action would look like this:
ActionResult BackwardCompatibleAction(int val)
I f...
What is the common convention for supporting multiple representation (e.g. html, json, xml) for resources (e.g. blog, user) in django?
First, I don't know how I should format my urls. For example, what your take on using either of these urls to request xml format
/<resource>.<format>, e.g. /blogs/123.xml
/<format>/<resource>, e.g. /x...
I have an images table with a nsfw flag.
What's the best way to add nsfw and sfw to the URL?
For example,
if I have an image with an id=1 and nsfw flag is true, I want the URL to be /images/nsfw/1
if I have an image with an id=2 and nsfw flag is false, I want the URL to be /images/sfw/2
...
I have converted my asp.net mvc project to asp.net mvc website.
Everything works find under IIS but under Cassini it doesn't resolve the URLs, even tough it does it when its an MVC project !!
What could be wrong ?
...
I have a route in my code that looks like this:
map.app 'applications/:title_header', :controller => 'apps', :action => 'show'
I also changed my show method in the controller to be like this:
@app = App.find_by_title_header(params[:title_header])
If I type in applications/title things work fine. If I type in applications/1 (valid I...
Hi
I am trying to implement ASP.NET URL routing using the System.Web.Routing. And this seems to work fine on my localhost however when I go live I am getting an IIS 7's 404 error (File not found). FYI the hosting uses Windows Server 2008 IIS7.
I think this is making some difference in handling the routing mechanism. But I am not abl...
Hi - I'm trying to redirect a user to a url containing his username (like http://domain/username/), and trying to figure out how to do this. I'm using django.contrib.auth for my user management, so I've tried using LOGIN_REDIRECT_URL in the settings:
LOGIN_REDIRECT_URL = '/%s/' % request.user.username # <--- fail..
but it only seems t...
I'm writing a simple news site. I want that the URL will be something like this:
http://domain.com/killing-puts-focus-on-crimes-against-latinos
...instead of the basic Controller-View-ID structure. I do not want something like:
http://domain.com/news/killing-puts-focus-on-crimes-against-latinos
How can I do this?
Thanks.
...
I'm trying to create a catch-all route to track when an affiliate string is in the URL. An affilite code is marked by an x followed by an int, and will only appear at the end of a URL (but before the query string).
The idea is that I will extract the affiliate ID, do some logging, then do a 301 to the same request without the affiliate ...
Just struggling with a simple issue with ASP.NET MVC. I have a list of views, each view associated with an Index.aspx view being associated by default with /MyView.
Yet, for some reason I have 1 view named /Mappings that does not work (404 resource is not found) whereas the explicit path /Mappings/Index works.
I have the default route...
I am kind of new to ASP.NET MVC, so need your help getting me through a problem:
In my application the LogOn will be done using the Role of the user. I have my custom database schema (like User, Role, UserInRole etc.) and I am using my custom MembershipProvider and RoleProvider to achieve Logon.
BTW I am using the MVC default Account ...
How do I remember a url in php to serve it to a user after authentication. The idea is the user will request the url but while unauthenticated. In this case, I forward him to the login page, but what's the best practice to save that url so I can serve it to him once authenticated. I thought about saving it in session variables, but not s...
I have a file with .php extention www.example.com/thefile.php?name=123 that I want to direct the user to if the user visits any of the following aliases:
www.example.com/alias?name=123
www.example.com/unreal?name=123
www.example.com/fake?name=123
Is there a way I can get this done without using a framework that already uses this stru...
I'm new to CI and URI routing in general.
I created a new app. Set the default controller to Main. In Main, I have an index method, a popular method and a recent method.
When I load my app, the url shows up as http://localhost/myapp... this obviously loads up the index method in the Main controller... that's fine.
Now how do I route m...
Is there any way to get truly restful routing working in MVC, just like the rails dudes have? I 'm talking about nested urls like /bands/metallica/albums/killemall/track/4
The only library that I found to be useful is Steve Hodgkiss' Restful routing. It seems though a bit risky to base my whole project's routing on this guy's pet-projec...