Skip to content

Commit

Permalink
adding the DEBUG flag for settings page.
Browse files Browse the repository at this point in the history
  • Loading branch information
seanchen committed Jan 20, 2013
1 parent d7b9ec0 commit 3fcfe38
Showing 1 changed file with 29 additions and 23 deletions.
52 changes: 29 additions & 23 deletions wp-trac-client/admin-settings.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<?php

$DEBUG = False;

if (isset($_POST['wptc_settings_form_submit']) &&
$_POST['wptc_settings_form_submit'] == 'Y') {

Expand Down Expand Up @@ -102,29 +104,33 @@
</tbody></table>
</form>

<h3>Some temp Testing:</h3>
<p>Current Blog ID: <?php echo get_current_blog_id() ?></p>
<p>Current User ID: <?php echo get_current_user_id() ?></p>
<p>Option blog name: <?php echo get_option('blogname') ?></p>
<p>include path: <?php echo get_include_path() ?></p>
<p>PLUGIN URL: <?php echo plugins_url('wp-trac-client/js/jquery.dataTables.js'); ?> </p>
<?php if ($DEBUG) {
// some testing code.
?>
<h3>Some temp Testing:</h3>
<p>Current Blog ID: <?php echo get_current_blog_id() ?></p>
<p>Current User ID: <?php echo get_current_user_id() ?></p>
<p>Option blog name: <?php echo get_option('blogname') ?></p>
<p>include path: <?php echo get_include_path() ?></p>
<p>PLUGIN URL: <?php echo plugins_url('wp-trac-client/js/jquery.dataTables.js'); ?> </p>

<p>
<?php
$a = "123 abc cde";
list($a1, $a2) = explode(" ", $a);
var_dump($a1);
var_dump($a2);
$aa = explode(" ", $a);
echo "<pre>";
var_dump($aa);
echo "</pre>";
echo "<pre>shift out ";
echo array_shift($aa);
echo "</pre>";
echo "<pre> again!";
var_dump(wptc_get_ticket_types());
echo "</pre>";
?></p>
<p>
<?php
$a = "123 abc cde";
list($a1, $a2) = explode(" ", $a);
var_dump($a1);
var_dump($a2);
$aa = explode(" ", $a);
echo "<pre>";
var_dump($aa);
echo "</pre>";
echo "<pre>shift out ";
echo array_shift($aa);
echo "</pre>";
echo "<pre> again!";
var_dump(wptc_get_ticket_types());
echo "</pre>";
?></p>
<?php } ?>

</div>

0 comments on commit 3fcfe38

Please sign in to comment.