aluzzardi / wssh

SSH to WebSockets Bridge
MIT License
1.37k stars 273 forks source link

Chrome shows blank after log in #2

Open bbhenry opened 11 years ago

bbhenry commented 11 years ago

I am using the latest Chrome and once I log in with my ssh credential, that web page is blank with only the WSSH title bar left on top of the page. And I tested with Firefox which works fine.

Is there a way to adjust the terminal size? Font size?

Thanks,

Henry

aluzzardi commented 11 years ago

There might be an error in the JS code that prevents the page to load.

Could you open the Javascript Console of Chrome and try to reload the page? It should give you the error description.

Thanks,

mrijken commented 11 years ago

The error I get in the console is:

Refused to execute script from 'https://raw.github.com/chjj/tty.js/36717df8e96f35f4e2bd3fd585e9361f1439fc7e/static/term.js' because its MIME type ('text/plain') is not executable, and strict MIME type checking is enabled.

mculhane commented 11 years ago

Apparently Chrome used to ignore MIME types until recently, but now Chrome does MIME type checking. As a result, Chrome refuses to execute stuff on raw.github.com (which has the non-executable type 'text/plain').

I was able to get rid of the error by downloading the file and linking to it locally. Once I did that, the terminal popped back up in Chrome and everything worked just fine.

Alternatively, some clever folks seem to have come up with https://rawgithub.com, which simply serves content from https://raw.github.com with the proper content types (though it's not to be used in production environments). So, just removing the first dot in the script URL should fix the issue as well.