Browse Source

Files cleanup, preparation for 1.9 maintenance release

master
Janusz Tylek 2 years ago
parent
commit
a465e25df5
100 changed files with 1992 additions and 16064 deletions
  1. +0
    -4
      .babelrc
  2. +0
    -10
      .eslintrc.json
  3. +2
    -2
      README.md
  4. +1
    -0
      admin/modules/ConfigInfo.php
  5. +8
    -9
      check.php
  6. +12
    -10
      composer.json
  7. +1675
    -904
      composer.lock
  8. +0
    -1
      console.php
  9. +7
    -7
      console/Develop/CreateModuleCommand.php
  10. +7
    -7
      console/Develop/CreateTestModuleCommand.php
  11. +0
    -32
      console/Modules/RebuildModulesDatabaseCommand.php
  12. +0
    -6
      crowdin.yml
  13. +0
    -0
      dist/.gitkeep
  14. +0
    -12
      folder/nl/en.php.Dutch.old
  15. +0
    -10
      folder/no/en.php.Norwegian.old
  16. +0
    -2127
      folder/ro/en.php.Romanian.old
  17. BIN
      images/epesi_logo_RGB_Solid.png
  18. BIN
      images/epesi_logo_RGB_Solid_login.png
  19. BIN
      images/favicon.png
  20. BIN
      images/logo.png
  21. +0
    -1
      include.php
  22. +1
    -0
      include/config.php
  23. +3
    -3
      include/epesi.php
  24. +2
    -2
      include/error.php
  25. +0
    -15
      include/fontawesome.php
  26. +133
    -2
      include/misc.php
  27. +9
    -9
      include/module.php
  28. +1
    -1
      include/module_manager.php
  29. +0
    -1
      include/session.php
  30. +2
    -0
      include/simple_login.php
  31. +128
    -180
      index.php
  32. +1
    -1
      init_js.php
  33. +0
    -5
      libs/bootstrap-datetimepicker.min.css
  34. +0
    -2
      libs/bootstrap-datetimepicker.min.js
  35. BIN
      libs/images/ui-icons_444444_256x240.png
  36. BIN
      libs/images/ui-icons_555555_256x240.png
  37. BIN
      libs/images/ui-icons_777620_256x240.png
  38. BIN
      libs/images/ui-icons_777777_256x240.png
  39. BIN
      libs/images/ui-icons_cc0000_256x240.png
  40. BIN
      libs/images/ui-icons_ffffff_256x240.png
  41. +0
    -117
      libs/jquery.clonePosition.js
  42. +0
    -1216
      libs/moment-with-locales.min.js
  43. +0
    -127
      libs/php-fontawesome.php
  44. +0
    -4
      libs/quickform/.gitignore
  45. +0
    -290
      libs/quickform/Common.php
  46. +0
    -1712
      libs/quickform/QuickForm.php
  47. +0
    -32
      libs/quickform/QuickForm/Error.php
  48. +0
    -490
      libs/quickform/QuickForm/Field/Group/date.php
  49. +0
    -556
      libs/quickform/QuickForm/Field/Group/hierselect.php
  50. +0
    -213
      libs/quickform/QuickForm/Field/Input/advcheckbox.php
  51. +0
    -32
      libs/quickform/QuickForm/Field/Input/autocomplete.php
  52. +0
    -43
      libs/quickform/QuickForm/Field/Input/button.php
  53. +0
    -185
      libs/quickform/QuickForm/Field/Input/checkbox.php
  54. +0
    -272
      libs/quickform/QuickForm/Field/Input/file.php
  55. +0
    -55
      libs/quickform/QuickForm/Field/Input/hidden.php
  56. +0
    -72
      libs/quickform/QuickForm/Field/Input/image.php
  57. +0
    -66
      libs/quickform/QuickForm/Field/Input/password.php
  58. +0
    -171
      libs/quickform/QuickForm/Field/Input/radio.php
  59. +0
    -42
      libs/quickform/QuickForm/Field/Input/reset.php
  60. +0
    -50
      libs/quickform/QuickForm/Field/Input/submit.php
  61. +0
    -55
      libs/quickform/QuickForm/Field/Input/text.php
  62. +0
    -207
      libs/quickform/QuickForm/Field/Multi/automulti.php
  63. +0
    -279
      libs/quickform/QuickForm/Field/Multi/multiselect.php
  64. +0
    -193
      libs/quickform/QuickForm/Field/Select/autoselect.php
  65. +0
    -79
      libs/quickform/QuickForm/Field/Select/hiddenselect.php
  66. +0
    -39
      libs/quickform/QuickForm/Field/Static/header.php
  67. +0
    -42
      libs/quickform/QuickForm/Field/Static/html.php
  68. +0
    -97
      libs/quickform/QuickForm/Field/Static/link.php
  69. +0
    -474
      libs/quickform/QuickForm/Field/group.php
  70. +0
    -101
      libs/quickform/QuickForm/Field/input.php
  71. +0
    -144
      libs/quickform/QuickForm/Field/multi.php
  72. +0
    -438
      libs/quickform/QuickForm/Field/select.php
  73. +0
    -114
      libs/quickform/QuickForm/Field/static.php
  74. +0
    -120
      libs/quickform/QuickForm/Field/textarea.php
  75. +0
    -13
      libs/quickform/QuickForm/Field/toHtml.php
  76. +0
    -108
      libs/quickform/QuickForm/Field/xbutton.php
  77. +0
    -84
      libs/quickform/QuickForm/Renderer.php
  78. +0
    -321
      libs/quickform/QuickForm/Renderer/Array.php
  79. +0
    -367
      libs/quickform/QuickForm/Renderer/ArraySmarty.php
  80. +0
    -416
      libs/quickform/QuickForm/Renderer/Default.php
  81. +0
    -159
      libs/quickform/QuickForm/Renderer/QuickHtml.php
  82. +0
    -417
      libs/quickform/QuickForm/Renderer/TCMSArray.php
  83. +0
    -401
      libs/quickform/QuickForm/Renderer/TCMSArraySmarty.php
  84. +0
    -43
      libs/quickform/QuickForm/Renderer/TCMSDefault.js
  85. +0
    -515
      libs/quickform/QuickForm/Renderer/TCMSDefault.php
  86. +0
    -58
      libs/quickform/QuickForm/Rule.php
  87. +0
    -99
      libs/quickform/QuickForm/Rule/Callback.php
  88. +0
    -82
      libs/quickform/QuickForm/Rule/Compare.php
  89. +0
    -93
      libs/quickform/QuickForm/Rule/CompareString.php
  90. +0
    -49
      libs/quickform/QuickForm/Rule/Email.php
  91. +0
    -47
      libs/quickform/QuickForm/Rule/Range.php
  92. +0
    -80
      libs/quickform/QuickForm/Rule/Regex.php
  93. +0
    -39
      libs/quickform/QuickForm/Rule/Required.php
  94. +0
    -324
      libs/quickform/QuickForm/RuleRegistry.php
  95. +0
    -398
      libs/quickform/QuickForm/element.php
  96. +0
    -42
      libs/quickform/autocomplete_update.php
  97. +0
    -155
      libs/quickform/docs/elements.php
  98. +0
    -64
      libs/quickform/docs/filters.php
  99. +0
    -104
      libs/quickform/docs/formrule.php
  100. +0
    -96
      libs/quickform/docs/groups.php

+ 0
- 4
.babelrc View File

@@ -1,4 +0,0 @@
{
"presets": ["env"],
"plugins": ["transform-runtime", "transform-function-bind", "transform-class-properties"]
}

+ 0
- 10
.eslintrc.json View File

@@ -1,10 +0,0 @@
{
"extends": "airbnb-base",
"parser": "babel-eslint",
"env": {
"browser": true
},
"globals": {
"jQuery": true
}
}

+ 2
- 2
README.md View File

@@ -48,7 +48,7 @@ It requires properly configured HTTP server with PHP and MySQL or PostgreSQL dat

EPESI is released under the MIT License

Copyright © 2006-2016 Telaxus LLC
Copyright © 2006-2018 Telaxus LLC

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/orsell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

@@ -63,7 +63,7 @@ Telaxus LLC http://telaxus.com/
- Telaxus LLC is a technology company specializing in developoment of CRM and ERP solutions for small and medium size businesses utilizing our own platform - EPESI Business Information Manager.


<i>Copyright © 2006-2016 Telaxus LLC</i>
<i>Copyright © 2006-2018 Telaxus LLC</i>

Enjoy,
<b>EPESI Team</b>

+ 1
- 0
admin/modules/ConfigInfo.php View File

@@ -78,6 +78,7 @@ class ConfigInfo extends AdminModule {
$this->printTD('Set Session: ', (SET_SESSION ? 'YES' : 'NO'));

$this->printTD('Read Only Session: ', (READ_ONLY_SESSION ? 'YES' : 'NO'));
$this->printTD('Mobile Device: ', (MOBILE_DEVICE ? 'YES' : 'NO'));
$this->printTD('First Run: ', (FIRST_RUN ? 'YES' : 'NO'));
$this->printTD('Hosting Mode: ', (HOSTING_MODE ? 'YES' : 'NO'));
$this->printTD('Trial Mode: ', (TRIAL_MODE ? 'YES' : 'NO'));


+ 8
- 9
check.php View File

@@ -210,11 +210,11 @@ foreach ($checks as $c) {
$solution = false;
foreach ($c['tests'] as $t) {
switch ($t['severity']) {
case 0: $class = 'text-success'; break;
case 1: $class = 'text-warning'; $solution = true; break;
case 2: $class = 'text-danger'; $solution = true; break;
case 0: $color = '#00CC00'; break;
case 1: $color = '#CCAA00'; $solution = true; break;
case 2: $color = 'red'; $solution = true; break;
}
$html .= '<span style="font-weight:bold;float:right;" class="'.$class.'">'.$t['status'].'</span>';
$html .= '<span style="font-weight:bold;float:right;margin-right:100px;color:'.$color.'">'.$t['status'].'</span>';
$html .= '<span style="margin-left:40px;">'.$t['label'].'</span>';
$html .= '<br>';
}
@@ -228,12 +228,11 @@ foreach ($checks as $c) {
$html .= '<br><br>';
$html .= '<font size=-2>';
$html .= 'Legend:<br>';
$html .= '<div><span class="text-success">Green</span> - matches EPESI requirements</div>';
$html .= '<div><span class="text-warning">Yellow</span> - shouldn\'t prevent EPESI from running, but it\'s recommended to change the settings</div>';
$html .= '<div><span class="text-danger">Red</span> - check failed, it\'s necessary to change the settings</div>';
$html .= '<span style="color:#00CC00;">Green</span> - matches EPESI requirements<br>';
$html .= '<span style="color:#CCAA00;">Yellow</span> - shouldn\'t prevent EPESI from running, but it\'s recommended to change the settings<br>';
$html .= '<span style="color:red;">Red</span> - check failed, it\'s necessary to change the settings<br>';
$html .= '</font>';

print('<div class="col-md-6 col-md-offset-3"><div class="panel panel-default"><div class="panel-body">');
if ($fullscreen) {
if (class_exists('Utils_FrontPageCommon'))
Utils_FrontPageCommon::display('EPESI Compatibility check', $html);
@@ -242,5 +241,5 @@ if ($fullscreen) {
} else {
print($html);
}
print('</div></div></div>');
?>

+ 12
- 10
composer.json View File

@@ -8,20 +8,23 @@
"fzaninotto/faker": "^1.6",
"phpFastCache/phpFastCache": "^5.0",
"ifsnop/mysqldump-php": "dev-master",
"memio/memio": "^1.0",
"psy/psysh": "@stable",
"anahkiasen/underscore-php": "^2.0",
"moneyphp/money": "^3.0",
"enyo/dropzone": "@stable",
"ezyang/htmlpurifier": "^4.9",
"moneyphp/money": "^3.0"
"moneyphp/money": "^3.0",
"tecnickcom/tcpdf": "^6.2",
"memio/memio": "^2.0"
},
"scripts": {
"post-install-cmd": [
"@composer -d=\"modules/CRM/Mail\" install",
"@composer -d=\"modules/Libs/PHPExcel\" install",
"@composer -d=\"modules/Libs/TCPDF\" install"
]
"@composer -d\"modules/CRM/Mail\" install",
"@composer -d\"modules/Libs/PHPExcel\" install",
"@composer -d\"vendor/tecnickcom/tcpdf\" install",
"@composer -d\"vendor/tecnickcom/tcpdf\" dump-autoload"
],
"post-update-cmd": [
"@composer -d\"vendor/tecnickcom/tcpdf\" dump-autoload"
]
},
"autoload": {
"psr-4": {
@@ -30,8 +33,7 @@
},
"psr-0": {
"": "modules/"
},
"classmap": ["libs/quickform"]
}
},
"require-dev": {
"codeception/codeception": "*",


+ 1675
- 904
composer.lock
File diff suppressed because it is too large
View File


+ 0
- 1
console.php View File

@@ -27,7 +27,6 @@ $application->add(new \Epesi\Console\Modules\EnableModuleCommand());
$application->add(new \Epesi\Console\Modules\InstallModuleCommand());
$application->add(new \Epesi\Console\Modules\UninstallModuleCommand());
$application->add(new \Epesi\Console\Modules\EnableAllModuleCommand());
$application->add(new \Epesi\Console\Modules\RebuildModulesDatabaseCommand());
$application->add(new \Epesi\Console\CacheRebuildCommand());
$application->add(new \Epesi\Console\ThemeRebuildCommand());
$application->add(new \Epesi\Console\Maintenance\MaintenanceStatusCommand());


+ 7
- 7
console/Develop/CreateModuleCommand.php View File

@@ -10,7 +10,7 @@ use Symfony\Component\Console\Output\OutputInterface;

use Memio\Memio\Config\Build;
use Memio\Model\File;
use Memio\Model\Object;
use Memio\Model\Objekt;
use Memio\Model\Method;
use Memio\Model\Argument;

@@ -74,9 +74,9 @@ class CreateModuleCommand extends Command
$file_main = $module_dir . '/' . $core_name . '_0.php';
$myFile = File::make($file_main)
->setStructure(
Object::make($module_type)
Objekt::make($module_type)
->extend(
Object::make('Module'))
Objekt::make('Module'))
->addMethod(
Method::make('body')
)
@@ -91,9 +91,9 @@ class CreateModuleCommand extends Command
$file_common = $module_dir . '/' . $core_name . 'Common_0.php';
$myFile = File::make($file_common)
->setStructure(
Object::make($module_type . 'Common')
Objekt::make($module_type . 'Common')
->extend(
Object::make('ModuleCommon')
Objekt::make('ModuleCommon')
)
);

@@ -112,9 +112,9 @@ class CreateModuleCommand extends Command
$file_install = $module_dir . '/' . $core_name . 'Install.php';
$myFile = File::make($file_install)
->setStructure(
Object::make($module_type . 'Install')
Objekt::make($module_type . 'Install')
->extend(
Object::make('ModuleInstall'))
Objekt::make('ModuleInstall'))
->addMethod(
Method::make('install')
->setBody("{$t}{$t}return true;"))


+ 7
- 7
console/Develop/CreateTestModuleCommand.php View File

@@ -10,7 +10,7 @@ use Symfony\Component\Console\Output\OutputInterface;

use Memio\Memio\Config\Build;
use Memio\Model\File;
use Memio\Model\Object;
use Memio\Model\Objekt;
use Memio\Model\Method;
use Memio\Model\Argument;

@@ -66,9 +66,9 @@ class CreateTestModuleCommand extends Command
$file_main = $module_dir . '/' . $module_name . '_0.php';
$myFile = File::make($file_main)
->setStructure(
Object::make($module_type)
Objekt::make($module_type)
->extend(
Object::make('Module'))
Objekt::make('Module'))
->addMethod(
Method::make('body')
)
@@ -84,9 +84,9 @@ class CreateTestModuleCommand extends Command
$file_common = $module_dir . '/' . $module_name . 'Common_0.php';
$myFile = File::make($file_common)
->setStructure(
Object::make($module_type . 'Common')
Objekt::make($module_type . 'Common')
->extend(
Object::make('ModuleCommon')
Objekt::make('ModuleCommon')
)
->addMethod(
Method::make('menu')
@@ -108,9 +108,9 @@ class CreateTestModuleCommand extends Command
$file_install = $module_dir . '/' . $module_name . 'Install.php';
$myFile = File::make($file_install)
->setStructure(
Object::make($module_type . 'Install')
Objekt::make($module_type . 'Install')
->extend(
Object::make('ModuleInstall'))
Objekt::make('ModuleInstall'))
->addMethod(
Method::make('install')
->setBody("{$t}{$t}return true;"))


+ 0
- 32
console/Modules/RebuildModulesDatabaseCommand.php View File

@@ -1,32 +0,0 @@
<?php

namespace Epesi\Console\Modules;

use Symfony\Component\Console\Command\Command;
use Symfony\Component\Console\Helper\Table;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;

class RebuildModulesDatabaseCommand extends Command
{
protected function configure()
{
$this
->setName('module:rebuild')
->setDescription('Rebuild modules database')
;
}

protected function execute(InputInterface $input, OutputInterface $output)
{
$modules = \Base_SetupCommon::refresh_available_modules();

$table = new Table($output);
$table->setHeaders(array('<fg=white;options=bold>Name</fg=white;options=bold>', '<fg=white;options=bold>Version</fg=white;options=bold>'));
foreach ($modules as $name => $module) {
$table->addRow(array($name, $module[0]));
}

$table->render();
}
}

+ 0
- 6
crowdin.yml View File

@@ -1,6 +0,0 @@
files:
- source: '*/en.php'
translation: /folder/%two_letters_code%/%original_file_name%.%language%.old
languages_mapping:
two_letters_code:
en: .php

+ 0
- 0
dist/.gitkeep View File


+ 0
- 12
folder/nl/en.php.Dutch.old View File

@@ -1,12 +0,0 @@
<?php
/**
* Translation file.
* @package epesi-translations
* @subpackage en
*/
global $translations;
$translations['Projects']='';
$translations['Due Date']='';
$translations['Project Name']='';
$translations['Bugtrack']='';
$translations['Bug (attachment) #%d, %s']='';

+ 0
- 10
folder/no/en.php.Norwegian.old View File

@@ -1,10 +0,0 @@
<?php
/**
* Translation file.
* @package epesi-translations
* @subpackage en
*/
global $translations;
$translations['This text can be translated.']='';
$translations['Here you can have some numbers: %d, %d, %d but you can still translate whole text.']='';
$translations['Hello world!']='';

+ 0
- 2127
folder/ro/en.php.Romanian.old
File diff suppressed because it is too large
View File


BIN
images/epesi_logo_RGB_Solid.png View File

Before After
Width: 300  |  Height: 64  |  Size: 21 KiB

BIN
images/epesi_logo_RGB_Solid_login.png View File

Before After
Width: 600  |  Height: 128  |  Size: 31 KiB

BIN
images/favicon.png View File

Before After
Width: 16  |  Height: 16  |  Size: 1.4 KiB Width: 16  |  Height: 16  |  Size: 951 B

BIN
images/logo.png View File

Before After
Width: 550  |  Height: 200  |  Size: 45 KiB Width: 250  |  Height: 50  |  Size: 6.1 KiB

+ 0
- 1
include.php View File

@@ -37,7 +37,6 @@ try {
require_once('include/history.php');
require_once('include/patches.php');
require_once('include/simple_login.php');
require_once('include/fontawesome.php');
} catch (Exception $e) {
die($e->getMessage());
}

+ 1
- 0
include/config.php View File

@@ -45,6 +45,7 @@ if(!defined('TRACKING_CODE')) define('TRACKING_CODE','');
if(!defined('JS_OUTPUT')) define('JS_OUTPUT',0);
if(!defined('SET_SESSION')) define('SET_SESSION',1);
if(!defined('READ_ONLY_SESSION')) define('READ_ONLY_SESSION',0);
if(!defined('MOBILE_DEVICE')) define('MOBILE_DEVICE',0);
if(!defined('DIRECTION_RTL')) define('DIRECTION_RTL',0);

if(!defined('FIRST_RUN')) define('FIRST_RUN','FirstRun');


+ 3
- 3
include/epesi.php View File

@@ -326,8 +326,8 @@ class Epesi {
foreach($to_cleanup as $k) {
$mod = ModuleManager::get_instance($k);
if($mod === null) {
$xx = explode('__',$k);
$yy = explode('--',$xx[count($xx)-1]);
$xx = explode('/',$k);
$yy = explode('|',$xx[count($xx)-1]);
$mod = $yy[0];
if(is_callable(array($mod.'Common','destroy')))
call_user_func(array($mod.'Common','destroy'),$k,isset($_SESSION['client']['__module_vars__'][$k])?$_SESSION['client']['__module_vars__'][$k]:null);
@@ -434,7 +434,7 @@ class Epesi {
}
if(!isset($_SESSION['client']['custom_debug']) || $debug!=$_SESSION['client']['custom_debug']) {
self::text($debug,'debug');
if ($debug) Epesi::js("jq('#debug_content').show();");
if ($debug) Epesi::js("$('debug_content').style.display='block';");
$_SESSION['client']['custom_debug'] = $debug;
}



+ 2
- 2
include/error.php View File

@@ -27,8 +27,8 @@ class ErrorHandler {
chdir(dirname(dirname(__FILE__)));
Epesi::clean();
if(DISPLAY_ERRORS) {
Epesi::js("jq('#debug_content').show();");
Epesi::text('<pre>'.$buffer.'</pre><hr>','error_box','prepend');
Epesi::js("$('debug_content').style.display='block';");
Epesi::text('<pre>' . $buffer . '</pre><hr>','error_box','prepend');
}
Epesi::alert('There was an error in one of epesi modules.'.((DISPLAY_ERRORS)?' Details are displayed at the bottom of the page, please send this information to system administrator.':''));
return Epesi::get_output();


+ 0
- 15
include/fontawesome.php View File

@@ -1,15 +0,0 @@
<?php
/**
* @author Paul Bukowski <pbukowski@telaxus.com>
* @version 1.0
* @copyright Copyright &copy; 2017, Telaxus LLC
* @license SPL
* @package epesi-base
*/
defined("_VALID_ACCESS") || die('Direct access forbidden');
require_once(EPESI_LOCAL_DIR.'/libs/php-fontawesome.php');
class FontAwesome extends Smk_FontAwesome {
public static function get($class_prefix = 'fa-'){
return parent::getArray(EPESI_LOCAL_DIR.'/node_modules/font-awesome/css/font-awesome.css',$class_prefix);
}
}

+ 133
- 2
include/misc.php View File

@@ -316,7 +316,7 @@ function recalculate_time($date,$time) {
function escapeJS($str,$double=true,$single=true) {return Epesi::escapeJS($str,$double,$single);}

function get_epesi_url() {
if(defined('EPESI_URL')) return rtrim(EPESI_URL,'/');
if(defined('EPESI_URL')) return rtrim(EPESI_URL,'/') . '/';
if(php_sapi_name() == 'cli')
return dirname(dirname(__FILE__));
$protocol = (isset($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS'])!== "off") ? 'https://' : 'http://';
@@ -327,7 +327,7 @@ function get_epesi_url() {
$domain_name = $_SERVER['SERVER_NAME'];
}
$url = ($domain_name ? ($protocol . $domain_name) : '') . EPESI_DIR;
return trim($url);
return rtrim(trim($url), '/') . '/';
}

function get_client_ip_address()
@@ -386,6 +386,137 @@ function create_html_form(& $form_name, $action_url, $variables, $target = null,
return $html;
}

////////////////////////////////////////////////////
// mobile devices

function detect_mobile_device(){
// check if the user agent value claims to be windows but not windows mobile
if(stristr($_SERVER['HTTP_USER_AGENT'],'windows')&&!(stristr($_SERVER['HTTP_USER_AGENT'],'windows ce')||stristr($_SERVER['HTTP_USER_AGENT'],'windows mobile')||stristr($_SERVER['HTTP_USER_AGENT'],'palm'))){
return false;
}
// check if the user agent gives away any tell tale signs it's a mobile browser
if(preg_match('/up.browser|up.link|windows ce|iemobile|mini|mmp|symbian|midp|wap|phone|pocket|mobile|pda|psp|ppc|symbian/i',$_SERVER['HTTP_USER_AGENT'])){
return true;
}
// check the http accept header to see if wap.wml or wap.xhtml support is claimed
if(isset($_SERVER['HTTP_ACCEPT']) && (stristr($_SERVER['HTTP_ACCEPT'],'text/vnd.wap.wml')||stristr($_SERVER['HTTP_ACCEPT'],'application/vnd.wap.xhtml+xml'))){
return true;
}
// check if there are any tell tales signs it's a mobile device from the _server headers
if(isset($_SERVER['HTTP_X_WAP_PROFILE'])||isset($_SERVER['HTTP_PROFILE'])||isset($_SERVER['X-OperaMini-Features'])||isset($_SERVER['UA-pixels'])){
return true;
}
// build an array with the first four characters from the most common mobile user agents
$a = array(
'acs-'=>'acs-',
'alav'=>'alav',
'alca'=>'alca',
'amoi'=>'amoi',
'audi'=>'audi',
'aste'=>'aste',
'avan'=>'avan',
'benq'=>'benq',
'bird'=>'bird',
'blac'=>'blac',
'blaz'=>'blaz',
'brew'=>'brew',
'cell'=>'cell',
'cldc'=>'cldc',
'cmd-'=>'cmd-',
'dang'=>'dang',
'doco'=>'doco',
'eric'=>'eric',
'hipt'=>'hipt',
'inno'=>'inno',
'ipaq'=>'ipaq',
'java'=>'java',
'jigs'=>'jigs',
'kddi'=>'kddi',
'keji'=>'keji',
'leno'=>'leno',
'lg-c'=>'lg-c',
'lg-d'=>'lg-d',
'lg-g'=>'lg-g',
'lge-'=>'lge-',
'maui'=>'maui',
'maxo'=>'maxo',
'midp'=>'midp',
'mits'=>'mits',
'mmef'=>'mmef',
'mobi'=>'mobi',
'mot-'=>'mot-',
'moto'=>'moto',
'mwbp'=>'mwbp',
'nec-'=>'nec-',
'newt'=>'newt',
'noki'=>'noki',
'opwv'=>'opwv',
'palm'=>'palm',
'pana'=>'pana',
'pant'=>'pant',
'pdxg'=>'pdxg',
'phil'=>'phil',
'play'=>'play',
'pluc'=>'pluc',
'port'=>'port',
'prox'=>'prox',
'qtek'=>'qtek',
'qwap'=>'qwap',
'sage'=>'sage',
'sams'=>'sams',
'sany'=>'sany',
'sch-'=>'sch-',
'sec-'=>'sec-',
'send'=>'send',
'seri'=>'seri',
'sgh-'=>'sgh-',
'shar'=>'shar',
'sie-'=>'sie-',
'siem'=>'siem',
'smal'=>'smal',
'smar'=>'smar',
'sony'=>'sony',
'sph-'=>'sph-',
'symb'=>'symb',
't-mo'=>'t-mo',
'teli'=>'teli',
'tim-'=>'tim-',
'tosh'=>'tosh',
'treo'=>'treo',
'tsm-'=>'tsm-',
'upg1'=>'upg1',
'upsi'=>'upsi',
'vk-v'=>'vk-v',
'voda'=>'voda',
'wap-'=>'wap-',
'wapa'=>'wapa',
'wapi'=>'wapi',
'wapp'=>'wapp',
'wapr'=>'wapr',
'webc'=>'webc',
'winw'=>'winw',
'winw'=>'winw',
'xda-'=>'xda-'
);
// check if the first four characters of the current user agent are set as a key in the array
if(isset($a[substr($_SERVER['HTTP_USER_AGENT'],0,4)])){
return true;
}
}

function detect_iphone(){
if (!isset($_SERVER['HTTP_USER_AGENT'])) return false;
if(preg_match('/iphone/i',$_SERVER['HTTP_USER_AGENT'])||preg_match('/iPad/i',$_SERVER['HTTP_USER_AGENT'])||preg_match('/ipod/i',$_SERVER['HTTP_USER_AGENT'])||preg_match('/android/i',$_SERVER['HTTP_USER_AGENT'])||preg_match('/webOS/i',$_SERVER['HTTP_USER_AGENT'])){
return true;
}
return false;
}

if(detect_iphone())
define('IPHONE',1);
else
define('IPHONE',0);

////////////////////////////
// strip epesi invalid html code


+ 9
- 9
include/module.php View File

@@ -139,7 +139,7 @@ abstract class Module extends ModulePrimitive {
$this->children[$type] = array();
$this->children[$type][$instance] = & $ch;
if(DEBUG)
Epesi::debug('registering '.$this->get_path().'--'.$ch->get_node_id());
Epesi::debug('registering '.$this->get_path().'/'.$ch->get_node_id());
}

private final function get_new_child_instance_id($type) {
@@ -157,7 +157,7 @@ abstract class Module extends ModulePrimitive {
$x = false;
return $x;
}
$yy = explode('__',$id);
$yy = explode('|',$id);
return $this->children[$yy[0]][$yy[1]];
}

@@ -184,7 +184,7 @@ abstract class Module extends ModulePrimitive {
if($this->clear_child_vars) return;
$module_type = str_replace('/','_',$module_type);
if(!isset($name)) $name = $this->get_new_child_instance_id($module_type);
$this->frozen_modules[$module_type.'__'.$name] = 1;
$this->frozen_modules[$module_type.'|'.$name] = 1;
}

//endregion
@@ -840,7 +840,7 @@ abstract class Module extends ModulePrimitive {
* @param string $function_name function to call (get output from), if user has enought privileges.
* @return mixed if access denied returns false, else true
*/
public final function display_module(& $m, $args=null, $function_name = null, $template = null) {
public final function display_module(& $m, $args=null, $function_name = null) {
$ret = $this->get_html_of_module($m,$args,$function_name);
if($ret===false) return false;
print($ret);
@@ -873,7 +873,7 @@ abstract class Module extends ModulePrimitive {

if (!$m->check_access($function_name))
return false;
//we cannot trigger error here, because logout doesn't work
//we cannot trigger error here, couse logout doesn't work
//trigger_error('Method given as argument 2 for display_module inaccessible.<br>$'.$this->get_type().'->display_module(\''.$m->get_type().'\','.$args.',\''.$function_name.'\');',E_USER_ERROR);

$s = & $m->get_module_variable('__shared_unique_vars__',array());
@@ -887,7 +887,7 @@ abstract class Module extends ModulePrimitive {
$path = $m->get_path();
if($this->is_inline_display()) $m->set_inline_display();
if(!$m->is_inline_display()) {
Epesi::$content[$path]['span'] = $this_path.'__'.$this->children_count_display.'content';
Epesi::$content[$path]['span'] = $this_path.'|'.$this->children_count_display.'content';
$this->children_count_display++;
}
Epesi::$content[$path]['module'] = & $m;
@@ -1073,7 +1073,7 @@ abstract class Module extends ModulePrimitive {
*/
public final function get_node_id()
{
return $this->type_with_submodule . '__' . $this->instance;
return $this->type_with_submodule . '|' . $this->instance;
}

/**
@@ -1084,13 +1084,13 @@ abstract class Module extends ModulePrimitive {
*
* Example:
* Module named Base/Box, instance 1, without parents:
* get_path returns '--Base_Box-1'
* get_path returns '/Base_Box|1'
*
* @return string unique module name
*/
public final function get_path() {
if(!isset($this->path))
$this->path = $this->get_parent_path().'--'.$this->get_node_id();
$this->path = $this->get_parent_path().'/'.$this->get_node_id();
return $this->path;
}



+ 1
- 1
include/module_manager.php View File

@@ -755,7 +755,7 @@ class ModuleManager {
* @return bool null if module instance was not found, requested module object otherwise
*/
public static final function get_instance($path) {
$xx = explode('--',$path);
$xx = explode('/',$path);
$curr = self::$root;
if(is_object($curr) && $curr->get_node_id() != $xx[1]) {
$x = null;


+ 0
- 1
include/session.php View File

@@ -335,7 +335,6 @@ if(defined('EPESI_PROCESS')) {
} else {
ini_set('session.gc_probability', 0);
}
ini_set('session.save_handler', 'user');

session_set_save_handler(array('DBSession','open'),
array('DBSession','close'),


+ 2
- 0
include/simple_login.php View File

@@ -15,6 +15,8 @@ class SimpleLogin {
return self::t('You have exceeded the number of allowed login attempts.');
}

require_once('modules/Libs/QuickForm/requires.php');

if ((!Base_AclCommon::is_user()) && !$anonymous) {
Base_User_LoginCommon::autologin();
}


+ 128
- 180
index.php View File

@@ -7,7 +7,7 @@
* @author Paul Bukowski <pbukowski@telaxus.com>
* @copyright Copyright &copy; 2006, Telaxus LLC
* @license MIT
* @version 1.0
* @version 1.0
* @package epesi-base
*/
if(version_compare(phpversion(), '5.5.0')==-1)
@@ -17,7 +17,10 @@ if(trim(ini_get("safe_mode")))
die('You cannot use EPESI with PHP safe mode turned on - please disable it. Please notice this feature is deprecated since PHP 5.3 and will be removed in PHP 7.0.');

define('_VALID_ACCESS',1);
require_once('include/data_dir.php');
define('DATA_DIR','data'); // added by J. Tylek to remove map.php
// Default /data directory location is epesidir/data
// Must be defined here to read config.php

if(!file_exists(DATA_DIR.'/config.php')) {
header('Location: setup.php');
exit();
@@ -37,15 +40,51 @@ if(epesi_requires_update()) {
header('Location: update.php');
exit();
}



$tables = DB::MetaTables();
if(!in_array('modules',$tables) || !in_array('variables',$tables) || !in_array('session',$tables))
die('Database structure you are using is apparently out of date or damaged. If you didn\'t perform application update recently you should try to restore the database. Otherwise, please refer to EPESI documentation in order to perform database update.');

ob_start();

if(IPHONE) {
if(!isset($_GET['force_desktop'])) {
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<meta name="robots" content="NOINDEX, NOARCHIVE">
<meta id="viewport" name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;" />
<title><?php print(EPESI);?></title>
<link rel="stylesheet" href="libs/UiUIKit/stylesheets/iphone.css" />
<link rel="apple-touch-icon" href="images/apple-touch-icon.png" />
<script type="text/javascript" charset="utf-8">
window.onload = function() {
setTimeout(function(){window.scrollTo(0, 1);}, 100);
}
</script>
</head>

<body>
<div id="header">
<h1><?php print(EPESI);?></h1>
</div>

Please choose <?php print(EPESI);?> version:<ul>
<li><a href="mobile.php" class="white button">mobile</a><br>
<li><a href="index.php?force_desktop=1" class="green button">desktop</a>
</ul>

</body>
</html>
<?php
exit();
}
} elseif(detect_mobile_device()) {
header('Location: mobile.php');
exit();
}

?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
@@ -56,195 +95,101 @@ ob_start();
<title><?php print(EPESI);?></title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="SKYPE_TOOLBAR" content="SKYPE_TOOLBAR_PARSER_COMPATIBLE" />
<meta name="SKYPE_TOOLBAR" content="SKYPE_TOOLBAR_PARSER_COMPATIBLE" />
<meta name="robots" content="NOINDEX, NOARCHIVE">
<script type='text/javascript' src='dist/index.js'></script>
<link href='dist/styles.css' rel="stylesheet" type="text/css">
<style type="text/css">

#epesi_loader {
font-weight: 300;
font-size: 15px;
background-color: white;
position: fixed;
left: 50%;
top: 30%;
margin-left: -180px;
width: 360px;
text-align: center;
vertical-align: middle;
z-index: 2002;
overflow: hidden;
padding-top: 20px;
}
#epesi_loader img {
padding: 15px;
}

#epesi_loader .text {
margin-top: 10px;
margin-bottom: 25px;
font-size: 22px;
}

#epesi_loader .spinner {
margin: 20px auto 20px;
text-align: center;
}

#epesi_loader .spinner > div {
width: 18px;
height: 18px;
background-color: #333;

border-radius: 100%;
display: inline-block;
-webkit-animation: sk-bouncedelay 1.4s infinite ease-in-out both;
animation: sk-bouncedelay 1.4s infinite ease-in-out both;
}

#epesi_loader .spinner .bounce1 {
-webkit-animation-delay: -0.32s;
animation-delay: -0.32s;
}

#epesi_loader .spinner .bounce2 {
-webkit-animation-delay: -0.16s;
animation-delay: -0.16s;
}

@-webkit-keyframes sk-bouncedelay {
0%, 80%, 100% { -webkit-transform: scale(0) }
40% { -webkit-transform: scale(1.0) }
}

@keyframes sk-bouncedelay {
0%, 80%, 100% {
-webkit-transform: scale(0);
transform: scale(0);
} 40% {
-webkit-transform: scale(1.0);
transform: scale(1.0);
}
}





.Base_StatusBar_background {
z-index: 2001;
position: fixed;
top: 0px;
left: 0px;
width: 100%;
height: 100%;
text-align: center;
vertical-align: middle;
background-color: rgba(255, 255, 255, 0.5);
}

.Base_StatusBar {
background-color: white;
position: fixed;
left: 50%;
top: 30%;
margin-left: -100px;
width: 200px;
text-align: center;
vertical-align: middle;
z-index: 2002;
overflow: hidden;
padding-top: 20px;
}

.Base_StatusBar .text {
font-size: 22px;
}

.Base_StatusBar .spinner {
margin: 20px auto 20px;
text-align: center;
}

.Base_StatusBar .spinner > div {
width: 18px;
height: 18px;
background-color: #333;

border-radius: 100%;
display: inline-block;
-webkit-animation: sk-bouncedelay 1.4s infinite ease-in-out both;
animation: sk-bouncedelay 1.4s infinite ease-in-out both;
}

.Base_StatusBar .spinner .bounce1 {
-webkit-animation-delay: -0.32s;
animation-delay: -0.32s;
}

.Base_StatusBar .spinner .bounce2 {
-webkit-animation-delay: -0.16s;
animation-delay: -0.16s;
}

@-webkit-keyframes sk-bouncedelay {
0%, 80%, 100% { -webkit-transform: scale(0) }
40% { -webkit-transform: scale(1.0) }
}

@keyframes sk-bouncedelay {
0%, 80%, 100% {
-webkit-transform: scale(0);
transform: scale(0);
} 40% {
-webkit-transform: scale(1.0);
transform: scale(1.0);
}
}

</style>
<?php
ini_set('include_path', 'libs/minify' . PATH_SEPARATOR . '.' . PATH_SEPARATOR . 'libs' . PATH_SEPARATOR . ini_get('include_path'));
require_once('Minify/Build.php');
$jquery = DEBUG_JS ? 'libs/jquery-1.11.3.js' : 'libs/jquery-1.11.3.min.js';
$jquery_migrate = DEBUG_JS ? 'libs/jquery-migrate-1.2.1.js' : 'libs/jquery-migrate-1.2.1.min.js';
$jses = array('libs/prototype.js', $jquery, $jquery_migrate, 'libs/jquery-ui-1.10.1.custom.min.js', 'libs/HistoryKeeper.js', 'include/epesi.js');
if(!DEBUG_JS) {
$jsses_build = new Minify_Build($jses);
$jsses_src = $jsses_build->uri('serve.php?' . http_build_query(array('f' => array_values($jses))));
echo("<script type='text/javascript' src='$jsses_src'></script>");
} else {
foreach($jses as $js)
print("<script type='text/javascript' src='$js'></script>");
}
$csses = array('libs/jquery-ui-1.10.1.custom.min.css');
$csses_build = new Minify_Build($csses);
$csses_src = $csses_build->uri('serve.php?'.http_build_query(array('f'=>array_values($csses))));
?>
<link type="text/css" href="<?php print($csses_src)?>" rel="stylesheet"></link>

<style type="text/css">
<?php if (DIRECTION_RTL) print('body { direction: rtl; }'); ?>
#epesiStatus {
/* Netscape 4, IE 4.x-5.0/Win and other lesser browsers will use this */
position: fixed;
left: 50%; top: 30%;
margin-left: -280px;
/* all */
/*background-color: #e6ecf2;*/
background-color: white;
border: 5px solid #336699;
visibility: hidden;
width: 560px;
text-align: center;
vertical-align: middle;
z-index: 2002;
color: #336699;
overflow: hidden;
/* css3 shadow border*/
-webkit-box-shadow: 1px 1px 15px black;
-moz-box-shadow: 1px 1px 15px black;
box-shadow: 1px 1px 15px black;
/* end css3 shadow border*/
/* border radius */
-webkit-border-radius: 6px;
-moz-border-radius: 6px;
border-radius: 6px;
/* end border radius */
}
#epesiStatus table {
color: #336699;
font-weight: bold;
font-family: Tahoma, Verdana, Vera-Sans, DejaVu-Sans;
font-size: 11px;
border: 5px solid #FFFFFF;
}

</style>
<?php print(TRACKING_CODE); ?>
</head>
<body class="<?php if (DIRECTION_RTL) print(' epesi_rtl'); ?>" >
<body <?php if (DIRECTION_RTL) print('class="epesi_rtl"'); ?> >

<div id="body_content" class="page">
<div id="main_content" class="page-main" style="display:none;"></div>
<div id="body_content">
<div id="main_content" style="display:none;"></div>
<div id="debug_content" style="padding-top:97px;display:none;">
<div class="button" onclick="jq('#error_box').html('');jq('#debug_content').hide();">Hide</div>
<div class="button" onclick="$('error_box').innerHTML='';$('debug_content').style.display='none';">Hide</div>
<div id="debug"></div>
<div id="error_box"></div>
</div>

<div id="epesi_loader" class="panel panel-default">
<img src="images/epesi_logo_RGB_Solid.png">
<div class="lead text" id="epesiStatusText"><?php print(STARTING_MESSAGE);?></div>
<div class="spinner">
<div class="bounce1"></div>
<div class="bounce2"></div>
<div class="bounce3"></div>
</div>
</div>
<div id="Base_StatusBar" class="Base_StatusBar_background">
<div class="Base_StatusBar panel panel-default">
<p id="statusbar_text" class="lead">Loading...</p>
<div class="spinner">
<div class="bounce1"></div>
<div class="bounce2"></div>
<div class="bounce3"></div>
</div>
<div id="dismiss">Click anywhere to dismiss</div>
</div>
</div>
<div id="epesiStatus">
<table cellspacing="0" cellpadding="0" border="0" style="width: 100%;">
<tr>
<td><img src="images/logo.png" alt="logo" width="550" height="200" border="0"></td>
</tr>
<tr>
<td style="text-align: center; vertical-align: middle; height: 30px;"><span id="epesiStatusText"><?php print(STARTING_MESSAGE);?></span></td>
</tr>
<tr>
<td style="text-align: center; vertical-align: middle; height: 30px;"><img src="images/loader.gif" alt="loader" width="256" height="10" border="0"></td>
</tr>
</table>
</div>
</div>
<?php
<?php
/*
* init_js file allows only num_of_clients sessions. If there is image
* with empty src="" browser will load index.php file, so we cannot
* include init_js file directly because num_of_clients request will
* reset our history and restart EPESI.
*
*
* Check here if request accepts html. If it does we can assume that
* this is request for page and include init_js file which is faster.
* If there is not 'html' in accept use script with src property.
@@ -255,6 +200,9 @@ ob_start();
<script type="text/javascript" src="init_js.php?<?php print(http_build_query($_GET));?>"></script>
<?php } ?>
<noscript>Please enable JavaScript in your browser and let <?php print(EPESI);?> work!</noscript>
<?php if(IPHONE) { ?>
<script type="text/javascript">var iphone=true;</script>
<?php } ?>
</body>
</html>
<?php


+ 1
- 1
init_js.php View File

@@ -35,4 +35,4 @@ if($client_id-5>=0) {
}
session_commit();

?>window.Epesi = new EpesiClass(<?php print($client_id); ?>,'<?php print(rtrim(str_replace('\\','/',dirname($_SERVER['PHP_SELF'])),'/').'/process.php'); ?>','<?php print(http_build_query($_GET));?>');
?>Epesi.init(<?php print($client_id); ?>,'<?php print(rtrim(str_replace('\\','/',dirname($_SERVER['PHP_SELF'])),'/').'/process.php'); ?>','<?php print(http_build_query($_GET));?>');

+ 0
- 5
libs/bootstrap-datetimepicker.min.css
File diff suppressed because it is too large
View File


+ 0
- 2
libs/bootstrap-datetimepicker.min.js
File diff suppressed because it is too large
View File


BIN
libs/images/ui-icons_444444_256x240.png View File

Before After
Width: 256  |  Height: 240  |  Size: 6.8 KiB

BIN
libs/images/ui-icons_555555_256x240.png View File

Before After
Width: 256  |  Height: 240  |  Size: 6.8 KiB

BIN
libs/images/ui-icons_777620_256x240.png View File

Before After
Width: 256  |  Height: 240  |  Size: 4.4 KiB

BIN
libs/images/ui-icons_777777_256x240.png View File

Before After
Width: 256  |  Height: 240  |  Size: 6.8 KiB

BIN
libs/images/ui-icons_cc0000_256x240.png View File

Before After
Width: 256  |  Height: 240  |  Size: 4.4 KiB

BIN
libs/images/ui-icons_ffffff_256x240.png View File

Before After
Width: 256  |  Height: 240  |  Size: 6.2 KiB

+ 0
- 117
libs/jquery.clonePosition.js View File

@@ -1,117 +0,0 @@
(function($){

function setOffset(el, newOffset){
var $el = $(el);

// get the current css position of the element
var cssPosition = $el.css('position');

// whether or not element is hidden
var hidden = false;

// if element was hidden, show it
if($el.css('display') == 'none'){
hidden = true;
$el.show();
}

// get the current offset of the element
var curOffset = $el.offset();

// if there is no current jQuery offset, give up
if(!curOffset){
// if element was hidden, hide it again
if(hidden)
$el.hide();
return;
}

// set position to relative if it's static
if (cssPosition == 'static') {
$el.css('position', 'relative');
cssPosition = 'relative';
}

// get current 'left' and 'top' values from css
// this is not necessarily the same as the jQuery offset
var delta = {
left : parseInt($el.css('left'), 10),
top: parseInt($el.css('top'), 10)
};

// if the css left or top are 'auto', they aren't numbers
if (isNaN(delta.left)){
delta.left = (cssPosition == 'relative') ? 0 : el.offsetLeft;
}
if (isNaN(delta.top)){
delta.top = (cssPosition == 'relative') ? 0 : el.offsetTop;
}

if (newOffset.left || 0 === newOffset.left){
$el.css('left', newOffset.left - curOffset.left + delta.left + 'px');
}
if (newOffset.top || 0 === newOffset.top){
$el.css('top', newOffset.top - curOffset.top + delta.top + 'px');
}

// if element was hidden, hide it again
if(hidden)
$el.hide();
}

$.fn.extend({

/**
* Store the original version of offset(), so that we don't lose it
*/
_offset : $.fn.offset,

/**
* Set or get the specific left and top position of the matched
* elements, relative the the browser window by calling setXY
* @param {Object} newOffset
*/
offset : function(newOffset){
return !newOffset ? this._offset() : this.each(function(){
setOffset(this, newOffset);
});
}
});

$.fn.clonePosition = function(element, options){
var options = $.extend({
cloneWidth: true,
cloneHeight: true,
offsetLeft: 0,
offsetTop: 0
}, (options || {}));

var offsets = $(element).offset();

$(this).offset({top: (offsets.top + options.offsetTop),
left: (offsets.left + options.offsetLeft)});

if (options.cloneWidth) $(this).width($(element).width());
if (options.cloneHeight) $(this).height($(element).height());

return this;
}
$.fn.absolutize = function() {
element = $(this);

if (element.css('position') == 'absolute') {
return element;
}

element.css({
position: 'absolute',
top: element.offset().top + 'px',
left: element.offset().left + 'px',
width: element.width() + 'px',
height: element.height() + 'px'
});

return this;
}
})(jQuery);

+ 0
- 1216
libs/moment-with-locales.min.js
File diff suppressed because it is too large
View File


+ 0
- 127
libs/php-fontawesome.php View File

@@ -1,127 +0,0 @@
<?php
/*
* SMK Font Awesome
*
* Get font awesome class names in an array or json format.
*
* -------------------------------------------------------------------------------------
* @Author: Smartik
* @Author URI: http://smartik.ws/
* @Copyright: (c) 2014 Smartik. All rights reserved
* @License: MIT
* -------------------------------------------------------------------------------------
*
*
*/
if( ! class_exists('Smk_FontAwesome') ){
class Smk_FontAwesome{

/**
* Font Awesome
*
* @param string $path font awesome css file path
* @param string $class_prefix change this if the class names does not start with `fa-`
* @return array
*/
public static function getArray($path, $class_prefix = 'fa-'){

if( ! file_exists($path) )
return false;//if path is incorect or file does not exist, stop.

$css = file_get_contents($path);
$pattern = '/\.('. $class_prefix .'(?:\w+(?:-)?)+):before\s+{\s*content:\s*"(.+)";\s+}/';

preg_match_all($pattern, $css, $matches, PREG_SET_ORDER);

$icons = array();
foreach ($matches as $match) {
$icons[$match[1]] = $match[2];
}
return $icons;

}

//------------------------------------//--------------------------------------//

/**
* Sort array by key name
*
* @param array $array font awesome array. Create it using `getArray` method
* @return array
*/
public function sortByName($array){

if( ! is_array($array) )
return false;//Do not proceed if is not array

ksort( $array );
return $array;

}

//------------------------------------//--------------------------------------//

/**
* Get only HTML class key(class) => value(class)
*
* @param array $array font awesome array. Create it using `getArray` method
* @return array
*/
public function onlyClass($array){

if( ! is_array($array) )
return false;//Do not proceed if is not array

$temp = array();
foreach ($array as $class => $unicode) {
$temp[$class] = $class;
}
return $temp;

}

//------------------------------------//--------------------------------------//

/**
* Get only the unicode key
*
* @param array $array font awesome array. Create it using `getArray` method
* @return array
*/
public function onlyUnicode($array){

if( ! is_array($array) )
return false;//Do not proceed if is not array

$temp = array();
foreach ($array as $class => $unicode) {
$temp[$unicode] = $unicode;
}
return $temp;

}

//------------------------------------//--------------------------------------//

/**
* Readable class name. Ex: fa-video-camera => Video Camera
*
* @param array $array font awesome array. Create it using `getArray` method
* @param string $class_prefix change this if the class names does not start with `fa-`
* @return array
*/
public function readableName($array, $class_prefix = 'fa-'){

if( ! is_array($array) )
return false;//Do not proceed if is not array

$temp = array();
foreach ($array as $class => $unicode) {
$temp[$class] = ucfirst( str_ireplace(array($class_prefix, '-'), array('', ' '), $class) );
}
return $temp;

}

}//class
}//class_exists

+ 0
- 4
libs/quickform/.gitignore View File

@@ -1,4 +0,0 @@
# composer related
composer.lock
composer.phar
vendor

+ 0
- 290
libs/quickform/Common.php View File

@@ -1,290 +0,0 @@
<?php
/**
* Base class for all HTML classes
*
* @package HTML_Common
* @author Adam Daniel <adaniel1@eesus.jnj.com>
* @copyright 2001-2009 The PHP Group
* @license http://www.php.net/license/3_01.txt PHP License 3.01
*/

/**
* Base class for all HTML classes
*
* @package HTML_Common
* @author Adam Daniel <adaniel1@eesus.jnj.com>
*/
abstract class HTML_Common
{
/**
* Associative array of attributes
*
* @var array
* @access private
*/
var $_attributes = array();

/**
* Class constructor
*
* @param mixed $attributes Associative array of table tag attributes or HTML attributes name="value" pairs
*/
public function __construct($attributes = null)
{
$this->setAttributes($attributes);
}

/**
* Returns the current API version
*
* @returns double
*/
public function apiVersion()
{
return 1.7;
}

/**
* Returns an HTML formatted attribute string
*
* @param array $attributes
* @return string
* @access private
*/
function _getAttrString($attributes)
{
$strAttr = '';

if (is_array($attributes)) {
$charset = self::charset();
foreach ($attributes as $key => $value) {
$strAttr .= ' ' . $key . '="' . htmlspecialchars($value, ENT_COMPAT, $charset) . '"';
}
}
return $strAttr;
}

/**
* Returns a valid atrributes array from either a string or array
*
* @param mixed $attributes Either a typical HTML attribute string or an associative array
* @access private
* @return array
*/
function _parseAttributes($attributes)
{
if (is_array($attributes)) {
$ret = array();
foreach ($attributes as $key => $value) {
if (is_int($key)) {
$key = $value = strtolower($value);
} else {
$key = strtolower($key);
}
$ret[$key] = $value;
}
return $ret;

} elseif (is_string($attributes)) {
$preg = "/(([A-Za-z_:]|[^\\x00-\\x7F])([A-Za-z0-9_:.-]|[^\\x00-\\x7F])*)" .
"([ \\n\\t\\r]+)?(=([ \\n\\t\\r]+)?(\"[^\"]*\"|'[^']*'|[^ \\n\\t\\r]*))?/";
if (preg_match_all($preg, $attributes, $regs)) {
for ($counter=0; $counter<count($regs[1]); $counter++) {
$name = $regs[1][$counter];
$check = $regs[0][$counter];
$value = $regs[7][$counter];
if (trim($name) == trim($check)) {
$arrAttr[strtolower(trim($name))] = strtolower(trim($name));
} else {
if (substr($value, 0, 1) == "\"" || substr($value, 0, 1) == "'") {
$arrAttr[strtolower(trim($name))] = substr($value, 1, -1);
} else {
$arrAttr[strtolower(trim($name))] = trim($value);
}
}
}
return $arrAttr;
}
}
}

/**
* Returns the array key for the given non-name-value pair attribute
*
* @param string $attr Attribute
* @param array $attributes Array of attribute
* @since 1.0
* @access private
* @return bool
*/
function _getAttrKey($attr, $attributes)
{
if (isset($attributes[strtolower($attr)])) {
return true;
} else {
return null;
}
}

/**
* Updates the attributes in $attr1 with the values in $attr2 without changing the other existing attributes
*
* @param array $attr1 Original attributes array
* @param array $attr2 New attributes array
* @access private
* @return bool
*/
function _updateAttrArray(&$attr1, $attr2)
{
if (!is_array($attr2)) {
return false;
}
foreach ($attr2 as $key => $value) {
$attr1[$key] = $value;
}
}

/**
* Removes the given attribute from the given array
*
* @param string $attr Attribute name
* @param array $attributes Attribute array
* @access private
* @return void
*/
function _removeAttr($attr, &$attributes)
{
$attr = strtolower($attr);
if (isset($attributes[$attr])) {
unset($attributes[$attr]);
}
}

/**
* Returns the value of the given attribute
*
* @param string $attr Attribute name
* @return string|null returns null if an attribute does not exist
*/
public function getAttribute($attr)
{
$attr = strtolower($attr);
if (isset($this->_attributes[$attr])) {
return $this->_attributes[$attr];
}
return null;
}

/**
* Sets the value of the attribute
*
* @param string $name Attribute name
* @param string $value Attribute value (will be set to $name if omitted)
*/
public function setAttribute($name, $value = null)
{
$name = strtolower($name);
if (is_null($value)) {
$value = $name;
}
$this->_attributes[$name] = $value;
}

/**
* Sets the HTML attributes
*
* @param mixed $attributes Either a typical HTML attribute string or an associative array
*/
public function setAttributes($attributes)
{
$this->_attributes = $this->_parseAttributes($attributes);
}

/**
* Returns the assoc array (default) or string of attributes
*
* @param bool $asString Whether to return the attributes as string
* @return mixed attributes
*/
public function getAttributes($asString = false)
{
if ($asString) {
return $this->_getAttrString($this->_attributes);
} else {
return $this->_attributes;
}
}

/**
* Updates the passed attributes without changing the other existing attributes
*
* @param mixed $attributes Either a typical HTML attribute string or an associative array
*/
function updateAttributes($attributes)
{
$this->_updateAttrArray($this->_attributes, $this->_parseAttributes($attributes));
}

/**
* Removes an attribute
*
* @param string $attr Attribute name
*/
public function removeAttribute($attr)
{
$this->_removeAttr($attr, $this->_attributes);
}

/**
* Abstract method. Must be extended to return the objects HTML
*
* @return string
*/
abstract function toHtml();

/**
* Displays the HTML to the screen
*/
public function display()
{
print $this->toHtml();
}

/**
* Sets the charset to use by htmlspecialchars() function
*
* Since this parameter is expected to be global, the function is designed
* to be called statically:
* <code>
* HTML_Common::charset('utf-8');
* </code>
* or
* <code>
* $charset = HTML_Common::charset();
* </code>
*
* @param string $newCharset New charset to use. Omit if just getting the current value. Consult the htmlspecialchars() docs for a list of supported character sets.
* @return string Current charset
*/
public static function charset($newCharset = null)
{
static $charset = 'ISO-8859-1';

if (!is_null($newCharset)) {
$charset = $newCharset;
}
return $charset;
}

public function addClass($addClass)
{
$class = $this->getAttribute('class');
if($class != null) {
$class = $class.' '.$addClass;
} else {
$class = $addClass;
}
$this->setAttribute('class', $class);
}
}
?>

+ 0
- 1712
libs/quickform/QuickForm.php
File diff suppressed because it is too large
View File


+ 0
- 32
libs/quickform/QuickForm/Error.php View File

@@ -1,32 +0,0 @@
<?php
/**
* Class for errors thrown by HTML_QuickForm package
*
* @package HTML_QuickForm
* @author Adam Daniel <adaniel1@eesus.jnj.com>
* @author Bertrand Mansion <bmansion@mamasam.com>
*/
class HTML_QuickForm_Error extends Exception
{
/**
* Prefix for all error messages
* @var string
*/
var $error_message_prefix = 'QuickForm Error: ';

/**
* Creates a quickform error exception
*
* @param string $message The error message
* @param int $code The error code
* @throws self
*/
function __construct($message, $code = QUICKFORM_ERROR)
{
if (is_int($code)) {
parent::__construct(HTML_QuickForm::errorMessage($code) . ': ' . $message, $code);
} else {
throw new self("Invalid error code: $code", QUICKFORM_ERROR, $this);
}
}
}

+ 0
- 490
libs/quickform/QuickForm/Field/Group/date.php View File

@@ -1,490 +0,0 @@
<?php
/**
* @package HTML_QuickForm
* @author Alexey Borzov <avb@php.net>
* @copyright 2001-2011 The PHP Group
* @license http://www.php.net/license/3_01.txt PHP License 3.01
*/

/**
* Class for a group of elements used to input dates (and times).
*
* Inspired by original 'date' element but reimplemented as a subclass
* of HTML_QuickForm_group
*
* @package HTML_QuickForm
* @author Alexey Borzov <avb@php.net>
*/
class HTML_QuickForm_date extends HTML_QuickForm_group
{
/**
* Various options to control the element's display.
*
* @access private
* @var array
*/
var $_options = array(
'language' => 'en',
'format' => 'dMY',
'minYear' => 2001,
'maxYear' => null, // set in the constructor
'addEmptyOption' => false,
'emptyOptionValue' => '',
'emptyOptionText' => '&nbsp;',
'optionIncrement' => array('i' => 1, 's' => 1)
);

/**
* These complement separators, they are appended to the resultant HTML
* @access private
* @var array
*/
var $_wrap = array('', '');

/**
* Options in different languages
*
* Note to potential translators: to avoid encoding problems please send
* your translations with "weird" letters encoded as HTML Unicode entities
*
* @access private
* @var array
*/
var $_locale = array(
'en' => array (
'weekdays_short'=> array ('Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'),
'weekdays_long' => array ('Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'),
'months_short' => array ('Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'),
'months_long' => array ('January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December')
),
'de' => array (
'weekdays_short'=> array ('So', 'Mon', 'Di', 'Mi', 'Do', 'Fr', 'Sa'),
'weekdays_long' => array ('Sonntag', 'Montag', 'Dienstag', 'Mittwoch', 'Donnerstag', 'Freitag', 'Samstag'),
'months_short' => array ('Jan', 'Feb', 'M&#xe4;rz', 'April', 'Mai', 'Juni', 'Juli', 'Aug', 'Sept', 'Okt', 'Nov', 'Dez'),
'months_long' => array ('Januar', 'Februar', 'M&#xe4;rz', 'April', 'Mai', 'Juni', 'Juli', 'August', 'September', 'Oktober', 'November', 'Dezember')
),
'fr' => array (
'weekdays_short'=> array ('Dim', 'Lun', 'Mar', 'Mer', 'Jeu', 'Ven', 'Sam'),
'weekdays_long' => array ('Dimanche', 'Lundi', 'Mardi', 'Mercredi', 'Jeudi', 'Vendredi', 'Samedi'),
'months_short' => array ('Jan', 'F&#xe9;v', 'Mar', 'Avr', 'Mai', 'Juin', 'Juil', 'Ao&#xfb;t', 'Sep', 'Oct', 'Nov', 'D&#xe9;c'),
'months_long' => array ('Janvier', 'F&#xe9;vrier', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Ao&#xfb;t', 'Septembre', 'Octobre', 'Novembre', 'D&#xe9;cembre')
),
'hu' => array (
'weekdays_short'=> array ('V', 'H', 'K', 'Sze', 'Cs', 'P', 'Szo'),
'weekdays_long' => array ('vas&#xe1;rnap', 'h&#xe9;tf&#x151;', 'kedd', 'szerda', 'cs&#xfc;t&#xf6;rt&#xf6;k', 'p&#xe9;ntek', 'szombat'),
'months_short' => array ('jan', 'feb', 'm&#xe1;rc', '&#xe1;pr', 'm&#xe1;j', 'j&#xfa;n', 'j&#xfa;l', 'aug', 'szept', 'okt', 'nov', 'dec'),
'months_long' => array ('janu&#xe1;r', 'febru&#xe1;r', 'm&#xe1;rcius', '&#xe1;prilis', 'm&#xe1;jus', 'j&#xfa;nius', 'j&#xfa;lius', 'augusztus', 'szeptember', 'okt&#xf3;ber', 'november', 'december')
),
'pl' => array (
'weekdays_short'=> array ('Nie', 'Pn', 'Wt', '&#x15a;r', 'Czw', 'Pt', 'Sob'),
'weekdays_long' => array ('Niedziela', 'Poniedzia&#x142;ek', 'Wtorek', '&#x15a;roda', 'Czwartek', 'Pi&#x105;tek', 'Sobota'),
'months_short' => array ('Sty', 'Lut', 'Mar', 'Kwi', 'Maj', 'Cze', 'Lip', 'Sie', 'Wrz', 'Pa&#x17a;', 'Lis', 'Gru'),
'months_long' => array ('Stycze&#x144;', 'Luty', 'Marzec', 'Kwiecie&#x144;', 'Maj', 'Czerwiec', 'Lipiec', 'Sierpie&#x144;', 'Wrzesie&#x144;', 'Pa&#x17a;dziernik', 'Listopad', 'Grudzie&#x144;')
),
'sl' => array (
'weekdays_short'=> array ('Ned', 'Pon', 'Tor', 'Sre', 'Cet', 'Pet', 'Sob'),
'weekdays_long' => array ('Nedelja', 'Ponedeljek', 'Torek', 'Sreda', 'Cetrtek', 'Petek', 'Sobota'),
'months_short' => array ('Jan', 'Feb', 'Mar', 'Apr', 'Maj', 'Jun', 'Jul', 'Avg', 'Sep', 'Okt', 'Nov', 'Dec'),
'months_long' => array ('Januar', 'Februar', 'Marec', 'April', 'Maj', 'Junij', 'Julij', 'Avgust', 'September', 'Oktober', 'November', 'December')
),
'ru' => array (
'weekdays_short'=> array ('&#x412;&#x441;', '&#x41f;&#x43d;', '&#x412;&#x442;', '&#x421;&#x440;', '&#x427;&#x442;', '&#x41f;&#x442;', '&#x421;&#x431;'),
'weekdays_long' => array ('&#x412;&#x43e;&#x441;&#x43a;&#x440;&#x435;&#x441;&#x435;&#x43d;&#x44c;&#x435;', '&#x41f;&#x43e;&#x43d;&#x435;&#x434;&#x435;&#x43b;&#x44c;&#x43d;&#x438;&#x43a;', '&#x412;&#x442;&#x43e;&#x440;&#x43d;&#x438;&#x43a;', '&#x421;&#x440;&#x435;&#x434;&#x430;', '&#x427;&#x435;&#x442;&#x432;&#x435;&#x440;&#x433;', '&#x41f;&#x44f;&#x442;&#x43d;&#x438;&#x446;&#x430;', '&#x421;&#x443;&#x431;&#x431;&#x43e;&#x442;&#x430;'),
'months_short' => array ('&#x42f;&#x43d;&#x432;', '&#x424;&#x435;&#x432;', '&#x41c;&#x430;&#x440;', '&#x410;&#x43f;&#x440;', '&#x41c;&#x430;&#x439;', '&#x418;&#x44e;&#x43d;', '&#x418;&#x44e;&#x43b;', '&#x410;&#x432;&#x433;', '&#x421;&#x435;&#x43d;', '&#x41e;&#x43a;&#x442;', '&#x41d;&#x43e;&#x44f;', '&#x414;&#x435;&#x43a;'),
'months_long' => array ('&#x42f;&#x43d;&#x432;&#x430;&#x440;&#x44c;', '&#x424;&#x435;&#x432;&#x440;&#x430;&#x43b;&#x44c;', '&#x41c;&#x430;&#x440;&#x442;', '&#x410;&#x43f;&#x440;&#x435;&#x43b;&#x44c;', '&#x41c;&#x430;&#x439;', '&#x418;&#x44e;&#x43d;&#x44c;', '&#x418;&#x44e;&#x43b;&#x44c;', '&#x410;&#x432;&#x433;&#x443;&#x441;&#x442;', '&#x421;&#x435;&#x43d;&#x442;&#x44f;&#x431;&#x440;&#x44c;', '&#x41e;&#x43a;&#x442;&#x44f;&#x431;&#x440;&#x44c;', '&#x41d;&#x43e;&#x44f;&#x431;&#x440;&#x44c;', '&#x414;&#x435;&#x43a;&#x430;&#x431;&#x440;&#x44c;')
),
'es' => array (
'weekdays_short'=> array ('Dom', 'Lun', 'Mar', 'Mi&#xe9;', 'Jue', 'Vie', 'S&#xe1;b'),
'weekdays_long' => array ('Domingo', 'Lunes', 'Martes', 'Mi&#xe9;rcoles', 'Jueves', 'Viernes', 'S&#xe1;bado'),
'months_short' => array ('Ene', 'Feb', 'Mar', 'Abr', 'May', 'Jun', 'Jul', 'Ago', 'Sep', 'Oct', 'Nov', 'Dic'),
'months_long' => array ('Enero', 'Febrero', 'Marzo', 'Abril', 'Mayo', 'Junio', 'Julio', 'Agosto', 'Septiembre', 'Octubre', 'Noviembre', 'Diciembre')
),
'da' => array (
'weekdays_short'=> array ('S&#xf8;n', 'Man', 'Tir', 'Ons', 'Tor', 'Fre', 'L&#xf8;r'),
'weekdays_long' => array ('S&#xf8;ndag', 'Mandag', 'Tirsdag', 'Onsdag', 'Torsdag', 'Fredag', 'L&#xf8;rdag'),
'months_short' => array ('Jan', 'Feb', 'Mar', 'Apr', 'Maj', 'Jun', 'Jul', 'Aug', 'Sep', 'Okt', 'Nov', 'Dec'),
'months_long' => array ('Januar', 'Februar', 'Marts', 'April', 'Maj', 'Juni', 'Juli', 'August', 'September', 'Oktober', 'November', 'December')
),
'is' => array (
'weekdays_short'=> array ('Sun', 'M&#xe1;n', '&#xde;ri', 'Mi&#xf0;', 'Fim', 'F&#xf6;s', 'Lau'),
'weekdays_long' => array ('Sunnudagur', 'M&#xe1;nudagur', '&#xde;ri&#xf0;judagur', 'Mi&#xf0;vikudagur', 'Fimmtudagur', 'F&#xf6;studagur', 'Laugardagur'),
'months_short' => array ('Jan', 'Feb', 'Mar', 'Apr', 'Ma&#xed;', 'J&#xfa;n', 'J&#xfa;l', '&#xc1;g&#xfa;', 'Sep', 'Okt', 'N&#xf3;v', 'Des'),
'months_long' => array ('Jan&#xfa;ar', 'Febr&#xfa;ar', 'Mars', 'Apr&#xed;l', 'Ma&#xed;', 'J&#xfa;n&#xed;', 'J&#xfa;l&#xed;', '&#xc1;g&#xfa;st', 'September', 'Okt&#xf3;ber', 'N&#xf3;vember', 'Desember')
),
'it' => array (
'weekdays_short'=> array ('Dom', 'Lun', 'Mar', 'Mer', 'Gio', 'Ven', 'Sab'),
'weekdays_long' => array ('Domenica', 'Luned&#xec;', 'Marted&#xec;', 'Mercoled&#xec;', 'Gioved&#xec;', 'Venerd&#xec;', 'Sabato'),
'months_short' => array ('Gen', 'Feb', 'Mar', 'Apr', 'Mag', 'Giu', 'Lug', 'Ago', 'Set', 'Ott', 'Nov', 'Dic'),
'months_long' => array ('Gennaio', 'Febbraio', 'Marzo', 'Aprile', 'Maggio', 'Giugno', 'Luglio', 'Agosto', 'Settembre', 'Ottobre', 'Novembre', 'Dicembre')
),
'sk' => array (
'weekdays_short'=> array ('Ned', 'Pon', 'Uto', 'Str', '&#x8a;tv', 'Pia', 'Sob'),
'weekdays_long' => array ('Nede&#x17e;a', 'Pondelok', 'Utorok', 'Streda', '&#x8a;tvrtok', 'Piatok', 'Sobota'),
'months_short' => array ('Jan', 'Feb', 'Mar', 'Apr', 'M&#xe1;j', 'J&#xfa;n', 'J&#xfa;l', 'Aug', 'Sep', 'Okt', 'Nov', 'Dec'),
'months_long' => array ('Janu&#xe1;r', 'Febru&#xe1;r', 'Marec', 'Apr&#xed;l', 'M&#xe1;j', 'J&#xfa;n', 'J&#xfa;l', 'August', 'September', 'Okt&#xf3;ber', 'November', 'December')
),
'cs' => array (
'weekdays_short'=> array ('Ne', 'Po', '&#xda;t', 'St', '&#x10c;t', 'P&#xe1;', 'So'),
'weekdays_long' => array ('Ned&#x11b;le', 'Pond&#x11b;l&#xed;', '&#xda;ter&#xfd;', 'St&#x159;eda', '&#x10c;tvrtek', 'P&#xe1;tek', 'Sobota'),
'months_short' => array ('Led', '&#xda;no', 'B&#x159;e', 'Dub', 'Kv&#x11b;', '&#x10c;en', '&#x10c;ec', 'Srp', 'Z&#xe1;&#x159;', '&#x158;&#xed;j', 'Lis', 'Pro'),
'months_long' => array ('Leden', '&#xda;nor', 'B&#x159;ezen', 'Duben', 'Kv&#x11b;ten', '&#x10c;erven', '&#x10c;ervenec', 'Srpen', 'Z&#xe1;&#x159;&#xed;', '&#x158;&#xed;jen', 'Listopad', 'Prosinec')
),
'hy' => array (
'weekdays_short'=> array ('&#x53f;&#x580;&#x56f;', '&#x535;&#x580;&#x56f;', '&#x535;&#x580;&#x584;', '&#x549;&#x580;&#x584;', '&#x540;&#x576;&#x563;', '&#x548;&#x582;&#x580;', '&#x547;&#x562;&#x569;'),
'weekdays_long' => array ('&#x53f;&#x56b;&#x580;&#x561;&#x56f;&#x56b;', '&#x535;&#x580;&#x56f;&#x578;&#x582;&#x577;&#x561;&#x562;&#x569;&#x56b;', '&#x535;&#x580;&#x565;&#x584;&#x577;&#x561;&#x562;&#x569;&#x56b;', '&#x549;&#x578;&#x580;&#x565;&#x584;&#x577;&#x561;&#x562;&#x569;&#x56b;', '&#x540;&#x56b;&#x576;&#x563;&#x577;&#x561;&#x562;&#x569;&#x56b;', '&#x548;&#x582;&#x580;&#x562;&#x561;&#x569;', '&#x547;&#x561;&#x562;&#x561;&#x569;'),
'months_short' => array ('&#x540;&#x576;&#x57e;', '&#x553;&#x57f;&#x580;', '&#x544;&#x580;&#x57f;', '&#x531;&#x57a;&#x580;', '&#x544;&#x575;&#x57d;', '&#x540;&#x576;&#x57d;', '&#x540;&#x56c;&#x57d;', '&#x555;&#x563;&#x57d;', '&#x54d;&#x57a;&#x57f;', '&#x540;&#x56f;&#x57f;', '&#x546;&#x575;&#x574;', '&#x534;&#x56f;&#x57f;'),
'months_long' => array ('&#x540;&#x578;&#x582;&#x576;&#x57e;&#x561;&#x580;', '&#x553;&#x565;&#x57f;&#x580;&#x57e;&#x561;&#x580;', '&#x544;&#x561;&#x580;&#x57f;', '&#x531;&#x57a;&#x580;&#x56b;&#x56c;', '&#x544;&#x561;&#x575;&#x56b;&#x57d;', '&#x540;&#x578;&#x582;&#x576;&#x56b;&#x57d;', '&#x540;&#x578;&#x582;&#x56c;&#x56b;&#x57d;', '&#x555;&#x563;&#x578;&#x57d;&#x57f;&#x578;&#x57d;', '&#x54d;&#x565;&#x57a;&#x57f;&#x565;&#x574;&#x562;&#x565;&#x580;', '&#x540;&#x578;&#x56f;&#x57f;&#x565;&#x574;&#x562;&#x565;&#x580;', '&#x546;&#x578;&#x575;&#x565;&#x574;&#x562;&#x565;&#x580;', '&#x534;&#x565;&#x56f;&#x57f;&#x565;&#x574;&#x562;&#x565;&#x580;')
),
'nl' => array (
'weekdays_short'=> array ('Zo', 'Ma', 'Di', 'Wo', 'Do', 'Vr', 'Za'),
'weekdays_long' => array ('Zondag', 'Maandag', 'Dinsdag', 'Woensdag', 'Donderdag', 'Vrijdag', 'Zaterdag'),
'months_short' => array ('Jan', 'Feb', 'Mar', 'Apr', 'Mei', 'Jun', 'Jul', 'Aug', 'Sep', 'Okt', 'Nov', 'Dec'),
'months_long' => array ('Januari', 'Februari', 'Maart', 'April', 'Mei', 'Juni', 'Juli', 'Augustus', 'September', 'Oktober', 'November', 'December')
),
'et' => array (
'weekdays_short'=> array ('P', 'E', 'T', 'K', 'N', 'R', 'L'),
'weekdays_long' => array ('P&#xfc;hap&#xe4;ev', 'Esmasp&#xe4;ev', 'Teisip&#xe4;ev', 'Kolmap&#xe4;ev', 'Neljap&#xe4;ev', 'Reede', 'Laup&#xe4;ev'),
'months_short' => array ('Jaan', 'Veebr', 'M&#xe4;rts', 'Aprill', 'Mai', 'Juuni', 'Juuli', 'Aug', 'Sept', 'Okt', 'Nov', 'Dets'),
'months_long' => array ('Jaanuar', 'Veebruar', 'M&#xe4;rts', 'Aprill', 'Mai', 'Juuni', 'Juuli', 'August', 'September', 'Oktoober', 'November', 'Detsember')
),
'tr' => array (
'weekdays_short'=> array ('Paz', 'Pzt', 'Sal', '&#xc7;ar', 'Per', 'Cum', 'Cts'),
'weekdays_long' => array ('Pazar', 'Pazartesi', 'Sal&#x131;', '&#xc7;ar&#x15f;amba', 'Per&#x15f;embe', 'Cuma', 'Cumartesi'),
'months_short' => array ('Ock', '&#x15e;bt', 'Mrt', 'Nsn', 'Mys', 'Hzrn', 'Tmmz', 'A&#x11f;st', 'Eyl', 'Ekm', 'Ksm', 'Arlk'),
'months_long' => array ('Ocak', '&#x15e;ubat', 'Mart', 'Nisan', 'May&#x131;s', 'Haziran', 'Temmuz', 'A&#x11f;ustos', 'Eyl&#xfc;l', 'Ekim', 'Kas&#x131;m', 'Aral&#x131;k')
),
'no' => array (
'weekdays_short'=> array ('S&#xf8;n', 'Man', 'Tir', 'Ons', 'Tor', 'Fre', 'L&#xf8;r'),
'weekdays_long' => array ('S&#xf8;ndag', 'Mandag', 'Tirsdag', 'Onsdag', 'Torsdag', 'Fredag', 'L&#xf8;rdag'),
'months_short' => array ('Jan', 'Feb', 'Mar', 'Apr', 'Mai', 'Jun', 'Jul', 'Aug', 'Sep', 'Okt', 'Nov', 'Des'),
'months_long' => array ('Januar', 'Februar', 'Mars', 'April', 'Mai', 'Juni', 'Juli', 'August', 'September', 'Oktober', 'November', 'Desember')
),
'eo' => array (
'weekdays_short'=> array ('Dim', 'Lun', 'Mar', 'Mer', '&#x134;a&#x16D;', 'Ven', 'Sab'),
'weekdays_long' => array ('Diman&#x109;o', 'Lundo', 'Mardo', 'Merkredo', '&#x134;a&#x16D;do', 'Vendredo', 'Sabato'),
'months_short' => array ('Jan', 'Feb', 'Mar', 'Apr', 'Maj', 'Jun', 'Jul', 'A&#x16D;g', 'Sep', 'Okt', 'Nov', 'Dec'),
'months_long' => array ('Januaro', 'Februaro', 'Marto', 'Aprilo', 'Majo', 'Junio', 'Julio', 'A&#x16D;gusto', 'Septembro', 'Oktobro', 'Novembro', 'Decembro')
),
'ua' => array (
'weekdays_short'=> array('&#x41d;&#x434;&#x43b;', '&#x41f;&#x43d;&#x434;', '&#x412;&#x442;&#x440;', '&#x421;&#x440;&#x434;', '&#x427;&#x442;&#x432;', '&#x41f;&#x442;&#x43d;', '&#x421;&#x431;&#x442;'),
'weekdays_long' => array('&#x41d;&#x435;&#x434;&#x456;&#x43b;&#x44f;', '&#x41f;&#x43e;&#x43d;&#x435;&#x434;&#x456;&#x43b;&#x43e;&#x43a;', '&#x412;&#x456;&#x432;&#x442;&#x43e;&#x440;&#x43e;&#x43a;', '&#x421;&#x435;&#x440;&#x435;&#x434;&#x430;', '&#x427;&#x435;&#x442;&#x432;&#x435;&#x440;', '&#x41f;\'&#x44f;&#x442;&#x43d;&#x438;&#x446;&#x44f;', '&#x421;&#x443;&#x431;&#x43e;&#x442;&#x430;'),
'months_short' => array('&#x421;&#x456;&#x447;', '&#x41b;&#x44e;&#x442;', '&#x411;&#x435;&#x440;', '&#x41a;&#x432;&#x456;', '&#x422;&#x440;&#x430;', '&#x427;&#x435;&#x440;', '&#x41b;&#x438;&#x43f;', '&#x421;&#x435;&#x440;', '&#x412;&#x435;&#x440;', '&#x416;&#x43e;&#x432;', '&#x41b;&#x438;&#x441;', '&#x413;&#x440;&#x443;'),
'months_long' => array('&#x421;&#x456;&#x447;&#x435;&#x43d;&#x44c;', '&#x41b;&#x44e;&#x442;&#x438;&#x439;', '&#x411;&#x435;&#x440;&#x435;&#x437;&#x435;&#x43d;&#x44c;', '&#x41a;&#x432;&#x456;&#x442;&#x435;&#x43d;&#x44c;', '&#x422;&#x440;&#x430;&#x432;&#x435;&#x43d;&#x44c;', '&#x427;&#x435;&#x440;&#x432;&#x435;&#x43d;&#x44c;', '&#x41b;&#x438;&#x43f;&#x435;&#x43d;&#x44c;', '&#x421;&#x435;&#x440;&#x43f;&#x435;&#x43d;&#x44c;', '&#x412;&#x435;&#x440;&#x435;&#x441;&#x435;&#x43d;&#x44c;', '&#x416;&#x43e;&#x432;&#x442;&#x435;&#x43d;&#x44c;', '&#x41b;&#x438;&#x441;&#x442;&#x43e;&#x43f;&#x430;&#x434;', '&#x413;&#x440;&#x443;&#x434;&#x435;&#x43d;&#x44c;')
),
'ro' => array (
'weekdays_short'=> array ('Dum', 'Lun', 'Mar', 'Mie', 'Joi', 'Vin', 'Sam'),
'weekdays_long' => array ('Duminica', 'Luni', 'Marti', 'Miercuri', 'Joi', 'Vineri', 'Sambata'),
'months_short' => array ('Ian', 'Feb', 'Mar', 'Apr', 'Mai', 'Iun', 'Iul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'),
'months_long' => array ('Ianuarie', 'Februarie', 'Martie', 'Aprilie', 'Mai', 'Iunie', 'Iulie', 'August', 'Septembrie', 'Octombrie', 'Noiembrie', 'Decembrie')
),
'he' => array (
'weekdays_short'=> array ('&#1512;&#1488;&#1513;&#1493;&#1503;', '&#1513;&#1504;&#1497;', '&#1513;&#1500;&#1497;&#1513;&#1497;', '&#1512;&#1489;&#1497;&#1506;&#1497;', '&#1495;&#1502;&#1497;&#1513;&#1497;', '&#1513;&#1497;&#1513;&#1497;', '&#1513;&#1489;&#1514;'),
'weekdays_long' => array ('&#1497;&#1493;&#1501; &#1512;&#1488;&#1513;&#1493;&#1503;', '&#1497;&#1493;&#1501; &#1513;&#1504;&#1497;', '&#1497;&#1493;&#1501; &#1513;&#1500;&#1497;&#1513;&#1497;', '&#1497;&#1493;&#1501; &#1512;&#1489;&#1497;&#1506;&#1497;', '&#1497;&#1493;&#1501; &#1495;&#1502;&#1497;&#1513;&#1497;', '&#1497;&#1493;&#1501; &#1513;&#1497;&#1513;&#1497;', '&#1513;&#1489;&#1514;'),
'months_short' => array ('&#1497;&#1504;&#1493;&#1488;&#1512;', '&#1508;&#1489;&#1512;&#1493;&#1488;&#1512;', '&#1502;&#1512;&#1509;', '&#1488;&#1508;&#1512;&#1497;&#1500;', '&#1502;&#1488;&#1497;', '&#1497;&#1493;&#1504;&#1497;', '&#1497;&#1493;&#1500;&#1497;', '&#1488;&#1493;&#1490;&#1493;&#1505;&#1496;', '&#1505;&#1508;&#1496;&#1502;&#1489;&#1512;', '&#1488;&#1493;&#1511;&#1496;&#1493;&#1489;&#1512;', '&#1504;&#1493;&#1489;&#1502;&#1489;&#1512;', '&#1491;&#1510;&#1502;&#1489;&#1512;'),
'months_long' => array ('&#1497;&#1504;&#1493;&#1488;&#1512;', '&#1508;&#1489;&#1512;&#1493;&#1488;&#1512;', '&#1502;&#1512;&#1509;', '&#1488;&#1508;&#1512;&#1497;&#1500;', '&#1502;&#1488;&#1497;', '&#1497;&#1493;&#1504;&#1497;', '&#1497;&#1493;&#1500;&#1497;', '&#1488;&#1493;&#1490;&#1493;&#1505;&#1496;', '&#1505;&#1508;&#1496;&#1502;&#1489;&#1512;', '&#1488;&#1493;&#1511;&#1496;&#1493;&#1489;&#1512;', '&#1504;&#1493;&#1489;&#1502;&#1489;&#1512;', '&#1491;&#1510;&#1502;&#1489;&#1512;')
),
'sv' => array (
'weekdays_short'=> array ('S&#xf6;n', 'M&#xe5;n', 'Tis', 'Ons', 'Tor', 'Fre', 'L&#xf6;r'),
'weekdays_long' => array ('S&#xf6;ndag', 'M&#xe5;ndag', 'Tisdag', 'Onsdag', 'Torsdag', 'Fredag', 'L&#xf6;rdag'),
'months_short' => array ('Jan', 'Feb', 'Mar', 'Apr', 'Maj', 'Jun', 'Jul', 'Aug', 'Sep', 'Okt', 'Nov', 'Dec'),
'months_long' => array ('Januari', 'Februari', 'Mars', 'April', 'Maj', 'Juni', 'Juli', 'Augusti', 'September', 'Oktober', 'November', 'December')
),
'pt' => array (
'weekdays_short'=> array ('Dom', 'Seg', 'Ter', 'Qua', 'Qui', 'Sex', 'S&aacute;b'),
'weekdays_long' => array ('Domingo', 'Segunda-feira', 'Ter&ccedil;a-feira', 'Quarta-feira', 'Quinta-feira', 'Sexta-feira', 'S&aacute;bado'),
'months_short' => array ('Jan', 'Fev', 'Mar', 'Abr', 'Mai', 'Jun', 'Jul', 'Ago', 'Set', 'Out', 'Nov', 'Dez'),
'months_long' => array ('Janeiro', 'Fevereiro', 'Mar&ccedil;o', 'Abril', 'Maio', 'Junho', 'Julho', 'Agosto', 'Setembro', 'Outubro', 'Novembro', 'Dezembro')
),
'tw' => array (
'weekdays_short'=> array ('&#36913;&#26085;','&#36913;&#19968;', '&#36913;&#20108;','&#36913;&#19977;', '&#36913;&#22235;','&#36913;&#20116;', '&#36913;&#20845;'),
'weekdays_long' => array ('&#26143;&#26399;&#26085;', '&#26143;&#26399;&#19968;', '&#26143;&#26399;&#20108;', '&#26143;&#26399;&#19977;', '&#26143;&#26399;&#22235;', '&#26143;&#26399;&#20116;', '&#26143;&#26399;&#20845;'),
'months_short' => array ('&#19968;&#26376;', '&#20108;&#26376;', '&#19977;&#26376;', '&#22235;&#26376;', '&#20116;&#26376;', '&#20845;&#26376;', '&#19971;&#26376;', '&#20843;&#26376;', '&#20061;&#26376;', '&#21313;&#26376;', '&#21313;&#19968;&#26376;', '&#21313;&#20108;&#26376;'),
'months_long' => array ('&#19968;&#26376;', '&#20108;&#26376;', '&#19977;&#26376;', '&#22235;&#26376;', '&#20116;&#26376;', '&#20845;&#26376;', '&#19971;&#26376;', '&#20843;&#26376;', '&#20061;&#26376;', '&#21313;&#26376;', '&#21313;&#19968;&#26376;', '&#21313;&#20108;&#26376;')
),
'pt-br' => array (
'weekdays_short'=> array ('Dom', 'Seg', 'Ter', 'Qua', 'Qui', 'Sex', 'S&aacute;b'),
'weekdays_long' => array ('Domingo', 'Segunda', 'Ter&ccedil;a', 'Quarta', 'Quinta', 'Sexta', 'S&aacute;bado'),
'months_short' => array ('Jan', 'Fev', 'Mar', 'Abr', 'Mai', 'Jun', 'Jul', 'Ago', 'Set', 'Out', 'Nov', 'Dez'),
'months_long' => array ('Janeiro', 'Fevereiro', 'Mar&ccedil;o', 'Abril', 'Maio', 'Junho', 'Julho', 'Agosto', 'Setembro', 'Outubro', 'Novembro', 'Dezembro')
),
'sr' => array (
'weekdays_short'=> array ('&#1053;&#1077;&#1076;', '&#1055;&#1086;&#1085;', '&#1059;&#1090;&#1086;', '&#1057;&#1088;&#1077;', '&#1063;&#1077;&#1090;', '&#1055;&#1077;&#1090;', '&#1057;&#1091;&#1073;'),
'weekdays_long' => array ('&#1053;&#1077;&#1076;&#1077;&#1113;&#1072;', '&#1055;&#1086;&#1085;&#1077;&#1076;&#1077;&#1113;&#1072;&#1082;', '&#1059;&#1090;&#1086;&#1088;&#1072;&#1082;', '&#1057;&#1088;&#1077;&#1076;&#1072;', '&#1063;&#1077;&#1090;&#1074;&#1088;&#1090;&#1072;&#1082;', '&#1055;&#1077;&#1090;&#1072;&#1082;', '&#1057;&#1091;&#1073;&#1086;&#1090;&#1072;'),
'months_short' => array ('&#1032;&#1072;&#1085;', '&#1060;&#1077;&#1073;', '&#1052;&#1072;&#1088;', '&#1040;&#1087;&#1088;', '&#1052;&#1072;&#1112;', '&#1032;&#1091;&#1085;', '&#1032;&#1091;&#1083;', '&#1040;&#1074;&#1075;', '&#1057;&#1077;&#1087;', '&#1054;&#1082;&#1090;', '&#1053;&#1086;&#1074;', '&#1044;&#1077;&#1094;'),