diff --git a/.gitignore b/.gitignore index e8d8e77ae1..98f53139b2 100755 --- a/.gitignore +++ b/.gitignore @@ -16,6 +16,8 @@ _protected/data/cache/* _protected/vendor/* composer.phar phpunit.phar +.php_cs +.php_cs.cache *.log *.tmp diff --git a/.php_cs.dist b/.php_cs.dist new file mode 100644 index 0000000000..a351fc170f --- /dev/null +++ b/.php_cs.dist @@ -0,0 +1,35 @@ + true, + '@Symfony' => true, + 'array_syntax' => ['syntax' => 'short'], + 'combine_consecutive_unsets' => true, + 'general_phpdoc_annotation_remove' => ['expectedException', 'expectedExceptionMessage', 'expectedExceptionMessageRegExp'], + 'heredoc_to_nowdoc' => true, + 'no_extra_consecutive_blank_lines' => ['break', 'continue', 'extra', 'return', 'throw', 'use', 'parenthesis_brace_block', 'square_brace_block', 'curly_brace_block'], + 'no_short_echo_tag' => true, + 'no_php4_constructor' => true, + 'no_unreachable_default_argument_value' => true, + 'no_useless_else' => true, + 'no_useless_return' => true, + 'ordered_class_elements' => true, + 'phpdoc_add_missing_param_annotation' => true, + 'phpdoc_order' => true, + 'semicolon_after_instruction' => true, + 'psr4' => true, + 'strict_comparison' => true, + 'strict_param' => true, + 'standardize_not_equals' => true +]; + +return PhpCsFixer\Config::create() + ->setRiskyAllowed(false) + ->setRules($aRules) + ->setFinder( + PhpCsFixer\Finder::create() + ->exclude('vendor') + ->exclude('library') + ->in('_protected') + ) +; diff --git a/_install/library/Controller.class.php b/_install/library/Controller.class.php index b5ea7c699b..47937d9b24 100755 --- a/_install/library/Controller.class.php +++ b/_install/library/Controller.class.php @@ -31,7 +31,7 @@ abstract class Controller implements Controllable SOFTWARE_COPYRIGHT = '© (c) 2012-2017, Pierre-Henry Soria. All Rights Reserved.', // 1.0, 1.1 branches were "pOH", 1.2 was "pOW", 1.3, 1.4 were "p[H]", 2.* was "H2O", 3.* was "H3O", 4.* was "HCO", 5.* was "pCO" and 6.* is "WoW" SOFTWARE_VERSION_NAME = 'WoW', - SOFTWARE_VERSION = '6.0.8', + SOFTWARE_VERSION = '6.0.9', SOFTWARE_BUILD = '1', DEFAULT_LANG = 'en', DEFAULT_THEME = 'base'; diff --git a/_protected/app/system/modules/admin123/views/base/tpl/setting/license.tpl b/_protected/app/system/modules/admin123/views/base/tpl/setting/license.tpl index 55ddd151de..11170018b8 100755 --- a/_protected/app/system/modules/admin123/views/base/tpl/setting/license.tpl +++ b/_protected/app/system/modules/admin123/views/base/tpl/setting/license.tpl @@ -5,6 +5,10 @@ {lang 'Unlock all premium features and use your site for commercial use'} + {{ LicenseForm::display() }} -

Staring Eyes

+ +

+ Staring Eyes +

diff --git a/_protected/framework/Security/Version.class.php b/_protected/framework/Security/Version.class.php index ea7d1a1df1..59a0069032 100755 --- a/_protected/framework/Security/Version.class.php +++ b/_protected/framework/Security/Version.class.php @@ -23,9 +23,9 @@ final class Version /***** Framework Kernel *****/ // 1.0, 1.1 branches were "pOH", 1.2 was "pOW", 1.3, 1.4 were "p[H]", 2.* was "H2O", 3.* was "H3O", 4.* was "HCO", 5.* was "pCO" and 6.* is "WoW" const KERNEL_VERSION_NAME = 'WoW'; - const KERNEL_VERSION = '6.0.8'; + const KERNEL_VERSION = '6.0.9'; const KERNEL_BUILD = '1'; - const KERNEL_RELASE_DATE = '2017-03-27'; + const KERNEL_RELASE_DATE = '2017-04-04'; /***** Framework Server *****/ const KERNEL_TECHNOLOGY_NAME = 'pH7T/1.0.1'; // Ph7 Technology diff --git a/_tools/deployment.sh b/_tools/deployment.sh index d1f34a2b08..46a2974baf 100755 --- a/_tools/deployment.sh +++ b/_tools/deployment.sh @@ -75,6 +75,12 @@ function run() { rm -rf ./_tests/ rm -rf ./.git/ + ## PHPCS + rm ./phpcs.xml.dist + rm ./.php_cs + rm ./.php_cs.cache + rm ./.php_cs.dist + ## TMP folders # elFinder cache folders rm -rf ./.quarantine/ diff --git a/composer.json b/composer.json index f5a4a40030..1bc85a0f5e 100644 --- a/composer.json +++ b/composer.json @@ -41,7 +41,8 @@ }, "require-dev": { "phpunit/phpunit": "^5.5", - "phake/phake": "^2.3" + "phake/phake": "^2.3", + "friendsofphp/php-cs-fixer": "^2.2" }, "autoload-dev": { "psr-4": { diff --git a/phpcs.xml.dist b/phpcs.xml.dist new file mode 100644 index 0000000000..4d7e696534 --- /dev/null +++ b/phpcs.xml.dist @@ -0,0 +1,9 @@ + + + _protected + + + + + + diff --git a/templates/themes/base/tpl/top_menu.inc.tpl b/templates/themes/base/tpl/top_menu.inc.tpl index d5470d9488..a6d9708e6a 100755 --- a/templates/themes/base/tpl/top_menu.inc.tpl +++ b/templates/themes/base/tpl/top_menu.inc.tpl @@ -452,14 +452,14 @@ {if !$is_valid_license}
  • {lang 'Switch to pH7CMSPro'}
  • {/if} -
  • {lang 'Customization/New Feature'}
  • {lang 'Technical Support'}
  • {lang 'Documentation'}
  • {lang 'FAQ'}
  • -
  • {lang 'Report a Bug'}
  • -
  • {lang 'Are you a Fiverr seller? Market your Gigs!'}
  • +
  • {lang 'Report a Bug'}
  • +
  • {lang 'Market your Android Apps'}
  • +
  • {lang 'Are you selling Fiverr? Market your Gigs!'}
  • {* Coming soon ... -
  • {lang 'Forum'}
  • +
  • {lang 'Forum'}
  • *}