Skip to content

Commit

Permalink
small code changes and switch to minimal php 5.6
Browse files Browse the repository at this point in the history
  • Loading branch information
bueltge committed Jan 3, 2018
1 parent d933121 commit 8546cc1
Show file tree
Hide file tree
Showing 17 changed files with 30 additions and 32 deletions.
1 change: 1 addition & 0 deletions .gitattributes
@@ -0,0 +1 @@
* text eol=lf
19 changes: 18 additions & 1 deletion .gitignore
Expand Up @@ -8,4 +8,21 @@
node_modules
.npm-debug.log
*.lock
vendor

### Composer template
composer.phar
/vendor/*
!assets/js/vendor/*


## PhpStorm
## Directory-based project format
.idea/
.idea_modules/

## File-based project format
*.ipr
*.iws

## Additional for IntelliJ
out/
2 changes: 0 additions & 2 deletions assets/css/index.php

This file was deleted.

2 changes: 0 additions & 2 deletions assets/img/index.php

This file was deleted.

2 changes: 0 additions & 2 deletions assets/index.php

This file was deleted.

2 changes: 0 additions & 2 deletions assets/js/index.php

This file was deleted.

2 changes: 0 additions & 2 deletions assets/js/map/index.php

This file was deleted.

2 changes: 0 additions & 2 deletions assets/js/source/index.php

This file was deleted.

2 changes: 0 additions & 2 deletions assets/js/vendor/index.php

This file was deleted.

Empty file modified assets/js/vendor/modernizr.js 100755 → 100644
Empty file.
16 changes: 9 additions & 7 deletions functions.php
Expand Up @@ -23,22 +23,22 @@
* For more information on hooks, actions, and filters, see
* @link http://codex.wordpress.org/Plugin_API.
*
* Php Version 5.3
* Php Version 5.6
*
* @package WordPress
* @subpackage WordPress_Basis_Theme
* @since 2012-05-08 0.0.1
* @version 2014-11-03
* @version 2018-01-03
* @author Frank Bültge <frank@bueltge.de>
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*/

// check for right php version
$correct_php_version = version_compare( phpversion(), '5.3.0', '>=' );
$correct_php_version = PHP_VERSION_ID >= 50600;

if ( ! $correct_php_version ) {
echo 'The WP Basis Theme requires <strong>PHP 5.3</strong> or higher.<br>';
echo 'You are running PHP ' . phpversion();
echo 'The WP Basis Theme requires <strong>PHP 5.6</strong> or higher.<br>';
echo 'You are running PHP ' . PHP_VERSION;
exit;
}

Expand All @@ -56,7 +56,7 @@
function wp_basis_load_files() {

$inc_directory = 'inc';
$inc_base = dirname( __FILE__ ) . '/' . $inc_directory . '/';
$inc_base = __DIR__ . DIRECTORY_SEPARATOR . $inc_directory . DIRECTORY_SEPARATOR;
$includes = array();

// load required classes
Expand All @@ -73,8 +73,10 @@ function wp_basis_load_files() {
$includes
);

foreach ( $includes as $key => $path )
foreach ( $includes as $key => $path ) {
/** @noinspection PhpIncludeInspection */
require_once $path;
}

}
}
Empty file added inc/class-gutenberg.php
Empty file.
2 changes: 0 additions & 2 deletions inc/index.php

This file was deleted.

2 changes: 0 additions & 2 deletions languages/index.php

This file was deleted.

2 changes: 0 additions & 2 deletions parts/index.php

This file was deleted.

4 changes: 2 additions & 2 deletions readme.md
Expand Up @@ -18,8 +18,8 @@ See the repository for a [starter kit](https://github.com/bueltge/wordpress-basi

## Installation
### Requirements
* WordPress (also Multisite) version 3.3 and later (tested at 3.4)
* PHP 5.3 (use PHP namespaces)
* WordPress (also Multisite) version 3.3 and later
* PHP 5.6 (use PHP namespaces)

### Composer Usage
#### What is Composer?
Expand Down
2 changes: 0 additions & 2 deletions widgets/index.php

This file was deleted.

0 comments on commit 8546cc1

Please sign in to comment.