File: 0.01.1a/pages/debug.php (View as HTML)

  1: <?php 
  2: /* -------------------------------------------------------------
  3: This file is part of FreeDESK
  4: 
  5: FreeDESK is (C) Copyright 2012 David Cutting
  6: 
  7: FreeDESK is free software: you can redistribute it and/or modify
  8: it under the terms of the GNU General Public License as published by
  9: the Free Software Foundation, either version 3 of the License, or
 10: (at your option) any later version.
 11: 
 12: FreeDESK is distributed in the hope that it will be useful,
 13: but WITHOUT ANY WARRANTY; without even the implied warranty of
 14: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 15: GNU General Public License for more details.
 16: 
 17: You should have received a copy of the GNU General Public License
 18: along with FreeDESK.  If not, see www.gnu.org/licenses
 19: 
 20: For more information see www.purplepixie.org/freedesk/
 21: -------------------------------------------------------------- */
 22: 
 23: /**
 24:  * Debug page
 25: **/
 26: global $DESK;
 27: echo "<div id=\"debug_info\">\n";
 28: echo "<h3>FreeDESK Version: ".$DESK->FullVersion()." </h3><br />\n";
 29: 
 30: echo "<b>Sub-Components</b><br /><br />";
 31: echo "<table>";
 32: echo "<tr><th>Module Name</th><th>Version</th><th>Type / Sub-Type</th></tr>";
 33: $plugs=$DESK->PluginManager->GetAll();
 34: foreach($plugs as $plug)
 35: {
 36: 	echo "<tr><td>".$plug->name."</td>";
 37: 	echo "<td>".$plug->version."</td>";
 38: 	echo "<td>".$plug->type." ";
 39: 	if ($plug->subtype != "")
 40: 		echo "/ ".$plug->subtype;
 41: 	echo "</td>";
 42: 	echo "</tr>";
 43: }
 44: echo "</table>\n";
 45: 
 46: echo "</div>\n";
 47: 
 48: echo "<br /><br />";
 49: 
 50: echo "<div id=\"js_debug\">\n";
 51: echo "<a href=\"#\" onclick=\"DESK.debugData('js_debug', '".$DESK->ContextManager->Session->sid."');\">Client-Side Debug Information</a>\n";
 52: echo "</div>\n";
 53: 
 54: //<script type="text/javascript">
 55: //document.getElementById("debug_info").innerHTML += "blah";
 56: //</script>
 57: 
 58: