[英]Using Socket.io, AngularJS and Express, client listening on different port than which the server is running at
[英]Socket server on different port and Client on different port
我正在開發一個私人聊天應用程序。 我的服務器端代碼(NodeJs + Express + Socket.io)在端口 7000 上運行。我的客戶端代碼(AngularJs)在端口 8000 上運行。
當我嘗試將套接字客戶端(在端口 8000 中運行)連接到套接字服務器(在端口 7000 上運行)時,得到 404,這很明顯。
我有以下與此相關的問題:-
謝謝,維克拉姆
找到了解決辦法。
而不是在 HTML 中包含 socket.io 為:-
您也可以將其包含為
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.