[ https://issues.apache.org/jira/browse/CB-1585?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13470574#comment-13470574 ]
Jesse MacFadyen commented on CB-1585: ------------------------------------- On Windows8 and WP7 I do this : {code:javascript} if(!console || !console.log) { var exec = require('cordova/exec'); var debugConsole = { log:function(msg){ exec(null,null,"DebugConsole","log",msg); }, warn:function(msg){ exec(null,null,"DebugConsole","warn",msg); }, error:function(msg){ exec(null,null,"DebugConsole","error",msg); } }; module.exports = debugConsole; } else if(console && console.log) { console.log("console.log exists already!"); console.warn = console.warn || function(msg){console.log("warn:"+msg);}; console.error = console.error || function(msg){console.log("error:"+msg);}; } {code} This could probably be used elsewherz. > console.debug, console.info are undefined > ----------------------------------------- > > Key: CB-1585 > URL: https://issues.apache.org/jira/browse/CB-1585 > Project: Apache Cordova > Issue Type: Bug > Components: CordovaJS > Affects Versions: 2.1.0 > Environment: phonegap-phonegap-2.1.0-0-g26d211b.zip > Reporter: Jeffrey Knight > Assignee: Patrick Mueller > Priority: Critical > Labels: javascript > > cordova-2.1.0.js > Issue: Web app works as expected in browser. Firebug shows console.debug + > console.info messages. Drop app into phonegap and it does not work. > > Cause: console.debug/info are not defined. > Fix: add debug+info protypes to console: > https://github.com/jknight/incubator-cordova-js/blob/patch-1/lib/ios/plugin/ios/console.js -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira