Just in case, the full answer does not answer the question. Only some parts do.
If I understand your question, you want to run your website on http://localhost. I just want to clarify that the normal localhost runs on port 80 i.e. http://localhost:80.
So, port 80 and just the localhost aren't different, so please don't get confused. You should not worry about httpd-ssl.conf, you shouldn't have to change it. The configuration is in the main conf: httpd.conf. And, I don't think the link you've given in your question is similar.
Can you access localhost using https://localhost
After all, I think, you want to change your port from 8012 to 80 (http default).
Please follow the following steps to change the port.
1) Click on Config after opening XAMPP
2) Click on Service And Port Settings
3) Change the port to 80 from your current port
If it still has the same error, do this:
Take a backup of httpd.conf before doing the following.
1) Edit your httpd.conf, change the following.
Listen 8012
To:
Listen 80
If still not working, go ahead and add the following at the end:
<VirtualHost *:80>
ServerAdmin your@email.com
DocumentRoot "C:\path\to\website"
</VirtualHost>
Thanks.
Edit:
The only way you could do this is by running your XAMPP server on a different IP like 127.0.0.2
So, try the following:
Edit httpd.conf and say:
<VirtualHost 127.0.0.2:80>
ServerAdmin your@email.com
DocumentRoot "path to htdocs"
</VirtualHost>
Go to the C:\Windows\System32\drivers\etc
Edit hosts file:
For some time, please add something like this.
127.0.0.2 localhostt
Also
You could also change the port of the application that is running on port 80
Open up the CMD
Run the following command:
netstat -aon | findstr "80"<br>
And get the info of something like:
TCP 0.0.0.0:80 0.0.0.0:0 LISTENING 11560<br>
Get the info of the last number i.e is in this post is 11560
Run the following after that
tasklist | findstr "11560"<br>
Replace 11560 to the number that you got running the previous command
And you will know what app is running in the port
My Last Guess:
The new way I found out is by doing this:
Change the listen directive to:
Listen 127.0.0.2:80
Go to the C:\Windows\System32\drivers\etc
Edit hosts file:
Try this:
127.0.0.2 localhost
OR
For some time, please add something like this.
127.0.0.2 localhostt
Hope it works.