A couple of years ago my professor said it is possible through javascript to access a computer but i didnt ask how and i dont want to know.
Not pure Javascript. It can be done using ActiveX or Java, and I think newer Netscape-ish browsers have a proprietary way of doing it.
neither he nor I recommend this because it open a whole slot of exploitations and ports
You probably meant ports. Even this is wrong, however: the only port that need be opened is the one already being used for the HTTP connection.