mirror of
https://github.com/hotspotbilling/phpnuxbill.git
synced 2025-06-25 19:18:33 +02:00
getting ready for customizeable dashboard with widget
This commit is contained in:
parent
30bdb89d91
commit
eff0c7dab7
27 changed files with 1112 additions and 2 deletions
22
system/widgets/html_php.php
Normal file
22
system/widgets/html_php.php
Normal file
|
@ -0,0 +1,22 @@
|
|||
<?php
|
||||
|
||||
class html_php
|
||||
{
|
||||
|
||||
public function getWidget($data = null)
|
||||
{
|
||||
global $ui;
|
||||
$ui->assign('card_header', $data['title']);
|
||||
ob_start();
|
||||
try{
|
||||
eval('?>'. $data['content']);
|
||||
}catch(Exception $e){
|
||||
echo $e->getMessage();
|
||||
echo "<br>";
|
||||
echo $e->getTraceAsString();
|
||||
}
|
||||
$content = ob_get_clean();
|
||||
$ui->assign('card_body', $content);
|
||||
return $ui->fetch('widget/card_html.tpl');
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue