remove widget html_only, add widget html_php_card

This commit is contained in:
iBNu Maksum
2025-03-04 16:14:10 +07:00
parent 3b7d478635
commit 8429ed763e
7 changed files with 546 additions and 20 deletions

View 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');
}
}