Completed
Push — master ( 65a58d...61df55 )
by Michael
08:26 queued 04:14
created

footer.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
* $Id: footer.php,v 1.13 2005/08/15 16:51:58 fx2024 Exp $
5
* Module: SmartFAQ
6
* Author: The SmartFactory <www.smartfactory.ca>
7
* Licence: GNU
8
*/
9
10
global $xoopsTpl, $xoopsModule, $xoopsModuleConfig;
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...
11
12
$uid = ($xoopsUser)? ($xoopsUser->getVar("uid")) : 0;
13
$isAdmin = (sf_userIsAdmin() || sf_moderator());
14
15
$xoopsTpl->assign("sf_adminpage", "<a href='" . XOOPS_URL . "/modules/smartfaq/admin/index.php'>" . _MD_SF_ADMIN_PAGE . "</a>");
16
$xoopsTpl->assign("isAdmin", $isAdmin);
17
18
$xoopsTpl->assign(array('lang_on' => _MD_SF_ON, 'lang_postedby' => _MD_SF_POSTEDBY, 'lang_faq' => _MD_SF_QUESTION, 'lang_datesub' => _MD_SF_DATESUB, 'lang_hits' => _MD_SF_HITS));
19
$xoopsTpl->assign('sectionname', $myts->displayTarea($xoopsModule->getVar('name')));
20
21
$xoopsTpl->assign('modulename', $xoopsModule->dirname());
22
$xoopsTpl->assign('displaylastfaq', $xoopsModuleConfig['displaylastfaq']);
23
$xoopsTpl->assign('displaysubcatdsc', $xoopsModuleConfig['displaysubcatdsc']);
24
$xoopsTpl->assign('displaycollaps', $xoopsModuleConfig['displaycollaps']);
25
$xoopsTpl->assign('display_date_col', $xoopsModuleConfig['display_date_col']);
26
$xoopsTpl->assign('display_hits_col', $xoopsModuleConfig['display_hits_col']);
27
28
$xoopsTpl->assign("displaytopcatdsc", $xoopsModuleConfig['displaytopcatdsc']);
29
30
$xoopsTpl->assign("ref_smartfaq", "SmartFAQ is developed by The SmartFactory (http://www.smartfactory.ca), a division of InBox Solutions (http://www.inboxsolutions.net)");
31
32
$xoopsTpl->assign("xoops_module_header", "<link rel='stylesheet' type='text/css' href='" . XOOPS_URL . "/modules/smartfaq/smartfaq.css'/>");
33