forked from WebDesignWorx/GlobalStrings_Manager
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfunctions.php
32 lines (25 loc) · 1.31 KB
/
functions.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
<?php
/**
* @platform WebsiteBaker Community Edition
* @package GlobalStrings Manager
* @author Christian M. Stefan (Stefek)
* @copyright Christian M. Stefan
* @license http://www.gnu.org/licenses/gpl-2.0.html
*/
//no direct file access
if(count(get_included_files())==1) die(header("Location: ../index.php", TRUE, 301));
$aPossibleStringTypes = array('textarea', 'shorttext', 'wysiwyg');
$sDirname = basename(dirname(__FILE__));
defined('STRINGS_CFG_TBL') or define('STRINGS_CFG_TBL', TABLE_PREFIX ."mod_".$sDirname."_cfg");
defined('STRINGS_FIELDS_TBL') or define('STRINGS_FIELDS_TBL', TABLE_PREFIX ."mod_".$sDirname."_fields");
defined('STRINGS_CONTENTS_TBL') or define('STRINGS_CONTENTS_TBL', TABLE_PREFIX ."mod_".$sDirname."_contents");
if(!isset($toolUrl)) $toolUrl = ADMIN_URL.'/admintools/tool.php?tool='.$sDirname;
if(!isset($modulePath)) $modulePath = WB_PATH.'/modules/'.$sDirname;
if(!isset($toolPath)) $toolPath = WB_PATH.'/modules/'.$sDirname;
if(!isset($module_name)) $module_name = 'GlobalStrings Manager';
$icons = WB_URL.'/modules/'.$sDirname.'/icons';
global $TOOL_TEXT;
// include useful common functions
include_once('functions/common.functions.php');
//include this AdminTool's specific functions
include_once('functions/global_strings.functions.php');