我有一個JS應用程序在aws ec2上運行 - 對應用程序的原始調用是http - 但是當更改爲https時,調用被拒絕 - 對不起,這個不詳細 - 項目包括mongodb節點js等....如果有人覺得他們可能會提供幫助,將提供更多的細節和可能需要的代碼JS應用程序未通過https運行aws
inspect =混合內容:'https://mediataplatform.com/COU_TEST.html'頁面通過HTTPS加載,但請求一個不安全的XMLHttpRequest端點'http://ec2-54-159-65-110.compute-1.amazonaws.com:3000/storeDetails'。此請求已被阻止;內容必須通過HTTPS提供。
strVar += " <form id=\"loginform\" name=\"loginform\"
method=\"POST\" action=\"http:\/\/ec2-54-159-65-110.compute-
1.amazonaws.com:3000\/storeDetails\">";
strVar += " <input type=\"hidden\" id = 'selectedEmotion' name =
\"selectedEmotion\" value='99'>";
ReferenceError: collection is not defined
at /home/ubuntu/expressproject/routes/index.js:118:3
at Layer.handle [as handle_request]
(/home/ubuntu/expressproject/node_modules/express/lib/router/layer.js:95:5)
at next
(/home/ubuntu/expressproject/node_modules/express/lib/router/route.js:131:13)
at Route.dispatch
(/home/ubuntu/expressproject/node_modules/express/lib/router/route.js:112:3)
at Layer.handle [as handle_request]
(/home/ubuntu/expressproject/node_modules/express/lib/router/layer.js:95:5)
at
/home/ubuntu/expressproject/node_modules/express/lib/router/index.js:277:22
at Function.process_params
(/home/ubuntu/expressproject/node_modules/express/lib/router/index.js:330:12)
at next
(/home/ubuntu/expressproject/node_modules/express/lib/router/index.js:271:10)
at /home/ubuntu/expressproject/node_modules/express-mongo-db/index.js:23:5
你將不得不包括更多的細節,特別是代碼。 –