Issues (1149)

include/couponform.php (15 issues)

Labels
Severity
1
<?php
2
/*
3
 * You may not change or alter any portion of this comment or credits
4
 * of supporting developers from this source code or any supporting source code
5
 * which is considered copyrighted (c) material of the original comment or credit authors.
6
 *
7
 * This program is distributed in the hope that it will be useful,
8
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
9
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10
 */
11
12
/**
13
 * @copyright    {@link https://xoops.org/ XOOPS Project}
14
 * @license      {@link http://www.gnu.org/licenses/gpl-2.0.html GNU GPL 2 or later}
15
 * @package      efqdirectory
16
 * @since
17
 * @author       Martijn Hertog (aka wtravel)
18
 * @author       XOOPS Development Team,
19
 */
20
21
require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
0 ignored issues
show
The constant XOOPS_ROOT_PATH was not found. Maybe you did not declare it correctly or list all dependencies?
Loading history...
22
require_once XOOPS_ROOT_PATH . '/class/xoopslists.php';
23
24
$uploaddirectory = '/uploads/';
25
26
$coupform      = new XoopsThemeForm(_MD_COUPONFORM, 'couponform', $_SERVER['PHP_SELF'], 'POST', true);
0 ignored issues
show
The type XoopsThemeForm was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
27
$linkimg_array = XoopsLists::getImgListAsArray(XOOPS_ROOT_PATH . '/uploads/');
0 ignored issues
show
The type XoopsLists was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
28
$coupform->addElement(new XoopsFormHidden('itemid', $itemid));
0 ignored issues
show
The type XoopsFormHidden was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
29
$coupform->addElement(new XoopsFormText(_MD_COUPONHEADER, 'heading', 25, 30, $heading), true);
0 ignored issues
show
The type XoopsFormText was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
30
$coupform->addElement(new XoopsFormDhtmlTextArea(_MD_DESCRIPTIONC, 'description', $description));
0 ignored issues
show
The type XoopsFormDhtmlTextArea was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
31
$image_option = new XoopsFormSelect(_MD_COUPONIMGMGR . '<br>' . _MD_COUPONIMG . '<br>', 'image', $image);
0 ignored issues
show
The type XoopsFormSelect was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
32
$image_option->addOptionArray($linkimg_array);
33
$imgtray = new XoopsFormElementTray(_MD_COUPSEL, '<br>');
0 ignored issues
show
The type XoopsFormElementTray was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
34
35
$image_option->setExtra("onchange='showImgSelected(\"imagex\", \"image\", \"" . $uploaddirectory . '", "", "' . XOOPS_URL . "\")'");
0 ignored issues
show
The constant XOOPS_URL was not found. Maybe you did not declare it correctly or list all dependencies?
Loading history...
36
$imgtray->addElement($image_option, false);
37
$imgtray->addElement(new XoopsFormLabel('', "<br><img src='" . $uploaddirectory . '/' . $image . '\' name=\'imagex\' id=\'imagex\' alt=\'\'>'));
0 ignored issues
show
The type XoopsFormLabel was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
38
$coupform->addElement($imgtray);
39
$coupform->addElement(new XoopsFormRadioYN(_MD_CONVERTLBR, 'lbr', $lbr));
0 ignored issues
show
The type XoopsFormRadioYN was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
40
$coupform->addElement(new XoopsFormDateTime(_MD_PUBLISHCOUPON, 'publish', 25, $publish));
0 ignored issues
show
The type XoopsFormDateTime was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
41
$expire_option = new XoopsFormCheckBox(_MD_SETEXPIRATION, 'expire_enable', $setexpire);
0 ignored issues
show
The type XoopsFormCheckBox was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
42
$expire_option->addOption(1, _YES);
0 ignored issues
show
The constant _YES was not found. Maybe you did not declare it correctly or list all dependencies?
Loading history...
43
$coupform->addElement($expire_option);
44
$coupform->addElement(new XoopsFormDateTime(_MD_EXPIRECOUPON, 'expire', 25, $expire));
45
46
$button_tray = new XoopsFormElementTray('');
47
$button_tray->addElement(new XoopsFormButton('', 'submit', _MD_SUBMIT, 'submit'));
0 ignored issues
show
The type XoopsFormButton was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
48
49
if ($couponid) {
50
    $button_tray->addElement(new XoopsFormButton('', 'delete', _MD_DELETE, 'submit'));
51
    $coupform->addElement(new XoopsFormHidden('couponid', $couponid));
52
}
53
$coupform->addElement($button_tray);
54
$coupform->display();
55