How to run html file on localhost?

后端 未结 8 674
再見小時候
再見小時候 2020-12-04 08:41

I have a html file and i run it on localhost. But, this file includes mirror using webcam. Example, how can i run this html file on localhost? Webcam starting on this exampl

相关标签:
8条回答
  • 2020-12-04 09:39

    You can run your file in http-server.

    1> Have Node.js installed in your system.

    2> In CMD, run the command npm install http-server -g

    3> Navigate to the specific path of your file folder in CMD and run the command http-server

    4> Go to your browser and type localhost:8080. Your Application should run there.

    Thanks:)

    0 讨论(0)
  • 2020-12-04 09:39

    You can install Xampp and run apache serve and place your file to www folder and access your file at localhost/{file name} or simply at localhost if your file is named index.html

    0 讨论(0)
提交回复
热议问题