hide the port in my URL

0

Well, I am writing to you because I have a problem that I can not solve and in good time it happens that I have a page with a www.mipagina.com.pe:8080 but it happens that I do not want to leave port 8080 (or any port) and only go to www.mipagina.com.pe. Now I have been making configurations in the apache but I still have an error, I have been applying virtualhost but I have no positive results. I hope you can help me. Where I got the information from was this page link I hope you can help me.

    
asked by Hector Salazar Mendoza 16.10.2017 в 20:20
source

3 answers

1

Good afternoon,

You can not hide the port of the URL if the one used is not the default one. It is not a matter of your specific URL (I say this because you do not waste time with friendly urls), but you have to tell the browser to go to port 8080 instead of port 80. When not using the default port, it is mandatory to notify the port to use. It's how an http connection works.

If what you have is a problem with Apache itself, you should share the configuration you have to understand why you can not raise Apache in the default port (probably in use or misconfigured).

Greetings,

    
answered by 17.10.2017 в 15:55
0

Try this,

is called friendly url.

integrate a .htaccess in your file root there set the .htacces

    Options +FollowSymlinks
RewriteEngine on
RewriteBase /

these lines of code are for the configuration that you will write in said file after the configuration try to do this

RewriteRule ^loquequieras/$ 8080

This snippet of code hopes to rewrite the url you want, I hope it works for you

    
answered by 16.10.2017 в 20:28
0

Just changing the virtual host is not enough. You need Apache to "listen" on port 80 (Listen 80 | Port 80) for which you will need permission in the operating system. The configuration also changes if you are using Windows or Linux. Ports less than 1024 need to be started with some kind of elevated permission (root on Linux or administrator on Windows). I hope this helps you better understand the solution.

    
answered by 17.10.2017 в 16:07