Redirect URL on IIS 7.5

Asked

Viewed 1,123 times

4

When publishing to the server (iis 7.5) the application:

Eu tenho isso     => http://meuip:8086
Mas preciso disso => http://meuip:8086/portal

when or if created the iis directory with the name "portal" and converted to application is generated a url error, because in the source are not like this, url example in the source:

em JS:
 var url = "/Portaria/Recado/Listar";
em C#:
 action="~/Gerenciamento/UsuarioExterno/Cadastro/0"

in C# the redirect even works when created in iis a subdirectory, but css and js do not, because in the source the "/portal/" does not exist.

inserir a descrição da imagem aqui

  • It would not be the case to create the /Portal as an application within the site :8086 ???

  • When created the /Portal inside Novoportal and converted into app I have an error in the URL’s, because my css and script do not have the "/portal". Hence the url comes "http://meuip:8086/meucss" and that path does not exist. There is now "/portal"

1 answer

3


1) Confirm that the redirect module is installed:

inserir a descrição da imagem aqui

In the English version the module is called Http Redirection.

2) Open OSI, locate the module HTTP Redirect under the website and directory where you want to create the redirect - in your case /portal:

inserir a descrição da imagem aqui

3) Enter the new URL. Optionally adjust the status code to 308 - browsers will cache the redirect information after the first visit.

inserir a descrição da imagem aqui

  • opa... I will check....

  • option 308 does not exist for me, only (302,301,307), I will try the 301 that is Permanent

  • @Daniellearrudatorres 301 and 308, if I remember correctly, are equivalent for browsers. It will probably work for your case.

  • didn’t work. do you have any idea what it might be?

Browser other questions tagged

You are not signed in. Login or sign up in order to post.