Is it possible to have a url redirect to another page and keep the original url in the title bar? - iis

A marketer in my company has a landing page on our site: www.importantcompany.com/amazingproduct
They have a vanity url that goes to the landing page:
www.amazingproduct.com
I successfully created the iis redirect rule. However, the marketer has comeback and would like to keep the redirect rule, but keep the address in the bar www.amazingproduct.com instead of www.importantcompany.com/amazingproduct
I'm assuming that this is not possible.
The only way to make this work is to create a new site in iis and copy the landing page into the new site and set the new site to go to www.amazingproduct.com
Please let me know if my assumption is correct.
Thanks!

Your assumption is incorrect.
You could write a filter on IIS that looks at the requested URL and notes if "www.amazingproduct.com" is sent in to do a "Server.Transfer" of the request to the subfolder that would be one solution that wouldn't require a new site at all.
URL Rewrite could also be another way to configure a way around this to some degree.

Related

How do I rewrite old URLs without affecting default redirects?

Let me see if I can explain this.
I used to have mydomain.com as my default page. The login page would be mydomain.com/login and every content created would become mydomain.com/topic1, mydomain.com/topic2 etc.
But I have created a subdirectory, so it's now mydomain.com/sub/login and mydomain.com/sub/topic1 etc.
I then set mydomain.com to redirect to mydomain.com/sub/login via my host's panel (Hostinger).
If a user accesses the website from one of the old links, I would like it to change the URL to include the new subdirectory automatically, without affecting the redirect I have created.
How can I do so? Is it possible?
Thanks, folks!

URL and Port redirect on IIS

I'm struggling with an issue in IIS 8.5 which is about redirection and rewriting, but couldn't get a solution yet
we have an application driven Webpage running on IIS, but is not manageable.
This application can attached by browser using
http:// 10.172.100.242:81/appname/object?parameter
which is not really customer friendly. Up to the "?parameter" the URL is steady, parameter is changing.
I would prefer to have this url shown to the customer as
http:// appname.domain.com/parameter (best solution) or
http:// appname.domain.com/object?parameter
The combination of redirect and rewrite is too much for my knowledge
The rules I tried didn't work and now I have the hope to get some help from guys with better knowledge than mine...
Thanks in advance
First create a new website in IIS. Then configure as follows.
Inside the website create a folder called "parameter"
Select the "parameter" folder and set the redirect as show in the picture 2

How to redirect one page to a different URL than the rest of the HTTP redirect IIS8

First off, apologies for not knowing the nomenclature for what I'm looking for, I'm not typically a Windows web admin.
I have a SharePoint website which contains several subsites. We also have several alternate URLs that point to specific pages, and some of those alternate URLs have friendly URLs which also redirect to other specific pages. We're in the process of migrating from a SharePoint 2007 site to this one, and in the process, I'm trying to remove our reliance on our registrar for handling some of this redirection, because it is apparently not a free service.
Currently our registrar does the following redirects:
http://alias1.tld/* redirects to http://subsite1.ca/page1
http://alias1.tld/friendly redirects to http://subsite1.ca/page2
http://alias2.tld/ redirects to http://subsite1.ca/page3
I know I can accomplish the first and second by setting the sites up in IIS, and using the HTTP Redirect function, but I'm not sure how I can do the second one. In Apache this would be easy, but I'm not sure what I'm looking for here.
Is this something that should be handled within SharePoint, and have that take care of redirecting alias1.tld/friendly to the specific page, or is this something I need to setup in IIS? Is this what URL rewrite is for, or is there a different IIS way to do this?
I'm not sure that this is the best way to do it, but I got things working how I wanted them. Here's what I ended up doing:
Create a new subsite on subsite1 to give me the URL subsite1.ca/subsubsite
Create a redirect from alias1.tld to subsite1.ca/subsite
Create 2 pages for the new subsite. One for the default page and one to use to redirect to page2. Both pages are redirects, Default points to Page1, the second points to Page2.
Set the subsite to use Managed Navigation for global and current through Site Settings > Navigation, and created a default term set by selecting the new subsite in the list and then clicking Create Term Set, then clicking OK.
Then created a term store for the one page that needs to be handled differently by going to Site Settings > Term Store Management. Click on the Term Set created in the last step, then select New Term. On the Term-Driven Pages tab, create the friendly URL and then select the target page, which is the redirect page created in step 3, then click Save.

how to use old URls as it is in new drupal site

I am migrating an asp site to drupal.the existing site node URL is as
story.asp?sectioncode=1&storycode=49667&c=1
to use the same urls in drupal site i add the URL in URL aliases.when i click on any article it it showing as
story.asp%3Fsectioncode%3D1%26storycode%3D49667%26c%3D1
in the browser.how to remove %3D,%26,%3F from the URL and when i copy and paste the old url in the browser it is not redirecting me to the actual page giving 404 not found page.could some one please help me how to manage my old URLs as it is in new site.
You're not supposed to type something like story.asp?sectioncode=1&storycode=49667&c=1 as an URL alias.
There's a better way to do that. Try installing redirect module and add a new 301 redirect rule from story.asp?sectioncode=1&storycode=49667&c=1 to your new node's URL node/1.
So, whatever any user / search engine visits story.asp?sectioncode=1&storycode=49667&c=1, they will be redirected to node/1. or whatever the path you have given to the 301 redirect rule.
Hope this Helps... Muhammad.

HTTP Module causing problem with Google Cache

I have a live site ( I can't provide the URL ).
It is on sharepoint 2007. The pages were having a URL, later that was modified.
I wrote a http module and used response.redirect() to navigate user to the correct page.
But since the site was live previously; on searching on google.com, it shows the old URL only. Though the redirection works fine. I need to change the cached URL to new URL.
How can I do that ?
You need to understand the different redirect codes - by itself response.redirect() just redirects a browser (or bot) to another address.
You should have been issuing a 301 redirect then Google and other services (its been roumered that there are a few other games in town) would have eventually removed the old URL and replaced with the new URL and all your 'link juice' would be kept.
If you need to change the URL of a
page as it is shown in search engine
results, we recommended that you use a
server-side 301 redirect. This is the
best way to ensure that users and
search engines are directed to the
correct page. The 301 status code
means that a page has permanently
moved to a new location.
ASP.NET code for this
Response.Status = "301 Moved Permanently"
Response.addheader "Location", "http://www.newdomain.com/newurl/"
Response.end
Try to look here. Not sure, but it can help you.

Resources