You need to add setup a wildcard subdomain from hostgator subdomain setup.
Go to subdomains and add one with just an asterisk(*).
To check if the wildcard setup is really working:If your domain is mydomain.com, then visit any random subdomain which is not assigned yet. For example: notAssigned.mydomain.com
If this subdomain redirects to your main domain, then your wildcard setup is ok. Otherwise, you have to manually edit the A record for the asterisk(*).
To do that go: Simple DNS Zone Editor
Add an A record to: *
You will find the address below of that page. The IP address or record (ex: 126.96.36.199) which is assigned to your main domain.
Add this into wp-config.php to enable multisite.
Login to your WordPress dashboard and go to Tools>>Network (.com/wp-admin/network.php) You will then see the following type of instructions. Just follow the instruction.
I don't know. Your site should be ok now.