diff --git a/public_html/inc_functions.php b/public_html/inc_functions.php index f2a5a283995aa24c440de6bb38b3a0d322fdcb11..3118b316e074e29edeef04277a1badfe700af412 100644 --- a/public_html/inc_functions.php +++ b/public_html/inc_functions.php @@ -7,16 +7,30 @@ function showExample($sPhpcode){ eval("\$sOut=$sPhpcode;"); return ' - <h3>PHP code</h3> - <pre>'.htmlentities($sPhpcode).'</pre> - - <h3>Output</h3> - visual output:<br> - <br> - '.$sOut.' - <br> - generated html code: - <pre>'.htmlentities(str_replace([">", "</"], [">\n", "\n</"], $sOut)).'</pre> - + <table class="table"> + <thead> + <tr> + <th>Source</th> + <th>Output</th> + <th>Generated html code</th> + </tr> + </thead> + <tbody> + <tr> + <td> + <div class="language-php max-height-300 highlighter-rouge"><div class="highlight"> + <pre class="highlight">'.htmlentities($sPhpcode).'</pre> + </div></div> + </td> + <td> + '.$sOut.' + </td> + <td> + <pre>'.htmlentities(str_replace([">", "</"], [">\n", "\n</"], $sOut)).'</pre> + </td> + </tr> + </tbody> + </table> + '; } \ No newline at end of file diff --git a/public_html/pages/component.php b/public_html/pages/component.php index eefcb52ec377ac8240201df4080431fcd2a8d08f..290c17b07397921cc02a6f2876a84a587fa0de3f 100644 --- a/public_html/pages/component.php +++ b/public_html/pages/component.php @@ -41,7 +41,7 @@ if(!isset($aComponents[$sComponent])){ ) .$renderAdminLTE->addRow( '<h3>Syntax</h3> - <pre>echo $renderAdminLTE-><strong>'.$aComp['method'].'</strong>($aOptions)</pre> + <code>echo $renderAdminLTE-><strong>'.$aComp['method'].'</strong>($aOptions)</code> ' ); diff --git a/public_html/ui/main.css b/public_html/ui/main.css new file mode 100644 index 0000000000000000000000000000000000000000..6648c9649822cc07622cb6b01c4c8f9cedc74351 --- /dev/null +++ b/public_html/ui/main.css @@ -0,0 +1,2 @@ + +pre{background-color: #445; color: #f8f8f8}; \ No newline at end of file