if (window.console) { var cons = console; if (cons) { cons.log('hello world, U r my world.'); } }