I am using http-server with ssl certificate in order to test facebook instant games. However, while server is running localhost
makes my browser download index.html
file instead of actually serving it in a browser. The problem occures in chrome, but microsoft edge seems to be fine.
Use this URL http://127.0.0.1:8080/
instead of localhost:8080
I found out this problem only occurs in Chrome, edge seemed to work fine, so I decided to clear browsing data in the chrome settings and tried again and surprisingly it doesn't download index.html
from localhost:8080
anymore! This method solved my issue.
In addition to Mahdi's answer, using firefox worked for me just fine.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.