running site on local host instead of the specific folder

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

running site on local host instead of the specific folder

Postby awaisbilal » 02. May 2023 06:43

Hi Dear XAMPP community,
I am new to the web servers world, I have a local WordPress website on my windows 10 pc. It loads in the browser when I type http://localhost/mysite in the address bar. Instead of the folder address I want to load my website at http://localhost in address bar of the browser, is there any solution for this purpose, please advise. Righton XAMPP keeps on showing its dashboard on the localhost address, can we show this dashboard on other address?
awaisbilal
 
Posts: 1
Joined: 02. May 2023 06:34
XAMPP version: 8.2.4
Operating System: windows 10

Re: running site on local host instead of the specific folde

Postby Altrea » 02. May 2023 08:51

Hi,

you could define a virtual host pointing DocumentRoot to your /htdocs/mysite/ folder.
Keep in mind that wordpress generates urls based on the base url, so you need to adjust this in the wordpress configs too or install wordpress freshly from the new url.
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: 11933
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 11 Pro x64

Re: running site on local host instead of the specific folde

Postby Nobbie » 02. May 2023 11:30

You can also simply change the value of DocumentRoot to your specific folder, as well as the Directory Block for the DocumentRoot. Do not install WordPress before you do this change, but after you restarted Apache. Keep in mind that this means also that the dashboard does not appear any longer.
Nobbie
 
Posts: 13176
Joined: 09. March 2008 13:04


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 245 guests