Reputation: 261
I can see the server, but when I load the app I get a red div across the front that says:
Vorlon.js: please load socket.io before referencing vorlon.js or use includeSocketIO = true in your catalog.json file.
my terminal gives me the following output every time I load the server page:
{
"useSSL": false,
"SSLkey": "cert/server.key",
"SSLcert": "cert/server.crt",
"includeSocketIO": true,
"plugins": [
{ "id": "CONSOLE", "name": "Interactive Console", "panel": "bottom", "foldername": "interactiveConsole", "enabled": true },
{ "id": "DOM", "name": "Dom Explorer", "panel": "top", "foldername": "domExplorer", "enabled": true },
{ "id": "MODERNIZR", "name": "Modernizr", "panel": "bottom", "foldername": "modernizrReport", "enabled": true },
{ "id": "OBJEXPLORER", "name": "Obj. Explorer", "panel": "top", "foldername": "objectExplorer", "enabled": true },
{ "id": "XHRPANEL", "name": "XHR", "panel": "top", "foldername": "xhrPanel", "enabled": true },
{ "id": "NGINSPECTOR", "name": "Ng. Inspector", "panel": "top", "foldername": "ngInspector", "enabled": false },
{ "id": "NETWORK", "name": "Network Monitor", "panel": "top", "foldername": "networkMonitor", "enabled": true },
{ "id": "RESOURCES", "name": "Resources Explorer", "panel": "top", "foldername": "resourcesExplorer", "enabled": true }
]
}
(fourth line down, includeSocketIO is set to true).
Has anyone else had a similar issue (and hopefully been able to fix it)?
Upvotes: 3
Views: 546
Reputation: 1191
It looks like the problem comes from CORS errors. Socket.io doesn't have the right permission to write across domains. To fix the issue so I could open my app on my iPad, I did this:
http://mymachine.local/...
on my iPad, and I set the Vorlon script URL to http://mymachine.local:1337/vorlon.js
in my page. Instead of mymachine.local
, this might be your local network IP (192.168.x.x
).If it's still not working, open your app in a second browser (I tested in FF with the Vorlon server open in Chrome) and check the console for CORS errors.
Hope this helps.
Upvotes: 2