-1

I am trying to make my localhost WordPress website live. I have purchased domain names from Hostgator.com but I don't want the hosting. I want my local server which is XAMPP, to host my WordPress website and I want my test domain, which is ,for example, test.example.com. So, what exactly I need to do to point to my XAMPP server site? For example, I have my WordPress site on localhost/wordpress,

Looking forward to the great responses.

Fahad Tariq
  • 23
  • 1
  • 7
  • 1
    It's usually a pretty bad idea to try to host your own public web server. XAMPP is made for development. – Devon Bessemer Jul 14 '18 at 18:19
  • Thank you for your response. I am just using it for test purposes. I am also using tomcat server. Please guide me through the process. – Fahad Tariq Jul 14 '18 at 18:31
  • Possibly helpful (just replace godaddy with hostgator): [Pointing DNS name to IP address on local machine](https://stackoverflow.com/questions/4940395/pointing-dns-name-to-ip-address-on-local-machine) – HPierce Jul 14 '18 at 18:42
  • @HPierce I am already using Hostgator. – Fahad Tariq Jul 14 '18 at 18:52
  • @HPierce Please take me through the process. How to do it using Hostgator? – Fahad Tariq Jul 14 '18 at 18:55
  • Please read https://stackoverflow.com/help/how-to-ask. Unfortunately, SO is not designed to provide tutorials or write code. However there *are* many services and websites online that do. You'll need to do a google search for a tutorial. If you later have a problem with a *specific line of code* SO may be able to help. – SherylHohman Jul 14 '18 at 19:24

1 Answers1

1

What you're trying to do is exposing your localhost to the web. This is not a good idea due to multiple security reasons but if you really want to do it, you can use ngrok or pagekite. The free versions would give you a randomly assigned sub-domain of ngrok/pagekite, whichever service you are using.

Then, you can setup a CName record to map your subdomain to the pagekite/ngrok domain in your domain provider's DNS Manager.

Yousuf Khan
  • 334
  • 3
  • 12
  • Thank you for your response. I have used ngrok method and it was successfully implemented. But I don't want the different domain name each time I run the ngrok command. That's why I am trying to use my test domain name which will be static for the time of course. Please tell me the process how to do it. I is just for testing purposes. Looking forward. – Fahad Tariq Jul 14 '18 at 19:00
  • Please check https://www.dynu.com DDNS provider. You can signup to get a free subdomain over there, something like xxx.dynu.com. After that, install their Windows app which will automatically update your IP on dynu's server allowing you to access your pc with their domain (xxx.dynu.com). If you want a custom domain, you can create a CName record which points to your dynu.com subdomain. – Yousuf Khan Jul 16 '18 at 12:50