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

@ -39,8 +39,7 @@ if ($action == 'add') {
$enabled = alphanumeric($_POST['enabled']);
$title = _post('title');
$widget = _post('widget');
$content = _post('content');
print_r($_POST);
$d = ORM::for_table('tbl_widgets')->create();
$d->orders = $orders;
$d->position = $position;
@ -48,7 +47,7 @@ if ($action == 'add') {
$d->enabled = $enabled;
$d->title = $title;
$d->widget = $widget;
$d->content = $content;
$d->content = _post('content');
$d->save();
if ($d->id() > 0) {
r2(getUrl('widgets&user=' . $tipeUser), 's', 'Widget Added Successfully');
@ -79,8 +78,6 @@ if ($action == 'add') {
$enabled = alphanumeric($_POST['enabled']);
$title = _post('title');
$widget = _post('widget');
$content = _post('content');
$d = ORM::for_table('tbl_widgets')->find_one($id);
$d->orders = $orders;
$d->position = $position;
@ -88,7 +85,7 @@ if ($action == 'add') {
$d->enabled = $enabled;
$d->title = $title;
$d->widget = $widget;
$d->content = $content;
$d->content = _post('content');
$d->save();
r2(getUrl('widgets&user=' . $tipeUser), 's', 'Widget Saved Successfully');
}