working JavaScript code from my geek-college ;) very nice