Pointing domain name to server ip running XAMPP and wordpress

I installed XAMPP on my windows server and also installed WordPress XAMPP module. I also bought a domain to point it to my server ip. Thing is , I want that when people enter mydomain.com , mydomain.com shows in the address bar and that it keeps showing while browsing.

First I tried to point the domain to my ip , and when I go to mydomain.com it shows mydomain.com/xampp

Read More

Then I tried to changing:DocumentRoot "C:xampphtdocs"
<Directory "C:xampphtdocs">

in httpd file in C:xamppapacheconf

to

DocumentRoot "C:xamppappswordpresshtdocs"
<Directory "C:xamppappswordpresshtdocs">

But this time when I enter mydomain.com it redirects to myipaddress.com/wordpress

All I want is:
1)When someone enters mydomain.com , he will see my wordpress home page.
2)Whenever a user is browsing mydomain.com , he will always see mydomain instead of myipaddress.

Any help would be appreciated.
Regards!

Related posts

Leave a Reply

1 comment

  1. Type this at the bottom of your httpd file:

    Alias /wordpress "C:/xampp/htdocs/wordpress/"
    <Directory "C:/xampp/htdocs/wordpress/">
    AllowOverride All
    Order allow,deny
    Allow from all
    </Directory>
    

    Please take note that the directory that I stated above is a sample of a default directory. I am having a hard time trying to figure out your directory but the above example should make sense. After typing the codes on your httpd file, go to the directory of xamp/apache/conf/extra/ and openup the httpd-vhosts file. Type this at the bottom of the httpd-vhosts file:

    NameVirtualHost *:80
    
    <VirtualHost *:80>
    ServerName www.yourdomain.com
    ServerAlias yourdomain.com
    ServerAdmin email@yourdomain.com
    DocumentRoot "C:xampphtdocswordpress"
    </VirtualHost>
    

    Double check your host file if you already entered this line:

    127.0.0.1     yourdomain.com
    

    Restart your Apache webserver. Hope this helps!