From d9aca6be7691ea48547c1514632ce4794237db1b Mon Sep 17 00:00:00 2001 From: Jordi Boggiano Date: Sun, 15 Jan 2012 18:04:04 +0100 Subject: [PATCH] Make sure it works without javascript --- index.php | 3 +-- php-console.js | 9 ++++++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/index.php b/index.php index 047b14e..f84bea6 100644 --- a/index.php +++ b/index.php @@ -87,9 +87,8 @@ if (isset($_POST['code'])) {
-
-
+
Line: 1, Column: 1 diff --git a/php-console.js b/php-console.js index 2af24e4..f25e2c4 100644 --- a/php-console.js +++ b/php-console.js @@ -72,10 +72,17 @@ }; initializeAce = function() { + var PhpMode, code; + + code = $('#' + options.editor).text(); + $('#' + options.editor) + .replaceWith('
') + .text(code); + editor = ace.edit(options.editor); // set mode - var PhpMode = require("ace/mode/php").Mode; + PhpMode = require("ace/mode/php").Mode; editor.getSession().setMode(new PhpMode()); // tab size