redirect

How to get wxCurl to automatically follow redirects?

I have a project that uses wxCurl to retrieve a file over HTTP. However, if the server sends a 301 or 302, all I get back is an empty string. I heard there was a way to get cURL to follow the location: headers sent by the server. How is this done? Also, how do you set the User-agent header in wxCurl? ...

The wrong url is showing up for my site in google searches

Hey folks. I have a client who's old website was called toastkid.com. I set up a new site, alekskrotoski.com, and had the old www.toastkid.com domain point to the new site. I have a 301 redirect working, so when you go to www.toastkid.com the address bar updates to alekskrotoski.com. So, the 301 is definitely working fine. However, ...

Java redirect exception to file

I want to redirect FULL output of my program to a file (including Exceptions) in bash. I can't change content of class. I run it like that: java -Djava.security.manager -Djava.security.policy=JLPPolicy -Xmx16M -Xms2M -cp /var/tomcat/bin/ Main > File Exceptions are send to console, which is bad for me. Can I do something with it? ...

Which redirection is better - web.config or global.asax

I need to redirect some of the older pages in my application to new pages. I thought urlMapping in web.config is the efficient way to achieve this. But there is also another way to redirect using global.asax. Which one is the efficient way for this. At what point in request execution does this asax and config file comes into the picture?...

Asp.net mvc 301 redirect from www.domain.com to domain.com

We have a website at domain.com, which is also accessible via a CNAME entry for www.domain.com that points back to domain.com. We'd like all visitors to www.domain.com to be redirected to domain.com using a 301 redirect. What's the best way to implement this in asp.net mvc? In global.asax? ...

php cURL , POST and redirect client , proxy/bridge

I'm trying to make a php cURL script that should act like a bridge/proxy (like "man in the middle" but nothing hacking ), make a POST to a url (example.com) and redirect the client to that link after it gets the response . I'm not sure if it's possible so please advise. Basically the client will pass 2 values through our site (e.g exam...

Forcing users to access the site with www. and https

I am trying to write an .htaccess rule that appends www. to the domain and s to http if required but I can't seem to find a rule or set of rules that works for each case. The cases are... \https://www.site.com - should just work \http://www.site.com - should go to \https://www.site.com \http://site.com - should go to \https://www.si...

ASP.NET Forms Authentication without Redirect

I am using ASP.Net's forms authentication, but do not want the default behavior of redirecting to a login page when a restricted area is accessed. Instead I would like to invoke a javascript JQuery dialog for the login on the current page, preventing the content behind from loading. My only issue is that by default the forms authenticat...

How can I launch the eMail client, and then do a page redirect with Javascript?

I'm required to make a website function exactly the same on other browsers as it does in IE6. Part of the current code looks similar to this: <script> function myFunc(){ location.href="mailto:[email protected]&body=Hello!"; location.href="newPage.html"; } </script> <body onload="myFunc();"> </body> in IE, this causes the mail client to ...

How to redirect a server call from a swf file to e rails environment

Hi Everybody, I have a problem with my SWF file integration. I am now able to load the SWF file and hand xml data over, in the SWF file I can change the xml data, and I can send them back to the Server. But my problem is, that the resulting redirection doesn't have any effect! I guess that the resulting page gets told to the SWF file an...

redirect a user accoding to his browser

Hello, I have a customer that requires a flash intro in the index page, what I would like to check if the user accesses from a mobile phone, and if so to redirect the user to the main page without the intro. All help is welcome, Adnan ...

Redirect to webapp default document when another page is specified?

IIS6, ASP.NET 2.0, No Forms Authentication I'm calling Response.Redirect("~/foo.aspx"), but the default document ("Default.aspx") for my site is appearing. To make matters worse, it only happens intermittently. Sometimes the redirect displays the right page. I've checked session state, and I don't see any values in the web.config (th...

Redirection loop problem at facebook iframe application

I do IFrame application for facebook. Problem is: any link inside it causes redirect loop Link is: http://mydomain/mypage?fb_sig=[what I got from $_GET['fb_sig']] (to test I link to the same page as my loaded canvas is loaded from) when I click on it, my server returns: <script type="text/javascript"> top.location.href = "http://www...

Django redirecting to external url that contains parameters (for development)

When developing with Django without a web server (serving directly from Django) I have a problem with external urls that lack the domain part and have parameters. Let's say I'm using a javascript library that does an ajax call to "/prefix/foo/bar?q=1" (the url is not something I can change). It is not a problem for the production serve...

C# + telnet process w/ redirected standard streams quits immediately

I'm trying to do a 'scripted telnet' project in C# (something vaguely resembling the Tcl Expect package) for which I need to start a telnet process and redirect (and process) its stdin/stdout streams. The problem is, the spawned telnet process quits immediately after starting (it does start, however). If I try to do the same with -say-...

C++ redirect outgoing connections

Is there any way in C++ on windows to monitor a program and redirect any outgoing requests it makes on a specific port? I have a simple C++ http proxy and want it to be able to automatically redirect all browser requests on port 80 through itself. ...

How do you do a 301 permanant redirect route in ASP.Net MVC

How do you do a HTTP 301 permanant redirect route in ASP.NET MVC? ...

Redirect user back to the original page

I have an edit page which is used from different sources. After editing I would like to redirect user to original page. Earlier I used ID (given as a parameter) and Action (hard-coded) to redirect user to certain page, but problems occurs when many different pages can access the same edit page. Any suggestions how to handle this situati...

Redirect to default action in Struts 2

I have an action with an empty string for name defined in the root namespace, and I want to redirect to that action from another action if a certain result is found, but it doesn't seem to work. Here's the default action <action name="" class="com.example.actions.HomeAction"> <result name="success" type="freemarker">freemarker/ho...

ASP HttpWebRequest and Redirect

OK, I have a client doing a POST to a server with some data. The server receives the post, and answers with a redirect. The problem is that the client does not redirects. Also, I've tried to check the StatusCode of the response the client gets, and it is always the same "OK". Instead of the redirect code. What am I missing? In the clien...