From b2617bd7b2504492a987083955cb78a4edef4d29 Mon Sep 17 00:00:00 2001 From: Jun NOGATA Date: Wed, 15 Jul 2015 08:23:49 +0900 Subject: [PATCH 1/3] Add ja_JP.json --- languages/ja_JP.json | 109 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 109 insertions(+) create mode 100644 languages/ja_JP.json diff --git a/languages/ja_JP.json b/languages/ja_JP.json new file mode 100644 index 00000000..6b98a392 --- /dev/null +++ b/languages/ja_JP.json @@ -0,0 +1,109 @@ +{ + "language-data": + { + "native": "日本語", + "english-name": "Japanese", + "last-update": "2015-07-15", + "author": "Jun NOGATA", + "email": "nogajun@gmail.com", + "website": "http://www.nofuture.tv/" + }, + + "username": "ユーザー名", + "password": "パスワード", + "confirm-password": "パスワードの確認", + "editor": "編集者", + "dashboard": "ダッシュボード", + "role": "役割", + "posts": "記事", + "users": "ユーザー", + "administrator": "管理者", + "add": "追加", + "cancel": "キャンセル", + "content": "内容", + "title": "タイトル", + "no-parent": "親ページなし", + "edit-page": "ページの編集", + "edit-post": "記事の編集", + "add-a-new-user": "新規ユーザーの追加", + "parent": "親ページ", + "friendly-url": "フレンドリーURL", + "description": "概要", + "posted-by": "投稿者", + "tags": "タグ", + "position": "位置", + "save": "保存", + "draft": "下書き", + "delete": "削除", + "registered": "登録日", + "Notifications": "通知", + "profile": "プロフィール", + "email": "Eメール", + "settings": "設定", + "general": "全般", + "advanced": "詳細", + "regional": "地域", + "about": "Bluditについて", + "login": "ログイン", + "logout": "ログアウト", + "dasbhoard": "ダッシュボード", + "manage": "管理", + "themes": "テーマ", + "configure-plugin": "プラグインの設定", + "confirm-delete-this-action-cannot-be-undone": "削除しますか? この操作は取り消せません", + "site-title": "サイトタイトル", + "site-slogan": "サイトキャッチフレーズ", + "site-description": "サイト概要", + "footer-text": "フッターテキスト", + "posts-per-page": "ページあたりの投稿数", + "site-url": "サイトURL", + "writting-settings": "編集設定", + "url-filters": "URLフィルター", + "pages": "ページ", + "home": "ホーム", + "welcome-back": "お帰りなさい", + "language": "言語", + "website": "Webサイト", + "timezone": "タイムゾーン", + "locale": "ロケール", + "notifications": "お知らせ", + "new-post": "新規記事", + "html-and-markdown-code-supported": "HTMLとMarkdownが利用できます", + "new-page": "新規ページ", + "manage-posts": "投稿の管理", + "published-date": "公開日", + "modified-date": "更新日", + "empty-title": "タイトルなし", + "plugins": "プラグイン", + "install-plugin": "インストール", + "uninstall-plugin": "アンインストール", + "new-password": "新しいパスワード", + "edit-user": "ユーザーの編集", + "publish-now": "今すぐ公開", + "first-name": "名", + "last-name": "姓", + "manage-pages": "ページの管理", + "advanced-options": "詳細オプション", + "database-regenerated": "データベースを再生成しました", + "html-markdown-code-supported": "HTMLとMarkdownが利用できます", + "enable-more-features-at": "より多くの機能を有効に", + "settings-advanced-writting-settings": "設定->詳細->編集設定", + "new-posts-and-pages-synchronized": "新規投稿とページを同期しました", + "you-can-choose-the-users-privilege": "ユーザーの権限を設定します。編集者は記事とページの投稿編集のみできます", + "email-will-not-be-publicly-displayed": "メールアドレスは公開されません。パスワードの復旧や通知に利用されます", + "use-this-field-to-name-your-site": "サイト名を入力します。サイト名は各ページ上部に表示されます", + "use-this-field-to-add-a-catchy-prhase": "サイトのキャッチフレーズを入力します", + "you-can-add-a-site-description-to-provide": "サイトの説明や紹介に利用する概要を入力します", + "you-can-add-a-small-text-on-the-bottom": "各ページ下部に追加する短いテキストを入力します。使用例: 著作権表示、所有者名表示、日付など", + "number-of-posts-to-show-per-page": "1ページに表示する投稿数を設定します", + "the-url-of-your-site": "サイトのURLを設定します", + "add-or-edit-description-tags-or": "コンテンツ概要やタグの追加と編集、フレンドリーURLの変更オプションを利用します", + "select-your-sites-language": "サイトで利用する言語を選択します", + "select-a-timezone-for-a-correct": "正しい日付/時刻を表示するためのタイムゾーンを選択します", + "you-can-use-this-field-to-define-a-set-of": "言語や国、固有の設定に関する設定を変更する場合に利用します", + "email": "Eメール", + "email": "Eメール", + "email": "Eメール", + "email": "Eメール", + "email": "Eメール" +} \ No newline at end of file From 3e52d937afa10b887b072da56c92595646c8efe2 Mon Sep 17 00:00:00 2001 From: dignajar Date: Tue, 14 Jul 2015 20:57:18 -0300 Subject: [PATCH 2/3] Plugin configuration --- admin/controllers/edit-user.php | 2 +- kernel/abstract/dbjson.class.php | 14 -------------- kernel/abstract/plugin.class.php | 3 ++- kernel/boot/rules/70.build_pages.php | 2 +- kernel/boot/rules/70.build_posts.php | 2 +- kernel/boot/rules/80.plugins.php | 2 +- kernel/dbusers.class.php | 8 ++++---- kernel/login.class.php | 2 +- 8 files changed, 11 insertions(+), 24 deletions(-) diff --git a/admin/controllers/edit-user.php b/admin/controllers/edit-user.php index a035e315..a697d575 100644 --- a/admin/controllers/edit-user.php +++ b/admin/controllers/edit-user.php @@ -51,7 +51,7 @@ if($Login->role()!=='admin') { $layout['parameters'] = $Login->username(); } -$_user = $dbUsers->get($layout['parameters']); +$_user = $dbUsers->getDb($layout['parameters']); // If the user doesn't exist, redirect to the users list. if($_user===false) { diff --git a/kernel/abstract/dbjson.class.php b/kernel/abstract/dbjson.class.php index 1977cfa6..ea81db76 100644 --- a/kernel/abstract/dbjson.class.php +++ b/kernel/abstract/dbjson.class.php @@ -36,20 +36,6 @@ class dbJSON } } - // Get database. - public function get() - { - return $this->db; - } - - // Set and save database. - public function set($db) - { - $this->db = $db; - - return $this->save(); - } - // Returns the amount of database items. public function count() { diff --git a/kernel/abstract/plugin.class.php b/kernel/abstract/plugin.class.php index b60ccd5f..83686978 100644 --- a/kernel/abstract/plugin.class.php +++ b/kernel/abstract/plugin.class.php @@ -144,7 +144,8 @@ class Plugin { // Create database $Tmp = new dbJSON($this->filenameDb); - $Tmp->set($this->dbFields); + $Tmp->db = $this->dbFields; + $Tmp->save(); return true; } diff --git a/kernel/boot/rules/70.build_pages.php b/kernel/boot/rules/70.build_pages.php index 062abe87..5484e33f 100644 --- a/kernel/boot/rules/70.build_pages.php +++ b/kernel/boot/rules/70.build_pages.php @@ -69,7 +69,7 @@ function build_page($key) // Parse username for the page. if( $dbUsers->userExists( $Page->username() ) ) { - $user = $dbUsers->get( $Page->username() ); + $user = $dbUsers->getDb( $Page->username() ); $Page->setField('authorFirstName', $user['firstName'], false); diff --git a/kernel/boot/rules/70.build_posts.php b/kernel/boot/rules/70.build_posts.php index 7f30b9b8..351e9852 100644 --- a/kernel/boot/rules/70.build_posts.php +++ b/kernel/boot/rules/70.build_posts.php @@ -57,7 +57,7 @@ function buildPost($key) // Parse username for the post. if( $dbUsers->userExists( $Post->username() ) ) { - $user = $dbUsers->get( $Post->username() ); + $user = $dbUsers->getDb( $Post->username() ); $Post->setField('authorFirstName', $user['firstName'], false); diff --git a/kernel/boot/rules/80.plugins.php b/kernel/boot/rules/80.plugins.php index 47e68897..8a3ed06e 100644 --- a/kernel/boot/rules/80.plugins.php +++ b/kernel/boot/rules/80.plugins.php @@ -62,7 +62,7 @@ function build_plugins() $database = new dbJSON($languageFilename, false); } - $databaseArray = $database->get(); + $databaseArray = $database->db; $Plugin->setData( $databaseArray['plugin-data'] ); // Add words to language dictionary. diff --git a/kernel/dbusers.class.php b/kernel/dbusers.class.php index 5fa2310b..0178ab1b 100644 --- a/kernel/dbusers.class.php +++ b/kernel/dbusers.class.php @@ -19,7 +19,7 @@ class dbUsers extends dbJSON } // Return an array with the username databases - public function get($username) + public function getDb($username) { if($this->userExists($username)) { @@ -57,7 +57,7 @@ class dbUsers extends dbJSON { $dataForDb = array(); - $user = $this->get($args['username']); + $user = $this->getDb($args['username']); if($user===false) { @@ -70,10 +70,10 @@ class dbUsers extends dbJSON { if( isset($this->dbFields[$field]) ) { - // Sanitize if will be saved on database. + // Sanitize. $tmpValue = Sanitize::html($value); - // Set type + // Set type. settype($tmpValue, gettype($this->dbFields[$field]['value'])); $user[$field] = $tmpValue; diff --git a/kernel/login.class.php b/kernel/login.class.php index f6ec2e05..d9ad1a11 100644 --- a/kernel/login.class.php +++ b/kernel/login.class.php @@ -60,7 +60,7 @@ class Login { return false; } - $user = $this->dbUsers->get($username); + $user = $this->dbUsers->getDb($username); if($user==false) { Log::set(__METHOD__.LOG_SEP.'Username not exist: '.$username); return false; From 85b9109be1e70d14212abbe8b1a2e4372cae5adb Mon Sep 17 00:00:00 2001 From: dignajar Date: Tue, 14 Jul 2015 21:07:07 -0300 Subject: [PATCH 3/3] MIT License --- README.md | 6 +++++- content/README | 2 ++ index.php | 2 +- install.php | 8 ++++++++ 4 files changed, 16 insertions(+), 2 deletions(-) create mode 100644 content/README diff --git a/README.md b/README.md index 603aaccc..ff0d329b 100644 --- a/README.md +++ b/README.md @@ -25,4 +25,8 @@ Installation guide 1. Download the latest version from http://www.bludit.com/bludit_latest.zip 2. Extract the zip file into a directory like `bludit`. 3. Upload the directory `bludit` on your hosting. -4. Done! \ No newline at end of file +4. Done! + +License +------- +Bludit is opensource software licensed under the [MIT license](https://tldrlegal.com/license/mit-license) \ No newline at end of file diff --git a/content/README b/content/README new file mode 100644 index 00000000..d68ab992 --- /dev/null +++ b/content/README @@ -0,0 +1,2 @@ +Set the correct permissions on this directory. +Check the documentation: http://docs.bludit.com/en/troubleshooting/writing-test-failure-err205 diff --git a/index.php b/index.php index be5ba4e4..add85269 100644 --- a/index.php +++ b/index.php @@ -4,7 +4,7 @@ * Bludit * http://www.bludit.com * Author Diego Najar - * All Bludit code is released under the GNU General Public License. + * Bludit is opensource software licensed under the MIT license. */ // Check installation diff --git a/install.php b/install.php index 7fc33c5b..08f03c65 100644 --- a/install.php +++ b/install.php @@ -1,4 +1,12 @@