javascript - How can I output results to the 'result' window in JSFiddle? -
i've tried using console.log()
need have developer window open in chrome see output. alert()
writes pop-up box. want output result window (bottom-right pane) in jsfiddle. can tell me please?
updated visual of answer jajadrinker - this.
add html section:
<div id="console-log"></div>
add javascript section:
var consoleline = "<p class=\"console-line\"></p>"; console = { log: function (text) { $("#console-log").append($(consoleline).html(text)); } };
optionally, add css make more user friendly:
.console-line { font-family: monospace; margin: 2px; }
you can see example here.
Comments
Post a Comment