Skip to content

Commit

Permalink
Merge pull request #4 from dignajar/master
Browse files Browse the repository at this point in the history
Merge update from dignajar
  • Loading branch information
ethan42411 committed Oct 9, 2015
2 parents bd6a396 + 058541a commit 32ab4fb
Show file tree
Hide file tree
Showing 71 changed files with 12,176 additions and 464 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ You only need a Webserver with PHP support.
- PHP module [mbstring](http://php.net/manual/en/book.mbstring.php) for full UTF-8 support.
- Webserver:
* Apache with module [mod_rewrite](http://httpd.apache.org/docs/current/mod/mod_rewrite.html)
* Ngnix with module [ngx_http_rewrite_module](http://nginx.org/en/docs/http/ngx_http_rewrite_module.html)
* Nginx with module [ngx_http_rewrite_module](http://nginx.org/en/docs/http/ngx_http_rewrite_module.html)

Installation guide
------------------
Expand Down
5 changes: 5 additions & 0 deletions admin/controllers/edit-user.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,11 @@ function deleteUser($args, $deleteContent=false)
return false;
}

// The editors cannot delete users.
if($Login->role()!=='admin') {
return false;
}

if($deleteContent) {
$dbPosts->deletePostsByUser($args['username']);
}
Expand Down
20 changes: 9 additions & 11 deletions admin/controllers/themes.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,25 +24,23 @@
$themes = array();
$themesPaths = Filesystem::listDirectories(PATH_THEMES);

// Load each plugin clasess
foreach($themesPaths as $themePath)
{
$langLocaleFile = $themePath.DS.'languages'.DS.$Site->locale().'.json';
$langDefaultFile = $themePath.DS.'languages'.DS.'en_US.json';
$database = false;

// Check if exists locale language
if( Sanitize::pathFile($langLocaleFile) ) {
$database = new dbJSON($langLocaleFile, false);
}
// Check if exists default language
elseif( Sanitize::pathFile($langDefaultFile) ) {
$database = new dbJSON($langDefaultFile, false);
}

if($database!==false)
if( Sanitize::pathFile($langDefaultFile) )
{
$database = new dbJSON($langDefaultFile, false);
$databaseArray = $database->db;

// Check if exists locale language
if( Sanitize::pathFile($langLocaleFile) ) {
$database = new dbJSON($langLocaleFile, false);
$databaseArray['theme-data'] = array_merge($databaseArray['theme-data'], $database->db['theme-data']);
}

$databaseArray['theme-data']['dirname'] = basename($themePath);

// Theme data
Expand Down
3 changes: 2 additions & 1 deletion admin/themes/default/css/default.css
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,10 @@ body {
background-color: #f9f9f9;
}

div.unit-80 {
/*div.unit-80 {
margin-left: 1% !important;
}
*/

.tools-alert {
text-align: center;
Expand Down
2 changes: 1 addition & 1 deletion admin/themes/default/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
</nav>
</div>

<div class="units-row">
<div class="units-row units-split">

<!-- SIDEBAR -->
<div class="unit-20">
Expand Down
53 changes: 53 additions & 0 deletions admin/themes/uikit/css/default.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
/* uikit hack for Bludit */
.uk-navbar {
background: #f5f5f5;
border: none !important;
}

.uk-button {
color: #ffffff;
padding: 1px 18px;
text-shadow: none;
}

.uk-button:hover,
.uk-button:focus {
background-color: #777777;
color: #ffffff;
}

.uk-navbar-nav > li > a {
border: none;
}

.uk-form-label {
color: #666666;
font-weight: normal !important;
}

.uk-form-help-block {
color: #AAAAAA;
font-size: 0.9em;
}

.uk-table th,
.uk-table td {
padding: 15px 10px;
}

/* Bludit */

#logo {
background: #f4f4f4;
height: 60px;
}

h2.subtitle {
margin: 20px 0;
}

div.plugin-link a {
display: inline-block;
margin-right: 10px;
margin-top: 5px;
}

0 comments on commit 32ab4fb

Please sign in to comment.