<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>cli.php</filename>
    </added>
    <added>
      <filename>common.php</filename>
    </added>
    <added>
      <filename>console.css</filename>
    </added>
    <added>
      <filename>console.js</filename>
    </added>
    <added>
      <filename>init.php</filename>
    </added>
    <added>
      <filename>lib/FastJSON.class.php</filename>
    </added>
    <added>
      <filename>query.php</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -8,102 +8,33 @@ Author URI: http://jerodsanto.net
 Version: 0.1.0
 */
 
-@ob_end_clean();
-error_reporting(E_ALL);
-set_time_limit(0);
-
-require_once &quot;Shell.php&quot;;
-require_once &quot;Shell/Extensions/Autoload.php&quot;;
-require_once &quot;Shell/Extensions/AutoloadDebug.php&quot;;
-require_once &quot;Shell/Extensions/Colour.php&quot;;
-require_once &quot;Shell/Extensions/ExecutionTime.php&quot;;
-require_once &quot;Shell/Extensions/InlineHelp.php&quot;;
-require_once &quot;Shell/Extensions/VerbosePrint.php&quot;;
-require_once &quot;Shell/Extensions/LoadScript.php&quot;;
-require_once dirname(__FILE__) . &quot;/../../../wp-load.php&quot;;
-    
-
-$__shell = new PHP_Shell();
-$__shell_exts = PHP_Shell_Extensions::getInstance();
-$__shell_exts-&gt;registerExtensions(array(
-    &quot;options&quot;        =&gt; PHP_Shell_Options::getInstance(), /* the :set command */
-    &quot;autoload&quot;       =&gt; new PHP_Shell_Extensions_Autoload(),
-    &quot;autoload_debug&quot; =&gt; new PHP_Shell_Extensions_AutoloadDebug(),
-    &quot;colour&quot;         =&gt; new PHP_Shell_Extensions_Colour(),
-    &quot;exectime&quot;       =&gt; new PHP_Shell_Extensions_ExecutionTime(),
-    &quot;inlinehelp&quot;     =&gt; new PHP_Shell_Extensions_InlineHelp(),
-    &quot;verboseprint&quot;   =&gt; new PHP_Shell_Extensions_VerbosePrint(),
-    &quot;loadscript&quot;     =&gt; new PHP_Shell_Extensions_LoadScript(),
-));
-$__shell_exts-&gt;colour-&gt;applyColourScheme(&quot;dark&quot;);
-
-$f = &lt;&lt;&lt;EOF
-WordPress Console - 0.1.0%s
-
-&gt;&gt; use '?' for help
-
-EOF;
-
-printf($f, 
-    $__shell-&gt;hasReadline() ? '' : ', PHP is missing readline support (command history, tab-completion)');
-unset($f);
+// require('common.php');
+
+// THE CSS AND THE JAVASCRIPTS
+function console_add_headers() {
+  $css_url = WP_PLUGIN_URL . '/wordpress-console/console.css';
+  $js_url  = WP_PLUGIN_URL . '/wordpress-console/console.js';
+  echo '&lt;link rel=&quot;stylesheet&quot; type=&quot;text/css&quot; href=&quot;' . $css_url . '&quot; /&gt;';
+  echo '&lt;script type=&quot;text/javascript&quot; src=&quot;' . $js_url .'&quot; &gt;&lt;/script&gt;';
+}
 
-print $__shell_exts-&gt;colour-&gt;getColour(&quot;default&quot;);
-while($__shell-&gt;input()) {
+// THE CONSOLE
+function console_admin_page() {
+  $page_url = str_replace( '%7E', '~', $_SERVER['REQUEST_URI']);
+  // session_start();
   
-  if ($__shell_exts-&gt;autoload-&gt;isAutoloadEnabled() &amp;&amp; !function_exists('__autoload')) {
-    function __autoload($classname) {
-      global $__shell_exts;
-
-      if ($__shell_exts-&gt;autoload_debug-&gt;isAutoloadDebug()) {
-        print str_repeat(&quot;.&quot;, $__shell_exts-&gt;autoload_debug-&gt;incAutoloadDepth()).&quot; -&gt; autoloading $classname&quot;.PHP_EOL;
-      }
-      include_once str_replace('_', '/', $classname).'.php';
-      if ($__shell_exts-&gt;autoload_debug-&gt;isAutoloadDebug()) {
-        print str_repeat(&quot;.&quot;, $__shell_exts-&gt;autoload_debug-&gt;decAutoloadDepth()).&quot; &lt;- autoloading $classname&quot;.PHP_EOL;
-      }
-    }
-  }
-
-  try {
-    $__shell_exts-&gt;exectime-&gt;startParseTime();
-    if ($__shell-&gt;parse() == 0) {
-      ## we have a full command, execute it
-
-      $__shell_exts-&gt;exectime-&gt;startExecTime();
-      $__shell_retval = eval($__shell-&gt;getCode()); 
-      if (isset($__shell_retval)) {
-        print $__shell_exts-&gt;colour-&gt;getColour(&quot;value&quot;);
-
-        if (function_exists(&quot;__shell_print_var&quot;)) {
-          __shell_print_var($__shell_retval, $__shell_exts-&gt;verboseprint-&gt;isVerbose());
-        } else {
-          var_export($__shell_retval);
-        }
-      }
-      ## cleanup the variable namespace
-      unset($__shell_retval);
-      $__shell-&gt;resetCode();
-    }
-  } catch(Exception $__shell_exception) {
-    print $__shell_exts-&gt;colour-&gt;getColour(&quot;exception&quot;);
-    print $__shell_exception-&gt;getMessage();
-
-    $__shell-&gt;resetCode();
-
-    ## cleanup the variable namespace
-    unset($__shell_exception);
-  }
-  print $__shell_exts-&gt;colour-&gt;getColour(&quot;default&quot;);
-  $__shell_exts-&gt;exectime-&gt;stopTime();
-  if ($__shell_exts-&gt;exectime-&gt;isShow()) {
-    printf(&quot; (parse: %.4fs, exec: %.4fs)&quot;, 
-      $__shell_exts-&gt;exectime-&gt;getParseTime(),
-      $__shell_exts-&gt;exectime-&gt;getExecTime()
-      );
-  }
+  echo '&lt;div id=&quot;wrap&quot;&gt;';
+  echo '&lt;h2&gt;WordPress Console&lt;/h2&gt;';
+  echo '&lt;div id=&quot;wrapper&quot;&gt;';
+  echo '&lt;/div&gt;';
+  echo '&lt;/div&gt;';
 }
 
-print $__shell_exts-&gt;colour-&gt;getColour(&quot;reset&quot;);
+// THE HOOK-UP
+add_action('admin_menu', 'console_add_page');
+add_action('admin_head', 'console_add_headers');
 
+function console_add_page() {
+  add_management_page('Console', 'Console', 10, __FILE__, 'console_admin_page');
+}
 ?&gt;
\ No newline at end of file</diff>
      <filename>wordpress-console.php</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>0bfbee2b3d57107357509465280136779750d5fb</id>
    </parent>
  </parents>
  <author>
    <name>sant0sk1</name>
    <email>sant0sk1@b8457f37-d9ea-0310-8a92-e5e31aec5664</email>
  </author>
  <url>http://github.com/sant0sk1/wordpress-console/commit/b536fc891b0fad63907adab0cb7385c867ee74f9</url>
  <id>b536fc891b0fad63907adab0cb7385c867ee74f9</id>
  <committed-date>2009-06-23T10:45:44-07:00</committed-date>
  <authored-date>2009-06-23T10:45:44-07:00</authored-date>
  <message>major progress in creating in-browser console.

git-svn-id: http://svn.wp-plugins.org/wordpress-console/trunk@128837 b8457f37-d9ea-0310-8a92-e5e31aec5664</message>
  <tree>e58f7087399c55a4839341a275f5cd6e8770451a</tree>
  <committer>
    <name>sant0sk1</name>
    <email>sant0sk1@b8457f37-d9ea-0310-8a92-e5e31aec5664</email>
  </committer>
</commit>
