I'm seeing the following behavior in Firebug:
When the debugger is paused on a breakpoint, if I go to the console and attempt to execute a statement, the Enter key keeps just adding lines instead of executing.
I've tried hitting Shift+Enter and Ctrl+Enter also, to no avail.
I'm seeing the following behavior in Firebug:
When the debugger is paused on a breakpoint, if I go to the console and attempt to execute a statement, the Enter key keeps just adding lines instead of executing.
I've tried hitting Shift+Enter and Ctrl+Enter also, to no avail.
Share Improve this question edited Jul 2, 2015 at 18:51 Gram 3761 gold badge7 silver badges19 bronze badges asked Jan 18, 2015 at 5:41 mtysonmtyson 8,58017 gold badges77 silver badges113 bronze badges 3- 1 Are you using the mand line or the mand editor (toggle-able with the little arrow button above right). In the mand editor you must click the "run" button above (then all mands will be executed unless 1 or more are highlighted) – DaveStSomeWhere Commented Jan 18, 2015 at 6:22
- 1 @DaveCoast: The mand editor sounds promising, but I don't see the arrow button to start it. – mtyson Commented Jan 18, 2015 at 17:43
- 1 The button to switch between the Command Line and the Command Editor has an arrow as symbol and is located at the very right side of the panel toolbar. Which version of Firefox and Firebug are you using? – Sebastian Zartner Commented Jan 18, 2015 at 22:02
2 Answers
Reset to default 8Environment
I sometimes get this issue on firebug (console), FireFox (dev console), and FireFox developer edition (dev console).
Issue
Using the "web console" I would type something like alert("test") and hit the enter key but it would not run.
Instead of running it would enter a new line as if I hit "Shift Enter". Oddly when I hit "Shift Enter" just to see what happens, there is no more new line but the code does not run.
Attempt to find a solution
I restarted my puter, and it went away only to return again later. I don't have a solution but more of a work around (that works some of the time). The biggest issue is I don't know what causes this to happen. After may hours I can only guess what I think the issue is.
I suspect that why this happens is the developer console gets disconnected with the web page that it is trying to debugged.
If the Dev tools are disconnected, then it can not run the code (my alert) because it does not know what page/tab to run it on.
Work Around
Fully closing all Firefox windows/tabs (and its dev/firebug windows/tabs). This may-or-may-not re-associate the console with the web page allowing the code to run again.
Disclaimer
It works for me most of the time, I would be vary happy if someone (who knows more about this) could explain why this happens and a better solution. But until then for anyone else with this issue like me I hope this helps.
I have experienced the same issue, where I would enter (a long) javascript statement in the console and pressing enter would just add new lines instead of running the statements.
In my case this was caused by brackets and parentheses that were not balanced. Once they were balanced, hitting the enter key would execute the statements.