Completed
Push — master ( dc7924...1aa479 )
by Michael
11s
created

header.php (1 issue)

Upgrade to new PHP Analysis Engine

These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more

1
<?php
2
/**
3
 *
4
 * Module: WF-Links
5
 * Version: v1.0.3
6
 * Release Date: 21 June 2005
7
 * Developer: John N
8
 * Team: WF-Projects
9
 * Licence: GNU
10
 */
11
12
$moduleDirName = basename(__DIR__);
13
14
require_once __DIR__ . '/../../mainfile.php';
15
include XOOPS_ROOT_PATH . '/modules/' . $moduleDirName . '/include/config.php';
16
include XOOPS_ROOT_PATH . '/modules/' . $moduleDirName . '/class/utility.php';
17
require_once XOOPS_ROOT_PATH . '/modules/' . $moduleDirName . '/class/WfThumbsNails.php';
18
require_once XOOPS_ROOT_PATH . '/class/pagenav.php';
19
require_once XOOPS_ROOT_PATH . '/modules/' . $moduleDirName . '/class/xoopstree.php';
20
21
if (!file_exists(__DIR__ . '/language/' . $xoopsConfig['language'] . '/main.php')) {
22
    require_once __DIR__ . '/language/english/main.php';
23
}
24
25
require_once XOOPS_ROOT_PATH . '/modules/' . $moduleDirName . '/class/wfltextsanitizer.php';
26
$wfmyts = new WflTextSanitizer(); // MyTextSanitizer object
27
28
global $xoopModuleConfig;
0 ignored issues
show
Compatibility Best Practice introduced by
Use of global functionality is not recommended; it makes your code harder to test, and less reusable.

Instead of relying on global state, we recommend one of these alternatives:

1. Pass all data via parameters

function myFunction($a, $b) {
    // Do something
}

2. Create a class that maintains your state

class MyClass {
    private $a;
    private $b;

    public function __construct($a, $b) {
        $this->a = $a;
        $this->b = $b;
    }

    public function myFunction() {
        // Do something
    }
}
Loading history...
29