win7+xampp1.8.1 localhost/monsite imposs remove ports [Solve

Problems with the Windows version of XAMPP, questions, comments, and anything related.

win7+xampp1.8.1 localhost/monsite imposs remove ports [Solve

Postby greenfairy » 01. March 2013 12:39

with windows7 and xampp1.8.1 http://localhost:8484/mysite works ! (php/sql/mydamin .....everything works!)
I change the ports ... not only the Apache server, everything works fine,
but impossible to operate: http://localhost/mysite removing ports: 8484 ...

Is that quelq'un has an idea?
(Sorry I'm french my english is bad)

I already tried:
C:\Windows\System32\drivers\etc\hosts

127.0.0.1 localhost
127.0.0.1:8484 localhost

(I tried with my local private ip)

apache ... \conf\httpd.conf (properly configured Listen 8484)
... apache conf\extra\httpd-vhosts.conf (properly configured )

<VirtualHost *:8484>
DocumentRoot "E :/..../xampp/htdocs/"
ServerName localhost
ServerAlias ​​localhost
<Directory "E :/..../xampp/htdocs/">
Options Indexes FollowSymLinks Includes ExecCGI
Order allow, deny
Allow from all
DirectoryIndex index.html index.php
</ Directory>
</ VirtualHost>

to a file. htaccess (E :/..../xampp/htdocs)
and finally to a file. htaccess (E :/..../xampp/htdocs/mysite)

RewriteEngine on
RewriteCond% {SERVER_PORT} ^ $ 8484
RewriteRule ^ (. *) Http://% {SERVER_NAME}% {REQUEST_URI}

when I asked the url http://localhost:8484/mysite url is rewritten in http://localhost/mysite

the url is redirected correctly but nothing is displayed (there is an index.html page in the directory)

Is that quelq'un has an idea?
(Sorry I'm french my english is bad)
http://www.creativ-e-motion.fr/creation-site-internet
greenfairy
 
Posts: 6
Joined: 07. November 2012 10:25
XAMPP Version: 5.6.3
Operating System: windows 7

Re: win7+xampp1.8.1 localhost/monsite impossible to remove p

Postby Altrea » 01. March 2013 13:16

Hi greenfairy,

greenfairy wrote:I change the ports ... not only the Apache server, everything works fine,
but impossible to operate: http://localhost/mysite removing ports: 8484 ...

Is that quelq'un has an idea?

Simple answer: you can't. If you don't specify a port in the url, the port will be specified by the protocol. http:// has the default port 80.
If you want to get rid of the port in your http url, you have to use port 80.

best wishes,
Altrea
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 6829
Joined: 17. August 2009 13:05
XAMPP Version: 5.5.19
Operating System: Windows 10 Pro x64

Re: win7+xampp1.8.1 localhost/monsite impossible to remove p

Postby greenfairy » 04. March 2013 08:41

@ Altrea, thank you for your answer ...

I now set the "main port" apache on 80 and actually
I can access my sites with http://localhost/mysite ...

why make it simple when you can make it complicated? (lol)
http://www.creativ-e-motion.fr/creation-site-internet
greenfairy
 
Posts: 6
Joined: 07. November 2012 10:25
XAMPP Version: 5.6.3
Operating System: windows 7


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 30 guests