如何使用备用自定义端口创建网站链接?

I would want my website subdomain a.site.com to be accessible via alternate port, lets say a.site.com:8866

How can i enable this? a.site.com will be going to the home page of site.com page by default.

It is in a lamp stack. Possible using htaccess? etc?

Thanks.

You can find the settings for those ports in your httpd.conf file (located at apache/conf/httpd.conf), once you opened that up look for listen 80 and change the 80 to your desired port.

note: do not forget to restart your webserver after these changes to update your config.