diff --git a/README.md b/README.md index d771c64e7..910cf2148 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,10 @@ October's mission is to show the world that web development is not rocket scienc The best place to learn October is by [reading the documentation](http://octobercms.com/docs). +### Installing October + +Instructions on how to install October can be found at the [installation guide](http://octobercms.com/docs/help/install). + ### Development Team October was created by [Alexey Bobkov](http://ca.linkedin.com/pub/aleksey-bobkov/2b/ba0/232) and [Samuel Georges](http://au.linkedin.com/pub/sam-georges/31/641/a9), who both continue to develop the platform. @@ -30,6 +34,6 @@ You can communicate with us using the following mediums: * [Follow us on Facebook](http://facebook.com/octobercms) for announcements and updates. * [Join us on IRC](https://kiwiirc.com/client/irc.freenode.net/?nick=Octonaut|?#october) to chat with us. -### License +### Licence The OctoberCMS platform is open-sourced software licensed under the [MIT license](http://opensource.org/licenses/MIT). diff --git a/app/config/cms.php b/app/config/cms.php index 18634e48b..4c63bcdb0 100644 --- a/app/config/cms.php +++ b/app/config/cms.php @@ -114,10 +114,10 @@ return array( /* |-------------------------------------------------------------------------- - | Determines if the asset minifcation is enabled. + | Determines if the asset minification is enabled. |-------------------------------------------------------------------------- | - | If the minifcation is enabled, combined assets are compressed (minified). + | If the minification is enabled, combined assets are compressed (minified). | It is recommended to disable the minification during the development, and | enable it in the production mode. | diff --git a/app/start/global.php b/app/start/global.php index bac8c1c78..a5b2c6aff 100644 --- a/app/start/global.php +++ b/app/start/global.php @@ -58,7 +58,7 @@ App::error(function(Exception $exception, $code) | | The "down" Artisan command gives you the ability to put an application | into maintenance mode. Here, you will define what is displayed back -| to the user if maintenace mode is in effect for this application. +| to the user if maintenance mode is in effect for this application. | */ diff --git a/modules/backend/behaviors/FormController.php b/modules/backend/behaviors/FormController.php index 22c6f1da3..4e23e276a 100644 --- a/modules/backend/behaviors/FormController.php +++ b/modules/backend/behaviors/FormController.php @@ -513,7 +513,7 @@ class FormController extends ControllerBehavior /** * Extend the query used for finding the form model. Extra conditions - * can be appied to the query, for example, $query->withTrashed(); + * can be applied to the query, for example, $query->withTrashed(); * @param October\Rain\Database\Builder $query * @return void */ diff --git a/modules/backend/behaviors/ListController.php b/modules/backend/behaviors/ListController.php index ef93ddf20..fa90decb6 100644 --- a/modules/backend/behaviors/ListController.php +++ b/modules/backend/behaviors/ListController.php @@ -19,7 +19,7 @@ class ListController extends ControllerBehavior /** * @var array List definitions, keys for alias and value for configuration. */ - private $listDefinintions; + private $listDefinitions; /** * @var string The primary list alias to use. Default: list @@ -61,18 +61,18 @@ class ListController extends ControllerBehavior * Extract list definitions */ if (is_array($controller->listConfig)) { - $this->listDefinintions = $controller->listConfig; - $this->primaryDefinition = key($this->listDefinintions); + $this->listDefinitions = $controller->listConfig; + $this->primaryDefinition = key($this->listDefinitions); } else { - $this->listDefinintions = ['list' => $controller->listConfig]; + $this->listDefinitions = ['list' => $controller->listConfig]; $this->primaryDefinition = 'list'; } /* * Build configuration */ - $this->setConfig($this->listDefinintions[$this->primaryDefinition], $this->requiredConfig); + $this->setConfig($this->listDefinitions[$this->primaryDefinition], $this->requiredConfig); } /** @@ -81,7 +81,7 @@ class ListController extends ControllerBehavior */ public function makeLists() { - foreach ($this->listDefinintions as $definition => $config) { + foreach ($this->listDefinitions as $definition => $config) { $this->listWidgets[$definition] = $this->makeList($definition); } @@ -94,10 +94,10 @@ class ListController extends ControllerBehavior */ public function makeList($definition = null) { - if (!$definition || !isset($this->listDefinintions[$definition])) + if (!$definition || !isset($this->listDefinitions[$definition])) $definition = $this->primaryDefinition; - $listConfig = $this->makeConfig($this->listDefinintions[$definition], $this->requiredConfig); + $listConfig = $this->makeConfig($this->listDefinitions[$definition], $this->requiredConfig); /* * Create the model @@ -197,7 +197,7 @@ class ListController extends ControllerBehavior if (!count($this->listWidgets)) throw new SystemException(Lang::get('backend::lang.list.behavior_not_ready')); - if (!$definition || !isset($this->listDefinintions[$definition])) + if (!$definition || !isset($this->listDefinitions[$definition])) $definition = $this->primaryDefinition; $collection = []; diff --git a/modules/backend/behaviors/RelationController.php b/modules/backend/behaviors/RelationController.php index e36e2c8ad..063f832d5 100644 --- a/modules/backend/behaviors/RelationController.php +++ b/modules/backend/behaviors/RelationController.php @@ -103,7 +103,7 @@ class RelationController extends ControllerBehavior protected $manageMode; /** - * @var int Primary id of an exisiting relation record. + * @var int Primary id of an existing relation record. */ protected $manageId; @@ -353,7 +353,7 @@ class RelationController extends ControllerBehavior } /** - * Returns the exisiting record IDs for the relation. + * Returns the existing record IDs for the relation. */ private function findExistingRelationIds($checkIds = null) { @@ -391,7 +391,7 @@ class RelationController extends ControllerBehavior if (($checkedIds = post('checked')) && is_array($checkedIds)) { /* - * Remove exisiting relations from the array + * Remove existing relations from the array */ $existingIds = $this->findExistingRelationIds($checkedIds); $checkedIds = array_diff($checkedIds, $existingIds); @@ -451,7 +451,7 @@ class RelationController extends ControllerBehavior $saveData = $this->pivotWidget->getSaveData(); /* - * Check for exisiting relation + * Check for existing relation */ $existing = $this->relationObject->where('id', $foreignId)->count(); @@ -569,7 +569,7 @@ class RelationController extends ControllerBehavior } /* - * Exclude exisiting relationships + * Exclude existing relationships */ if ($this->manageMode == 'pivot' || $this->manageMode == 'list') { $widget->bindEvent('list.extendQueryBefore', function($host, $query) { diff --git a/modules/backend/classes/Controller.php b/modules/backend/classes/Controller.php index 8e3ed26a6..77d2aaecd 100644 --- a/modules/backend/classes/Controller.php +++ b/modules/backend/classes/Controller.php @@ -213,7 +213,7 @@ class Controller extends Extendable /** * Invokes the current controller action without rendering a view, - * used by AJAX handler who may rely on the logic inside the aciton. + * used by AJAX handler who may rely on the logic inside the action. */ public function pageAction() { diff --git a/modules/backend/classes/ControllerBehavior.php b/modules/backend/classes/ControllerBehavior.php index dfb9b3709..6d0fc4ed3 100644 --- a/modules/backend/classes/ControllerBehavior.php +++ b/modules/backend/classes/ControllerBehavior.php @@ -116,7 +116,7 @@ class ControllerBehavior extends ExtensionBase * These methods could be defined in a controller to override a behavior default action. * Such methods should be defined as public, to allow the behavior object to access it. * By default public methods of a controller are considered as actions. - * To prevent this occurance, methods should be hidden by using this method. + * To prevent this occurrence, methods should be hidden by using this method. * @param mixed $methodName Specifies a method name. */ protected function hideAction($methodName) diff --git a/modules/backend/classes/FormField.php b/modules/backend/classes/FormField.php index 447728c9d..f8a452307 100644 --- a/modules/backend/classes/FormField.php +++ b/modules/backend/classes/FormField.php @@ -140,7 +140,7 @@ class FormField /** * Sets a side of the field on a form. - * @param $value Specifies a side. Possible values: left, right, full + * @param string $value Specifies a side. Possible values: left, right, full */ public function span($value = 'full') { @@ -150,7 +150,7 @@ class FormField /** * Sets a side of the field on a form. - * @param $value Specifies a size. Possible values: tiny, small, large, huge, giant + * @param string $value Specifies a size. Possible values: tiny, small, large, huge, giant */ public function size($value = 'large') { @@ -180,7 +180,7 @@ class FormField * Adds a text comment above or below the field. * @param string $text Specifies a comment text. * @param string $position Specifies a comment position. - * @param bool $commentHtml Set to true if you use HTML formatting in the comment + * @param bool $isHtml Set to true if you use HTML formatting in the comment * Supported values are 'below' and 'above' */ public function comment($text, $position = 'below', $isHtml = false) diff --git a/modules/backend/classes/WidgetBase.php b/modules/backend/classes/WidgetBase.php index 336497be5..2267cb452 100644 --- a/modules/backend/classes/WidgetBase.php +++ b/modules/backend/classes/WidgetBase.php @@ -43,7 +43,7 @@ abstract class WidgetBase /** * Constructor * @param Backend\Classes\Controller $controller - * @param array $configuration Proactive configuration definintion. + * @param array $configuration Proactive configuration definition. * @return void */ public function __construct($controller, $configuration = []) @@ -200,7 +200,7 @@ abstract class WidgetBase } /** - * Retreieves a widget related key/value pair from session data. + * Retrieves a widget related key/value pair from session data. * @param string $key Unique key for the data store. * @param string $default A default value to use when value is not found. * @return string diff --git a/modules/backend/classes/WidgetManager.php b/modules/backend/classes/WidgetManager.php index 20826ff11..832455d23 100644 --- a/modules/backend/classes/WidgetManager.php +++ b/modules/backend/classes/WidgetManager.php @@ -74,7 +74,7 @@ class WidgetManager /** * Makes a widget object with configuration set. - * @param $className A widget class name. + * @param string $className A widget class name. * @param Controller $controller The Backend controller that spawned this widget. * @param array $configuration Configuration values. * @return WidgetBase The widget object. @@ -92,7 +92,7 @@ class WidgetManager */ if (!class_exists($className)) { throw new SystemException(Lang::get('backend::lang.widget.not_registered', [ - 'name' => $name + 'name' => $className ])); } diff --git a/modules/backend/lang/ja/lang.php b/modules/backend/lang/ja/lang.php new file mode 100644 index 000000000..22cd35efa --- /dev/null +++ b/modules/backend/lang/ja/lang.php @@ -0,0 +1,139 @@ + [ + 'invalid_type' => '無効なフィールドタイプ :type が使用されています。', + 'options_method_not_exists' => 'モデルクラスの:modelは、":field"フォームフィールドのためにオプションを返す、:method()メソッドを定義しなくてはなりません。', + ], + 'widget' => [ + 'not_registered' => "':name'は、ウィジット名として登録されていません。", + 'not_bound' => "ウィジットクラス名の':name'は、コントローラーと結び付けられていません。", + ], + 'page' => [ + 'untitled' => "タイトル無し", + ], + 'partial' => [ + 'not_found' => "':name'パーシャルは見つかりません。", + ], + 'account' => [ + 'sign_out' => 'ログアウト', + 'login' => 'ログイン', + 'reset' => 'リセット', + 'restore' => '元に戻す', + 'login_placeholder' => 'ユーザー名', + 'password_placeholder' => 'パスワード', + 'forgot_password' => "パスワードを忘れましたか?", + 'enter_email' => "メールアドレスを入力してください", + 'enter_login' => "ユーザー名を入力してください", + 'email_placeholder' => "メールアドレス", + 'enter_new_password' => "新パスワードを入力してください", + 'password_reset' => "パスワードリセット", + 'restore_success' => "パスワードを元に戻すための手順を説明したメールを送信しました。", + 'restore_error' => "':login'というユーザーは登録されていません。", + 'reset_success' => "パスワードがリセットされました。", + 'reset_error' => "間違ったパスワードリセットデーターが送信されました。再実行してください。", + 'reset_fail' => "パスワードをリセットできませんでした。", + 'apply' => '適用', + 'cancel' => 'キャンセル', + 'delete' => '削除', + 'ok' => 'OK', + ], + 'dashboard' => [ + 'menu_label' => 'ダッシュボード', + ], + 'user' => [ + 'name' => '管理者', + 'menu_label' => '管理者', + 'list_title' => '管理者管理', + 'new' => '新管理者', + 'login' => "ログイン", + 'first_name' => "名", + 'last_name' => "氏", + 'full_name' => "氏名", + 'email' => "メールアドレス", + 'groups' => "グループ", + 'groups_comment' => "このユーザー所属が所属するグループを指定してください。", + 'avatar' => "アバター", + 'password' => "パスワード", + 'password_confirmation' => "パスワード確認", + 'superuser' => "スーパーユーザー", + 'superuser_comment' => "全領域へのアクセスをこのユーザーに許可する場合、ボックスをチェックしてください。", + 'send_invite' => 'メールにより招待送信', + 'send_invite_comment' => 'このユーザーに、メールで招待状を送る場合、ボックスをチェックしてください。', + 'delete_confirm' => 'この管理者を本当に削除しますか?', + 'return' => '管理者リストに戻る', + 'group' => [ + 'name' => 'グループ', + 'name_field' => '名前', + 'menu_label' => 'グループ', + 'list_title' => 'グループ管理', + 'new' => '新管理者グループ', + 'delete_confirm' => '本当にこの管理者グループを削除しますか?', + 'return' => 'グループリストへ戻る', + ], + 'preferences' => [ + 'not_authenticated' => '設定を読み込み/保存する、認証されたユーザーが存在していません。' + ] + ], + 'list' => [ + 'default_title' => 'リスト', + 'search_prompt' => '検索…', + 'no_records' => 'このビューにはレコードがありません。', + 'missing_model' => ':classクラスの中のリストビヘイビアーにモデルがありません。', + 'missing_column' => ':columnsに対する、カラム定義がありません。', + 'missing_columns' => ':classクラスの中のリストには、リストするカラムが定義されていません。', + 'missing_definition' => "リストビヘイビアーは、':field'に対するカラムを持っていません。", + 'behavior_not_ready' => 'リストビヘイビアーは初期化されていません。コントローラーで、makeLists()を呼び出しているか確認してください。', + ], + 'form' => [ + 'create_title' => "新規 :name", + 'update_title' => "編集 :name", + 'preview_title' => "プレビュー :name", + 'create_success' => ':nameを作成しました。', + 'update_success' => ':nameを更新しました。', + 'delete_success' => ':nameを削除しました。', + 'missing_id' => "フォームのレコードIDが指定されていません。", + 'missing_model' => ':classクラスで使用している、フォームビヘイビアーは、モデル定義を持っていません。', + 'missing_definition' => "フォームビヘイビアーは、':field'フィールドを持っていません。", + 'not_found' => 'IDが:idのフォームレコードが見つかりません。', + 'create' => '作成', + 'create_and_close' => '作成後閉じる', + 'creating' => '作成中…', + 'save' => '保存', + 'save_and_close' => '保存後閉じる', + 'saving' => '保存中…', + 'delete' => '削除', + 'deleting' => '削除中…', + 'undefined_tab' => 'その他', + 'field_off' => '無効', + 'field_on' => '有効', + 'apply' => '適用', + 'cancel' => 'キャンセル', + 'close' => 'クローズ', + 'ok' => 'OK', + 'or' => 'または', + 'confirm_tab_close' => '本当にタブを閉じますか? 保存されていない変更は消えてしまいます。', + 'behavior_not_ready' => 'フォームビヘイビアーは初期化されていません。コントローラーでinitForm()を呼び出しているか確認してください。', + ], + 'relation' => [ + 'missing_definition' => "リレーションビヘイビアーは、':field'フィールドに対する定義を持っていません。", + 'missing_model' => ":classクラスで使用している、リレーションビヘイビアーは、モデル定義を持っていません。", + 'invalid_action_single' => "このアクションは、単一リレーションでは実行できません。", + 'invalid_action_multi' => "このアクションは、複数リレーションでは実行できません。", + 'add' => "追加", + 'add_name' => "追加 :name", + 'create' => "作成", + 'create_name' => "作成 :name", + 'remove' => "削除", + 'remove_name' => "削除 :name", + 'delete' => "削除", + 'delete_name' => "削除 :name", + ], + 'model' => [ + 'name' => "Model", + 'not_found' => "IDが:idの、':class'モデルは見つかりません。", + 'missing_id' => "モデルレコードを探すためのIDが、指定されていません。", + 'missing_relation' => "':class'モデルは、':relation'の定義を持っていません。", + 'invalid_class' => ":classクラスで使用している、:modelモデルは正しくありません。\Modelクラスを継承してください。", + ], +]; diff --git a/modules/backend/lang/sv/lang.php b/modules/backend/lang/sv/lang.php index d242b6c75..3e5d19b86 100644 --- a/modules/backend/lang/sv/lang.php +++ b/modules/backend/lang/sv/lang.php @@ -45,8 +45,8 @@ return [ 'name' => 'Administratör', 'menu_label' => 'Administratörer', 'list_title' => 'Hantera administratörer', - 'new' => 'New Administrator', - 'login' => "Logga in", + 'new' => 'Ny Administratör', + 'login' => "Användarnamn", 'first_name' => "Förnamn", 'last_name' => "Efternamn", 'full_name' => "Fullständigt namn", @@ -60,16 +60,16 @@ return [ 'superuser_comment' => "Markera denna checkbox för att ge denna person tillgång till alla områden", 'send_invite' => 'Inbjudan är sänd via e-post', 'send_invite_comment' => 'Markera denna checkbox för att skicka en inbjudan till användaren via e-post', - 'delete_confirm' => 'Do you really want to delete this administrator?', - 'return' => 'Return to the administrator list', + 'delete_confirm' => 'Vill du verkligen radera denna administratör?', + 'return' => 'Återgå till administratörlistan', 'group' => [ 'name' => 'Grupp', 'name_field' => 'Namn', 'menu_label' => 'Grupper', 'list_title' => 'Hantera grupper', - 'new' => 'New Administrator Group', - 'delete_confirm' => 'Do you really want to delete this administrator group?', - 'return' => 'Return to the group list', + 'new' => 'New administratörgrupp', + 'delete_confirm' => 'Vill du verkligen radera denna administratörgrupp?', + 'return' => 'Återgå till grupplistan', ], 'preferences' => [ 'not_authenticated' => 'Det finns ingen autentiserad användare att ladda eller spara inställningar för', @@ -96,14 +96,14 @@ return [ 'missing_model' => 'Formuläregenskapen som används i :class har ingen modell definierad', 'missing_definition' => "Formuläregenskapen saknar ett fält för ':field'", 'not_found' => 'Record ID :id för formuläret kunde ej hittas', - 'create' => 'Create', - 'create_and_close' => 'Create and close', - 'creating' => 'Creating...', + 'create' => 'Skapa', + 'create_and_close' => 'Skapa och stäng', + 'creating' => 'Skapar...', 'save' => 'Spara', 'save_and_close' => 'Spara och stäng', 'saving' => 'Sparar...', 'delete' => 'Radera', - 'deleting' => 'Deleting...', + 'deleting' => 'Raderar...', 'undefined_tab' => 'Övrigt', 'field_off' => 'Av', 'field_on' => 'På', @@ -111,7 +111,7 @@ return [ 'cancel' => 'Avbryt', 'close' => 'Stäng', 'ok' => 'OK', - 'or' => 'or', + 'or' => 'eller', 'confirm_tab_close' => 'Vill du verkligen stänga fliken? Ej sparade ändringar kommer gå förlorade', 'behavior_not_ready' => 'Formuläregenskap har ej blivit initierad, kontrollera att du anropat initForm() i din controller', ], diff --git a/modules/cms/classes/CmsCompoundObject.php b/modules/cms/classes/CmsCompoundObject.php index bb4190a4b..306f372e5 100644 --- a/modules/cms/classes/CmsCompoundObject.php +++ b/modules/cms/classes/CmsCompoundObject.php @@ -49,6 +49,7 @@ class CmsCompoundObject extends CmsObject /** * Loads the object from a file. + * @param \Cms\Classes\Theme $theme Specifies the theme the object belongs to. * @param string $fileName Specifies the file name, with the extension. * The file name can contain only alphanumeric symbols, dashes and dots. * @return boolean Returns true if the object was successfully loaded. Otherwise returns false. @@ -152,7 +153,7 @@ class CmsCompoundObject extends CmsObject } /** - * Sets the PHP code content stirng. + * Sets the PHP code content string. * @param string $value Specifies the PHP code string. * @return \Cms\Classes\CmsCompoundObject Returns the object instance. */ diff --git a/modules/cms/classes/CmsException.php b/modules/cms/classes/CmsException.php index 6593a7da0..603e20e1f 100644 --- a/modules/cms/classes/CmsException.php +++ b/modules/cms/classes/CmsException.php @@ -57,9 +57,9 @@ class CmsException extends ApplicationException } /** - * Checks some conditions to confirm error has actually occured + * Checks some conditions to confirm error has actually occurred * due to the CMS template code, not some external code. If the error - * has occured in external code, the function will return false. Otherwise return + * has occurred in external code, the function will return false. Otherwise return * true and modify the exception by overriding it's content, line and message values * to be accurate against a CMS object properties. * @param \Exception $exception The exception to modify. @@ -152,7 +152,7 @@ class CmsException extends ApplicationException return false; } /* - * Errors occuring the PHP code base class (Cms\Classes\CodeBase) + * Errors occurring the PHP code base class (Cms\Classes\CodeBase) */ else { $trace = $exception->getTrace(); diff --git a/modules/cms/classes/CmsObject.php b/modules/cms/classes/CmsObject.php index 171aa7191..80113eedf 100644 --- a/modules/cms/classes/CmsObject.php +++ b/modules/cms/classes/CmsObject.php @@ -211,7 +211,7 @@ class CmsObject /** * Helper for {{ page.id }} or {{ layout.id }} twig vars - * Returns a unqiue string for this object. + * Returns a unique string for this object. * @return string */ public function getId() diff --git a/modules/cms/classes/CombineAssets.php b/modules/cms/classes/CombineAssets.php index f1a948a0b..715fc1044 100644 --- a/modules/cms/classes/CombineAssets.php +++ b/modules/cms/classes/CombineAssets.php @@ -89,7 +89,7 @@ class CombineAssets $this->registerFilter('less', new \Assetic\Filter\LessphpFilter); /* - * Minifcation filters + * Minification filters */ if ($this->useMinify) { $this->registerFilter('js', new \Assetic\Filter\JSMinFilter); @@ -114,7 +114,7 @@ class CombineAssets * Combines asset file references of a single type to produce * a URL reference to the combined contents. * @var array List of asset files. - * @var string File extension, used for asthetic purposes only. + * @var string File extension, used for aesthetic purposes only. * @return string URL to contents. */ protected function prepareRequest(array $assets, $path = null) @@ -186,7 +186,7 @@ class CombineAssets /** * Returns the URL used for accessing the combined files. - * @param string $outputFileName A custom file name to use. + * @param string $outputFilename A custom file name to use. * @return string */ protected function getCombinedUrl($outputFilename = 'undefined.css') diff --git a/modules/cms/classes/Controller.php b/modules/cms/classes/Controller.php index b201ca361..72e50376b 100644 --- a/modules/cms/classes/Controller.php +++ b/modules/cms/classes/Controller.php @@ -166,8 +166,8 @@ class Controller extends BaseController /* * Execute page lifecycle */ - if ($cycleReponse = $this->execPageCycle()) - return $cycleReponse; + if ($cycleResponse = $this->execPageCycle()) + return $cycleResponse; /* * Render the page @@ -566,7 +566,7 @@ class Controller extends BaseController * * @param mixed $name Specifies the Cms Page file name. * @param array $parameters Route parameters to consider in the URL. - * @param bool $routePersistence By default the exisiting routing parameters will be included + * @param bool $routePersistence By default the existing routing parameters will be included * when creating the URL, set to false to disable this feature. * @return string */ diff --git a/modules/cms/classes/FileHelper.php b/modules/cms/classes/FileHelper.php index a76ca1148..7edd70e7d 100644 --- a/modules/cms/classes/FileHelper.php +++ b/modules/cms/classes/FileHelper.php @@ -12,7 +12,7 @@ class FileHelper * Validates a CMS object file or directory name. * CMS object file names can contain only alphanumeric symbols, dashes, underscores and dots. * Name can also begin with a component name, eg: MyComponent::filename. - * @param string $filePath Specifies a path to validate + * @param string $fileName Specifies a path to validate * @return boolean Returns true if the file name is valid. Otherwise returns false. */ public static function validateName($fileName) @@ -22,7 +22,7 @@ class FileHelper /** * Validates whether a file has an allowed extension. - * @param string $filePath Specifies a path to validate + * @param string $fileName Specifies a path to validate * @param array $allowedExtensions A list of allowed file extensions * @param boolean $allowEmpty Determines whether the file extension could be empty. * @return boolean Returns true if the file extension is valid. Otherwise returns false. @@ -40,6 +40,7 @@ class FileHelper * Validates a CMS object path. * CMS object directory and file names can contain only alphanumeric symbols, dashes and dots. * CMS objects support only a single level of subdirectories. + * @param string $filePath Specifies a path to validate * @param integer $maxNesting Specifies the maximum allowed nesting level * @return boolean Returns true if the file name is valid. Otherwise returns false. */ @@ -65,6 +66,7 @@ class FileHelper /** * Formats an INI file string from an array * @param array $data Data to format. + * @param int $level Specifies the level of array value. * @return string Returns the INI file string. */ public static function formatIniString($data, $level = 1) diff --git a/modules/cms/classes/Router.php b/modules/cms/classes/Router.php index c08ee78d3..c37d88d51 100644 --- a/modules/cms/classes/Router.php +++ b/modules/cms/classes/Router.php @@ -56,7 +56,7 @@ class Router /** * Creates the router instance. - * @param \Cms\ClassesTheme $theme Specifies the theme being processed. + * @param \Cms\Classes\Theme $theme Specifies the theme being processed. */ public function __construct(Theme $theme) { diff --git a/modules/cms/classes/SectionParser.php b/modules/cms/classes/SectionParser.php index b8da6f4dc..90da6efbf 100644 --- a/modules/cms/classes/SectionParser.php +++ b/modules/cms/classes/SectionParser.php @@ -97,8 +97,8 @@ class SectionParser /** * Returns the line number of a found instance of CMS object section separator (==). - * @param $content Object content - * @param $instance Which instance to look for + * @param string $content Object content + * @param int $instance Which instance to look for * @return int The line number the instance was found. */ private static function calculateLinePosition($content, $instance = 1) @@ -120,8 +120,8 @@ class SectionParser * Pushes the starting line number forward since it is not always directly * after the separator (==). There can be an opening tag or white space in between * where the section really begins. - * @param $content Object content - * @param $startLine The calculated starting line from calculateLinePosition() + * @param string $content Object content + * @param int $startLine The calculated starting line from calculateLinePosition() * @return int The adjusted line number. */ private static function adjustLinePosition($content, $startLine = -1) diff --git a/modules/cms/classes/Theme.php b/modules/cms/classes/Theme.php index 627a86723..a534c3c96 100644 --- a/modules/cms/classes/Theme.php +++ b/modules/cms/classes/Theme.php @@ -60,8 +60,8 @@ class Theme /** * Returns the active theme. * By default the active theme is loaded from the cms.activeTheme parameter, - * but this behavior can be overriden by the cms.activeTheme event listeners. - * @return \Cms\Classes\Theme Returns the loaded theme objesct. + * but this behavior can be overridden by the cms.activeTheme event listeners. + * @return \Cms\Classes\Theme Returns the loaded theme object. * If the theme doesn't exist, returns null. */ public static function getActiveTheme() @@ -86,10 +86,10 @@ class Theme /** * Returns the edit theme. * By default the edit theme is loaded from the cms.editTheme parameter, - * but this behavior can be overriden by the cms.editTheme event listeners. + * but this behavior can be overridden by the cms.editTheme event listeners. * If the edit theme is not defined in the configuration file, the active theme * is returned. - * @return \Cms\Classes\Theme Returns the loaded theme objesct. + * @return \Cms\Classes\Theme Returns the loaded theme object. * If the theme doesn't exist, returns null. */ public static function getEditTheme() diff --git a/modules/cms/lang/ja/lang.php b/modules/cms/lang/ja/lang.php new file mode 100644 index 000000000..9082fdf6c --- /dev/null +++ b/modules/cms/lang/ja/lang.php @@ -0,0 +1,152 @@ + [ + 'invalid_file' => '正しくないファイル名::name。ファイル名は英文字、下線(_)、ダッシュ(-)、ピリオド(.)で構成されなくてはなりません。(正しいファイル名の例:page, page.htm, subdirectory/page)', + 'invalid_property' => '":name"プロパティーをセットできません。', + 'file_already_exists' => '":name"ファイルは既に存在しています。', + 'error_saving' => '":name"ファイル保存エラー', + 'error_creating_directory' => ':nameディレクトリー作成エラー', + 'invalid_file_extension'=>'正しくないファイル拡張子::invalid。許されている拡張子は、:allowedです。', + 'error_deleting' => '":name"一時ファイル削除エラー', + 'delete_success' => ':count個のテンプレートを削除しました。', + 'file_name_required' => 'ファイル名フィールドが必要です。' + ], + 'theme' => [ + 'active' => [ + 'not_set' => "アクティブなテーマがセットされていません。", + ], + 'edit' => [ + 'not_set' => "編集テーマがセットされていません。", + 'not_found' => "編集テーマが見つかりません。", + 'not_match' => "アクセスしようとしてるオブジェクトは、編集中のテーマに所属していません。ページを再読込してください。" + ] + ], + 'page' => [ + 'not_found' => [ + 'label' => "ページが見つかりません。", + 'help' => "要求されているページが見つかりません。", + ], + 'custom_error' => [ + 'label' => "ページエラー。", + 'help' => "恐れいります。何かが間違っているようで、ページが表示できません。", + ], + 'menu_label' => 'ページ', + 'no_list_records' => 'ページが見つかりません', + 'new' => '新ページ', + 'invalid_url' => '正しくないURL形式。URLはスラッシュ(/)で始まり、数字、ラテン文字、_-[]:?|/+*で構成します。', + 'delete_confirm_multiple' => '指定した全ページを本当に削除しますか?', + 'delete_confirm_single' => '本当にこのページを削除しますか?', + 'no_layout' => '-- レイアウト無し --' + ], + 'layout' => [ + 'not_found' => "レイアウト':name'が見つかりません。", + 'menu_label' => 'レイアウト', + 'no_list_records' => 'レイアウトが見つかりません', + 'new' => '新レイアウト', + 'delete_confirm_multiple' => '指定した全ページを本当に削除しますか?', + 'delete_confirm_single' => '本当にこのページを削除しますか?' + ], + 'partial' => [ + 'invalid_name' => "正しくないパーシャル名::name。", + 'not_found' => "':name'パーシャルが見つかりません。", + 'menu_label' => 'パーシャル', + 'no_list_records' => 'パーシャルが見つかりません。', + 'delete_confirm_multiple' => '指定した全パーシャルを本当に削除しますか?', + 'delete_confirm_single' => '本当にこのパーシャルを削除しますか?', + 'new' => '新パーシャル' + ], + 'content' => [ + 'not_found' => "':name'コンテンツファイルが見つかりません。", + 'menu_label' => 'コンテンツ', + 'no_list_records' => 'コンテンツファイルが見つかりません', + 'delete_confirm_multiple' => '指定した全コンテンツファイル/ディレクトリーを本当に削除しますか?', + 'delete_confirm_single' => '本当にこのコンテンツファイルを削除しますか?', + 'new' => '新コンテンツファイル' + ], + 'ajax_handler' => [ + 'invalid_name' => "正しくないAJAXハンドラー名::name。", + 'not_found' => "':name' AJAXハンドラーが見つかりません。", + ], + 'combiner' => [ + 'not_found' => "':name'コンバイナーファイルが見つかりません。", + ], + 'cms' => [ + 'menu_label' => "CMS" + ], + 'sidebar' => [ + 'add' => '追加', + 'search' => '検索…' + ], + 'editor' => [ + 'settings' => '設定', + 'title' => 'タイトル', + 'new_title' => '新ページタイトル', + 'url' => 'URL', + 'filename' => 'ファイル名', + 'layout' => 'レイアウト', + 'description' => '説明', + 'preview' => 'プレビュー', + 'meta' => 'メタ', + 'meta_title' => 'メタタイトル', + 'meta_description' => 'メタ説明', + 'markup' => 'マークアップ', + 'code' => 'コード', + 'content' => 'コンテンツ', + ], + 'asset' => [ + 'menu_label' => "アセット", + 'drop_down_add_title' => '追加…', + 'drop_down_operation_title' => 'アクション…', + 'upload_files' => 'ファイルアップロード', + 'create_file' => 'ファイル作成', + 'create_directory' => 'ディレクトリー作成', + 'rename' => '名前変更', + 'delete' => '削除', + 'move' => '移動', + 'new' => '新ファイル', + 'rename_popup_title' => '名前変更', + 'rename_new_name' => '新しい名前', + 'invalid_path' => 'パスは数字、ラテン文字、空白、._-/で構成されなくてはなりません。', + 'error_deleting_file' => ':nameファイル削除エラー。', + 'error_deleting_dir_not_empty' => ':nameディレクトリー削除エラー。ディレクトリーが空ではありません。', + 'error_deleting_dir' => ':nameディレクトリー削除エラー。', + 'invalid_name' => '名前は数字、ラテン文字、空白、._-で構成されなくてはなりません。', + 'original_not_found' => '元のファイル/ディレクトリーが見つかりません', + 'already_exists' => 'この名前のファイル/ディレクトリーは既に存在します。', + 'error_renaming' => 'ファイル/ディレクトリー名前変更エラー', + 'name_cant_be_empty' => '名前は空白にできません', + 'too_large' => 'アップロードファイルは大きすぎます。ファイルサイズは最大で、:max_sizeです。', + 'type_not_allowed' => '許可されているファイルタイプは、:allowed_typesだけです。', + 'file_not_valid' => 'ファイルが正しくありません。', + 'error_uploading_file' => '":name":ファイルアップロードエラー。(:error)', + 'move_please_select' => '選択してください', + 'move_destination' => '移動先ディレクトリー', + 'move_popup_title' => 'アセット移動', + 'move_button' => '移動', + 'selected_files_not_found' => '選択されたファイルは存在しません。', + 'select_destination_dir' => '移動先ディレクトリーを選択してください', + 'destination_not_found' => '移動先ディレクトリーは存在しません。', + 'error_moving_file' => ':fileファイル移動エラー', + 'error_moving_directory' => ':dirディレクトリー移動エラー', + 'error_deleting_directory' => '移動元:dirディレクトリー削除エラー', + 'path' => 'パス' + ], + 'component' => [ + 'menu_label' => "コンポーネント", + 'unnamed' => "名前なし", + 'no_description' => "説明なし", + 'alias' => "エイリアス", + 'alias_description' => "ページやレイアウトコードの中で使用される、一意のコンポーネント名。", + 'validation_message' => "ラテン文字、数字、下線(_)で構成された、コンポーネントエイリアスが必要です。エイリアスはラテン文字で始まらなくてなりません。", + 'invalid_request' => "コンポーネントデータが正しくないため、テンプレートは保存できません。", + 'no_records' => 'コンポーネントが見つかりません。', + 'not_found' => "':name'コンポーネントが見つかりません。", + 'method_not_found' => "':name'コンポーネントは、':method'メソッドを持っていません。", + ], + 'template' => [ + 'invalid_type' => "未知のテンプレートタイプ。", + 'not_found' => "リクエストされたテンプレートが見つかりません。", + 'saved'=> "テンプレートを保存しました。" + ] +]; diff --git a/modules/cms/lang/sv/lang.php b/modules/cms/lang/sv/lang.php index a48d38f81..ccc047f99 100644 --- a/modules/cms/lang/sv/lang.php +++ b/modules/cms/lang/sv/lang.php @@ -57,12 +57,12 @@ return [ 'new' => 'Ny partial' ], 'content' => [ - 'not_found' => "Content-filen ':name' kunde ej hittas", - 'menu_label' => 'Content', - 'no_list_records' => 'Inga content-filer funna', + 'not_found' => "Innehållet ':name' kunde ej hittas", + 'menu_label' => 'Innehåll', + 'no_list_records' => 'Inga innehållsfiler funna', 'delete_confirm_multiple' => 'Vill du verkligen radera markerade filer eller mappar?', - 'delete_confirm_single' => 'Vill du verkligen radera denna content-fil?', - 'new' => 'Ny content-fil' + 'delete_confirm_single' => 'Vill du verkligen radera detta innehållsfil?', + 'new' => 'Ny innehållsfil' ], 'ajax_handler' => [ 'invalid_name' => "Felaktig AJAX-hanterare: :name", @@ -75,27 +75,27 @@ return [ 'menu_label' => "CMS" ], 'sidebar' => [ - 'add' => 'Add', - 'search' => 'Search...' + 'add' => 'Lägg till', + 'search' => 'Sök...' ], 'editor' => [ - 'settings' => 'Settings', - 'title' => 'Title', - 'new_title' => 'New page title', + 'settings' => 'Inställningar', + 'title' => 'Titel', + 'new_title' => 'Ny sidtitel', 'url' => 'URL', - 'filename' => 'File Name', + 'filename' => 'Filnamn', 'layout' => 'Layout', - 'description' => 'Description', - 'preview' => 'Preview', + 'description' => 'Beskrivning', + 'preview' => 'Förhandsgranska', 'meta' => 'Meta', - 'meta_title' => 'Meta Title', - 'meta_description' => 'Meta Description', + 'meta_title' => 'Meta-titel', + 'meta_description' => 'Meta-beskrivning', 'markup' => 'Markup', - 'code' => 'Code', - 'content' => 'Content', + 'code' => 'Kod', + 'content' => 'Innehåll', ], 'asset' => [ - 'menu_label' => "Assets", + 'menu_label' => "Filsystem", 'drop_down_add_title' => 'Lägg till...', 'drop_down_operation_title' => 'Åtgärd...', 'upload_files' => 'Ladda upp fil(er)', @@ -122,7 +122,7 @@ return [ 'error_uploading_file' => 'Ett fel uppstod vid uppladdning av ":name" :error', 'move_please_select' => 'Var god välj', 'move_destination' => 'Destionationsmapp', - 'move_popup_title' => 'Flytta assets', + 'move_popup_title' => 'Flytta objekt', 'move_button' => 'Flytta', 'selected_files_not_found' => 'Valda filer kunde ej hittas', 'select_destination_dir' => 'Var god välj en destinationsmapp', @@ -133,7 +133,7 @@ return [ 'path' => 'Sökväg' ], 'component' => [ - 'menu_label' => "Komponent", + 'menu_label' => "Komponenter", 'unnamed' => "Ej namngiven", 'no_description' => "Ingen beskrivning", 'alias' => "Alias", diff --git a/modules/cms/twig/ComponentNode.php b/modules/cms/twig/ComponentNode.php index 14b018f08..5b8e80e04 100644 --- a/modules/cms/twig/ComponentNode.php +++ b/modules/cms/twig/ComponentNode.php @@ -20,7 +20,7 @@ class ComponentNode extends Twig_Node /** * Compiles the node to PHP. * - * @param Twig_Compiler A Twig_Compiler instance + * @param Twig_Compiler $compiler A Twig_Compiler instance */ public function compile(Twig_Compiler $compiler) { diff --git a/modules/cms/twig/ContentNode.php b/modules/cms/twig/ContentNode.php index 85ffeda1b..33e01e179 100644 --- a/modules/cms/twig/ContentNode.php +++ b/modules/cms/twig/ContentNode.php @@ -20,7 +20,7 @@ class ContentNode extends Twig_Node /** * Compiles the node to PHP. * - * @param Twig_Compiler A Twig_Compiler instance + * @param Twig_Compiler $compiler A Twig_Compiler instance */ public function compile(Twig_Compiler $compiler) { diff --git a/modules/cms/twig/DefaultNode.php b/modules/cms/twig/DefaultNode.php index 25c2e625a..9c501b968 100644 --- a/modules/cms/twig/DefaultNode.php +++ b/modules/cms/twig/DefaultNode.php @@ -19,7 +19,7 @@ class DefaultNode extends Twig_Node /** * Compiles the node to PHP. * - * @param Twig_Compiler A Twig_Compiler instance + * @param Twig_Compiler $compiler A Twig_Compiler instance */ public function compile(Twig_Compiler $compiler) { diff --git a/modules/cms/twig/Extension.php b/modules/cms/twig/Extension.php index 2f5a1db2f..bfd142415 100644 --- a/modules/cms/twig/Extension.php +++ b/modules/cms/twig/Extension.php @@ -222,7 +222,7 @@ class Extension extends Twig_Extension * Looks up the URL for a supplied page and returns it relative to the website root. * @param mixed $name Specifies the Cms Page file name. * @param array $parameters Route parameters to consider in the URL. - * @param bool $routePersistence By default the exisiting routing parameters will be included + * @param bool $routePersistence By default the existing routing parameters will be included * when creating the URL, set to false to disable this feature. * @return string */ diff --git a/modules/cms/twig/FlashNode.php b/modules/cms/twig/FlashNode.php index 0a4921886..fc53f3319 100644 --- a/modules/cms/twig/FlashNode.php +++ b/modules/cms/twig/FlashNode.php @@ -21,7 +21,7 @@ class FlashNode extends Twig_Node /** * Compiles the node to PHP. * - * @param Twig_Compiler A Twig_Compiler instance + * @param Twig_Compiler $compiler A Twig_Compiler instance */ public function compile(Twig_Compiler $compiler) { diff --git a/modules/cms/twig/FrameworkNode.php b/modules/cms/twig/FrameworkNode.php index dec67a13d..b7daaa0b2 100644 --- a/modules/cms/twig/FrameworkNode.php +++ b/modules/cms/twig/FrameworkNode.php @@ -19,7 +19,7 @@ class FrameworkNode extends Twig_Node /** * Compiles the node to PHP. * - * @param Twig_Compiler A Twig_Compiler instance + * @param Twig_Compiler $compiler A Twig_Compiler instance */ public function compile(Twig_Compiler $compiler) { diff --git a/modules/cms/twig/Loader.php b/modules/cms/twig/Loader.php index 7f5311cd9..501d29e7f 100644 --- a/modules/cms/twig/Loader.php +++ b/modules/cms/twig/Loader.php @@ -18,7 +18,7 @@ class Loader implements Twig_LoaderInterface /** * Sets a CMS object to load the template from. - * @param \Cms\CmsObject $obj Specifies the CMS object. + * @param \Cms\Classes\CmsObject $obj Specifies the CMS object. */ public function setObject(CmsObject $obj) { diff --git a/modules/cms/twig/PageNode.php b/modules/cms/twig/PageNode.php index 8bfac8488..ba3dcaf1c 100644 --- a/modules/cms/twig/PageNode.php +++ b/modules/cms/twig/PageNode.php @@ -19,7 +19,7 @@ class PageNode extends Twig_Node /** * Compiles the node to PHP. * - * @param Twig_Compiler A Twig_Compiler instance + * @param Twig_Compiler $compiler A Twig_Compiler instance */ public function compile(Twig_Compiler $compiler) { diff --git a/modules/cms/twig/PartialNode.php b/modules/cms/twig/PartialNode.php index 8b6b8100e..297446e93 100644 --- a/modules/cms/twig/PartialNode.php +++ b/modules/cms/twig/PartialNode.php @@ -20,7 +20,7 @@ class PartialNode extends Twig_Node /** * Compiles the node to PHP. * - * @param Twig_Compiler A Twig_Compiler instance + * @param Twig_Compiler $compiler A Twig_Compiler instance */ public function compile(Twig_Compiler $compiler) { diff --git a/modules/cms/twig/PlaceholderNode.php b/modules/cms/twig/PlaceholderNode.php index f545142e2..6b25e4235 100644 --- a/modules/cms/twig/PlaceholderNode.php +++ b/modules/cms/twig/PlaceholderNode.php @@ -24,7 +24,7 @@ class PlaceholderNode extends Twig_Node /** * Compiles the node to PHP. * - * @param Twig_Compiler A Twig_Compiler instance + * @param Twig_Compiler $compiler A Twig_Compiler instance */ public function compile(Twig_Compiler $compiler) { diff --git a/modules/cms/twig/PlaceholderTokenParser.php b/modules/cms/twig/PlaceholderTokenParser.php index 999bf6c1e..c66502680 100644 --- a/modules/cms/twig/PlaceholderTokenParser.php +++ b/modules/cms/twig/PlaceholderTokenParser.php @@ -9,7 +9,7 @@ use Twig_TokenParser; *
* {% placeholder head %}
*
- * or - use default placeholer content
+ * or - use default placeholder content
*
* {% placeholder head %}
*
diff --git a/modules/cms/twig/PutNode.php b/modules/cms/twig/PutNode.php
index b8ff1d9cf..ad224571f 100644
--- a/modules/cms/twig/PutNode.php
+++ b/modules/cms/twig/PutNode.php
@@ -20,7 +20,7 @@ class PutNode extends Twig_Node
/**
* Compiles the node to PHP.
*
- * @param Twig_Compiler A Twig_Compiler instance
+ * @param Twig_Compiler $compiler A Twig_Compiler instance
*/
public function compile(Twig_Compiler $compiler)
{
diff --git a/modules/cms/twig/ScriptsNode.php b/modules/cms/twig/ScriptsNode.php
index bc88c155a..6545d5ab3 100644
--- a/modules/cms/twig/ScriptsNode.php
+++ b/modules/cms/twig/ScriptsNode.php
@@ -19,7 +19,7 @@ class ScriptsNode extends Twig_Node
/**
* Compiles the node to PHP.
*
- * @param Twig_Compiler A Twig_Compiler instance
+ * @param Twig_Compiler $compiler A Twig_Compiler instance
*/
public function compile(Twig_Compiler $compiler)
{
diff --git a/modules/cms/twig/StylesNode.php b/modules/cms/twig/StylesNode.php
index 3d3b2f1d7..5dc26ed8f 100644
--- a/modules/cms/twig/StylesNode.php
+++ b/modules/cms/twig/StylesNode.php
@@ -19,7 +19,7 @@ class StylesNode extends Twig_Node
/**
* Compiles the node to PHP.
*
- * @param Twig_Compiler A Twig_Compiler instance
+ * @param Twig_Compiler $compiler A Twig_Compiler instance
*/
public function compile(Twig_Compiler $compiler)
{
diff --git a/modules/cms/widgets/AssetList.php b/modules/cms/widgets/AssetList.php
index 3de4114dc..f26069328 100644
--- a/modules/cms/widgets/AssetList.php
+++ b/modules/cms/widgets/AssetList.php
@@ -346,12 +346,11 @@ class AssetList extends WidgetBase
protected function getData()
{
- $result = [];
$assetsPath = $this->getAssetsPath();
if (!file_exists($assetsPath) || !is_dir($assetsPath)) {
if (!@mkdir($assetsPath))
- throw new ApplicationException(Lang::get('cms::lang.cms_object.error_creating_directory', ['name'=>$path]));
+ throw new ApplicationException(Lang::get('cms::lang.cms_object.error_creating_directory', ['name'=>$assetsPath]));
}
$searchTerm = Str::lower($this->getSearchTerm());
diff --git a/modules/system/ServiceProvider.php b/modules/system/ServiceProvider.php
index 663256e42..51dc4484d 100644
--- a/modules/system/ServiceProvider.php
+++ b/modules/system/ServiceProvider.php
@@ -32,7 +32,7 @@ class ServiceProvider extends ModuleServiceProvider
parent::register('system');
/*
- * Reregister core providers
+ * Register core providers
*/
App::register('October\Rain\Config\ConfigServiceProvider');
App::register('October\Rain\Translation\TranslationServiceProvider');
diff --git a/modules/system/behaviors/SettingsModel.php b/modules/system/behaviors/SettingsModel.php
index 70e958928..8cdec83ab 100644
--- a/modules/system/behaviors/SettingsModel.php
+++ b/modules/system/behaviors/SettingsModel.php
@@ -166,7 +166,7 @@ class SettingsModel extends ModelBehavior
}
/**
- * Checks if a key is legitamite or should be added to
+ * Checks if a key is legitimate or should be added to
* the field value collection
*/
private function isKeyAllowed($key)
diff --git a/modules/system/classes/ErrorHandler.php b/modules/system/classes/ErrorHandler.php
index bd8046246..c206058c8 100644
--- a/modules/system/classes/ErrorHandler.php
+++ b/modules/system/classes/ErrorHandler.php
@@ -27,7 +27,7 @@ class ErrorHandler
/**
* All exceptions are piped through this method from the framework workflow. This method will mask
- * any foriegn exceptions with a "scent" of the native application's exception, so it can render
+ * any foreign exceptions with a "scent" of the native application's exception, so it can render
* correctly when displayed on the error page.
* @param Exception $proposedException The exception candidate that has been thrown.
* @return View Object containing the error page.
diff --git a/modules/system/classes/ExceptionBase.php b/modules/system/classes/ExceptionBase.php
index 39782ec85..7456103a2 100644
--- a/modules/system/classes/ExceptionBase.php
+++ b/modules/system/classes/ExceptionBase.php
@@ -209,7 +209,7 @@ class ExceptionBase extends Exception
* @return Array with stack information, each value will be an object with these values:
* id - The stack ID number.
* code - The class and function name being called.
- * args - The arguements passed to the code function above.
+ * args - The arguments passed to the code function above.
* file - Reference to the file containing the called code.
* line - Reference to the line number of the file.
*/
@@ -230,7 +230,7 @@ class ExceptionBase extends Exception
$args = null;
if (isset($event['args']) && count($event['args'])) {
- $args = $this->formatStackArguements($event['args'], false);
+ $args = $this->formatStackArguments($event['args'], false);
}
$result[] = (object)[
@@ -293,7 +293,7 @@ class ExceptionBase extends Exception
* @param array arguments A list of the function or method arguments
* @return string
*/
- protected function formatStackArguements($arguments)
+ protected function formatStackArguments($arguments)
{
$argsArray = array();
foreach ($arguments as $argument) {
diff --git a/modules/system/classes/UpdateManager.php b/modules/system/classes/UpdateManager.php
index c3e997fa5..3ac8931bb 100644
--- a/modules/system/classes/UpdateManager.php
+++ b/modules/system/classes/UpdateManager.php
@@ -594,7 +594,7 @@ class UpdateManager
}
/**
- * Create a nonce based on milisecond time
+ * Create a nonce based on millisecond time
* @return int
*/
private function createNonce()
diff --git a/modules/system/classes/VersionManager.php b/modules/system/classes/VersionManager.php
index 63733e875..2d08fe909 100644
--- a/modules/system/classes/VersionManager.php
+++ b/modules/system/classes/VersionManager.php
@@ -110,7 +110,7 @@ class VersionManager
}
/**
- * Applys a single version update to a plugin.
+ * Applies a single version update to a plugin.
*/
protected function applyPluginUpdate($code, $version, $details)
{
@@ -149,7 +149,7 @@ class VersionManager
*/
public function removePlugin($plugin)
{
- $code = (is_string($plugin)) ? $code : $this->pluginManager->getIdentifier($plugin);
+ $code = (is_string($plugin)) ? $plugin : $this->pluginManager->getIdentifier($plugin);
if (!$this->hasVersionFile($code))
return false;
diff --git a/modules/system/lang/de/lang.php b/modules/system/lang/de/lang.php
index 3952f09ab..a6c6dc404 100644
--- a/modules/system/lang/de/lang.php
+++ b/modules/system/lang/de/lang.php
@@ -33,8 +33,13 @@ return [
'help' => 'Wie Sie Ihre Projekt-ID finden',
'missing' => 'Bitte geben Sie eine Projekt-ID an.',
],
- 'detach_confirm_' => 'Are you sure you want to detach this project?',
+ 'detach_confirm' => 'Are you sure you want to detach this project?',
'unbind_success' => 'Projekt wurde erfolgreich getrennt (detached).',
+ ],
+ 'settings' => [
+ 'menu_label' => 'Einstellungen',
+ 'missing_model' => 'Der Einstellungsseite fehlt eine Model-Definition.',
+ 'update_success' => 'Einstellung für :name wurde erfolgreich aktualisiert.',
'return' => 'Return to system settings',
],
'email' => [
@@ -56,11 +61,6 @@ return [
'sendmail_path' => 'Sendmail Path',
'sendmail_path_comment' => 'Please specify the path of the sendmail program.',
],
- 'settings' => [
- 'menu_label' => 'Einstellungen',
- 'missing_model' => 'Der Einstellungsseite fehlt eine Model-Definition.',
- 'update_success' => 'Einstellung für :name wurde erfolgreich aktualisiert.',
- ],
'install' => [
'project_label' => 'Mit Projekt verbinden',
'plugin_label' => 'Plugin installieren',
diff --git a/modules/system/lang/en/lang.php b/modules/system/lang/en/lang.php
index 671ce5bef..dc2d50695 100644
--- a/modules/system/lang/en/lang.php
+++ b/modules/system/lang/en/lang.php
@@ -33,7 +33,7 @@ return [
'help' => 'How to find your Project ID',
'missing' => 'Please specify a Project ID to use.',
],
- 'detach_confirm_' => 'Are you sure you want to detach this project?',
+ 'detach_confirm' => 'Are you sure you want to detach this project?',
'unbind_success' => 'Project has been detached successfully.',
],
'settings' => [
diff --git a/modules/system/lang/ja/lang.php b/modules/system/lang/ja/lang.php
new file mode 100644
index 000000000..cc9d13b7c
--- /dev/null
+++ b/modules/system/lang/ja/lang.php
@@ -0,0 +1,125 @@
+ [
+ 'name' => 'October CMS',
+ 'motto' => '基本に戻ろう!',
+ ],
+ 'directory' => [
+ 'create_fail' => "ディレクトリーが作成できません: :name",
+ ],
+ 'file' => [
+ 'create_fail' => "ファイルが作成できません: :name",
+ ],
+ 'system' => [
+ 'name' => 'システム',
+ 'menu_label' => 'システム',
+ ],
+ 'plugin' => [
+ 'unnamed' => '名前なしプラグイン',
+ 'name' => [
+ 'label' => 'プラグイン名',
+ 'help' => '重複しないプラグイン名を付けてください。(例:RainLab.Blog)',
+ ],
+ ],
+ 'project' => [
+ 'name' => 'プロジェクト',
+ 'owner_label' => '所有者',
+ 'attach' => 'プロジェクト追加',
+ 'detach' => 'プロジェクト切り離し',
+ 'none' => '無し',
+ 'id' => [
+ 'label' => 'プロジェクトID',
+ 'help' => 'プロジェクトIDの見つけ方',
+ 'missing' => '使用するプロジェクトのIDを指定してください。',
+ ],
+ 'detach_confirm' => 'このプロジェクトを切り離しますか?',
+ 'unbind_success' => 'プロジェクトを切り離しました。',
+ ],
+ 'settings' => [
+ 'menu_label' => '設定',
+ 'missing_model' => 'モデルの定義が見つかりません。',
+ 'update_success' => ':name を設定しました。',
+ 'return' => 'システム設定へ戻る',
+ ],
+ 'email' => [
+ 'menu_label' => 'メール設定',
+ 'menu_description' => 'メール設定の管理',
+ 'general' => '全般',
+ 'method' => 'メール方法',
+ 'sender_name' => '送信者名',
+ 'sender_email' => '送信者メール',
+ 'smtp' => 'SMTP',
+ 'smtp_address' => 'SMTPアドレス',
+ 'smtp_authorization' => 'SMTP認証が必要',
+ 'smtp_authorization_comment' => 'SMTPサーバーの認証が必要な場合、チェックしてください。',
+ 'smtp_username' => 'ユーザー名',
+ 'smtp_password' => 'パスワード',
+ 'smtp_port' => 'SMTPポート',
+ 'smtp_ssl' => 'SSL接続が必要',
+ 'sendmail' => 'Sendmail',
+ 'sendmail_path' => 'Sendmailパス',
+ 'sendmail_path_comment' => 'Sendmailプログラムへのパスを指定してください。',
+ ],
+ 'install' => [
+ 'project_label' => 'プロジェクト追加',
+ 'plugin_label' => 'プラグインインストール',
+ 'missing_plugin_name' => 'インストールするプラグインの名前を指定してください。',
+ 'install_completing' => 'インストールを仕上げ中',
+ 'install_success' => 'プラグインをインストールしました。',
+ ],
+ 'updates' => [
+ 'title' => 'アップデート管理',
+ 'name' => 'ソフトウェアアップデート',
+ 'menu_label' => 'アップデート',
+ 'check_label' => 'アップデート確認',
+ 'retry_label' => '再実行',
+ 'plugin_name' => '名前',
+ 'plugin_description' => '説明',
+ 'plugin_version' => 'バージョン',
+ 'plugin_author' => '作者',
+ 'core_build' => '現在のビルド',
+ 'core_build_old' => '現在のビルド :build',
+ 'core_build_new' => 'ビルド :build',
+ 'core_build_new_help' => '新しいビルドが存在します。',
+ 'core_downloading' => 'アプリケーションファイルのダウンロード中',
+ 'core_extracting' => 'アプリケーションファイルの展開中',
+ 'plugin_downloading' => 'プラグインダウンロード中: :name',
+ 'plugin_extracting' => 'プラグイン展開中: :name',
+ 'plugin_version_none' => '新プラグイン',
+ 'plugin_version_old' => '現在 v:version',
+ 'plugin_version_new' => 'v:version',
+ 'update_label' => 'ソフトウェアアップデート',
+ 'update_completing' => 'アップデート仕上げ中',
+ 'update_loading' => 'アップデートロード中…',
+ 'update_success' => 'アップデートしました。',
+ 'update_failed_label' => 'アップデート失敗',
+ 'force_label' => '強制アップデート',
+ 'found' => [
+ 'label' => '新しいアップデートあり',
+ 'help' => 'アップデートしたいソフトウェアをクリックしてください。',
+ ],
+ 'none' => [
+ 'label' => 'アップデートなし',
+ 'help' => '新しいアップデートが見つかりません。',
+ ],
+ ],
+ 'server' => [
+ 'connect_error' => 'サーバー接続エラー。',
+ 'response_not_found' => '更新サーバーが見つかりません。',
+ 'response_invalid' => 'サーバーからの無効なレスポンス。',
+ 'response_empty' => 'サーバーから空のレスポンス。',
+ 'file_error' => 'サーバーがパッケージ配布に失敗。',
+ 'file_corrupt' => 'サーバーからのファイルが壊れています。',
+ ],
+ 'behavior' => [
+ 'missing_property' => ':class クラスは、 :behavior ビヘイビアーにより使用される、 :property プロパティーを定義する必要があります。',
+ ],
+ 'config' => [
+ 'not_found' => ':location で、 :file 設定ファイルが見つかりません。',
+ 'required' => ':location の中の設定で、値の指定が必要な、 :property が見つかりません。',
+ ],
+ 'zip' => [
+ 'extract_failed' => "コアファイル: ':file' が取り出せません。",
+ ],
+];
diff --git a/modules/system/lang/ja/validation.php b/modules/system/lang/ja/validation.php
new file mode 100644
index 000000000..21efc0e7e
--- /dev/null
+++ b/modules/system/lang/ja/validation.php
@@ -0,0 +1,99 @@
+ ":attributeを承認してください。",
+ "active_url" => ":attributeが有効なURLではありません。",
+ "after" => ":attributeには、:date以降の日付を指定してください。",
+ "alpha" => ":attributeはアルファベッドのみがご利用できます。",
+ "alpha_dash" => ":attributeは英数字とダッシュ(-)及び下線(_)がご利用できます。",
+ "alpha_num" => ":attributeは英数字がご利用できます。.",
+ "array" => ":attributeは配列でなくてはなりません。",
+ "before" => ":attributeには、:date以前の日付をご利用ください。",
+ "between" => array(
+ "numeric" => ":attributeは、:minから:maxの間で指定してください。",
+ "file" => ":attributeは、:min kBから、:max kBの間で指定してください。",
+ "string" => ":attributeは、:min文字から、:max文字の間で指定してください。",
+ "array" => ":attributeは、:min個から:max個の間で指定してください。",
+ ),
+ "confirmed" => ":attributeと、確認フィールドとが、一致していません。",
+ "date" => ":attributeには有効な日付を指定してください。",
+ "date_format" => ":attributeは:format形式で指定してください。",
+ "different" => ":attributeと:otherには、異なった内容を指定してください。",
+ "digits" => ":attributeは:digits桁で指定してください。",
+ "digits_between" => ":attributeは:min桁から:max桁の間で指定してください。",
+ "email" => "The :attribute must be a valid email address.",
+ "exists" => "選択された:attributeは正しくありません。",
+ "image" => ":attributeには画像ファイルを指定してください。",
+ "in" => "選択された:attributeは正しくありません。",
+ "integer" => ":attributeは整数でご指定ください。",
+ "ip" => ":attributeには、有効なIPアドレスをご指定ください。",
+ "max" => array(
+ "numeric" => ":attributeには、:max以下の数字をご指定ください。",
+ "file" => ":attributeには、:max kB以下のファイルをご指定ください。",
+ "string" => ":attributeは、:max文字以下でご指定ください。",
+ "array" => ":attributeは:max個以下ご指定ください。",
+ ),
+ "mimes" => ":attributeには:valuesタイプのファイルを指定してください。",
+ "min" => array(
+ "numeric" => ":attributeには、:min以上の数字をご指定ください。",
+ "file" => ":attributeには、:min kB以上のファイルをご指定ください。",
+ "string" => ":attributeは、:min文字以上でご指定ください。",
+ "array" => ":attributeは:min個以上ご指定ください。",
+ ),
+ "not_in" => "選択された:attributeは正しくありません。",
+ "numeric" => ":attributeには、数字を指定してください。",
+ "regex" => ":attributeに正しい形式をご指定ください。",
+ "required" => ":attributeは必ず指定してください。",
+ "required_if" => ":otherが:valueの場合、:attributeも指定してください。",
+ "required_with" => ":valuesを指定する場合は、:attributeも指定してください。",
+ "required_without" => ":valuesを指定しない場合は、:attributeを指定してください。",
+ "required_without_all" => "The :attribute field is required when none of :values are present.",
+ "same" => ":attributeと:otherには同じ値を指定してください。",
+ "size" => array(
+ "numeric" => ":attributeは:sizeを指定してください。",
+ "file" => ":attributeのファイルは、:sizeキロバイトでなくてはなりません。",
+ "string" => ":attributeは:size文字で指定してください。",
+ "array" => ":attributeは:size個ご指定ください。",
+ ),
+ "unique" => ":attributeの値は既に存在しています。",
+ "url" => ":attributeに正しい形式をご指定ください。",
+
+ /*
+ |--------------------------------------------------------------------------
+ | カスタムバリデーション言語行
+ |--------------------------------------------------------------------------
+ |
+ | "属性.ルール"の規約でキーを指定することでカスタムバリデーション
+ | メッセージを定義できます。指定した属性ルールに対する特定の
+ | カスタム言語行を手早く指定できます。
+ |
+ */
+
+ 'custom' => array(),
+
+ /*
+ |--------------------------------------------------------------------------
+ | カスタムバリデーション属性名
+ |--------------------------------------------------------------------------
+ |
+ | 以下の言語行は、例えば"email"の代わりに「メールアドレス」のように、
+ | 読み手にフレンドリーな表現でプレースホルダーを置き換えるために指定する
+ | 言語行です。これはメッセージをよりきれいに表示するために役に立ちます。
+ |
+ */
+
+ 'attributes' => array(),
+
+);
diff --git a/modules/system/lang/nl/lang.php b/modules/system/lang/nl/lang.php
index 3a8aa7fea..205628cb9 100644
--- a/modules/system/lang/nl/lang.php
+++ b/modules/system/lang/nl/lang.php
@@ -33,7 +33,7 @@ return [
'help' => 'Hoe vind je jouw Project ID',
'missing' => 'Voer een Project ID in.',
],
- 'detach_confirm_' => 'Are you sure you want to detach this project?',
+ 'detach_confirm' => 'Are you sure you want to detach this project?',
'unbind_success' => 'Project is succesvol ontkoppeld.',
],
'settings' => [
diff --git a/modules/system/lang/ru/lang.php b/modules/system/lang/ru/lang.php
index b5c4758db..e27f2d977 100644
--- a/modules/system/lang/ru/lang.php
+++ b/modules/system/lang/ru/lang.php
@@ -33,8 +33,13 @@ return [
'help' => 'How to find your Project ID',
'missing' => 'Please specify a Project ID to use.',
],
- 'detach_confirm_' => 'Are you sure you want to detach this project?',
+ 'detach_confirm' => 'Are you sure you want to detach this project?',
'unbind_success' => 'Project has been detached successfully.',
+ ],
+ 'settings' => [
+ 'menu_label' => 'Settings',
+ 'missing_model' => 'The settings page is missing a Model definition.',
+ 'update_success' => 'Settings for :name have been updated successfully.',
'return' => 'Return to system settings',
],
'email' => [
@@ -56,11 +61,6 @@ return [
'sendmail_path' => 'Sendmail Path',
'sendmail_path_comment' => 'Please specify the path of the sendmail program.',
],
- 'settings' => [
- 'menu_label' => 'Settings',
- 'missing_model' => 'The settings page is missing a Model definition.',
- 'update_success' => 'Settings for :name have been updated successfully.',
- ],
'install' => [
'project_label' => 'Attach to Project',
'plugin_label' => 'Install Plugin',
diff --git a/modules/system/lang/sv/lang.php b/modules/system/lang/sv/lang.php
index 9b4754c21..9d64c93cf 100644
--- a/modules/system/lang/sv/lang.php
+++ b/modules/system/lang/sv/lang.php
@@ -25,41 +25,41 @@ return [
'project' => [
'name' => 'Projekt',
'owner_label' => 'Ägare',
- 'attach' => 'Attach Project',
- 'detach' => 'Detach Project',
- 'none' => 'None',
+ 'attach' => 'Länka projekt',
+ 'detach' => 'Avlänka projekt',
+ 'none' => 'Inget',
'id' => [
'label' => 'Projekt-ID',
'help' => 'Hur du hittar ditt Projekt-ID',
'missing' => 'Var god välj ett Projekt-ID',
],
- 'detach_confirm_' => 'Are you sure you want to detach this project?',
+ 'detach_confirm' => 'Vill du verkligen avlänka detta projekt?',
'unbind_success' => 'Projektet har blivit avlänkat',
- 'return' => 'Return to system settings',
- ],
- 'email' => [
- 'menu_label' => 'Email Configuration',
- 'menu_description' => 'Manage email configuration.',
- 'general' => 'General',
- 'method' => 'Email Method',
- 'sender_name' => 'Sender Name',
- 'sender_email' => 'Sender Email',
- 'smtp' => 'SMTP',
- 'smtp_address' => 'SMTP Address',
- 'smtp_authorization' => 'SMTP authorization required',
- 'smtp_authorization_comment' => 'Use this checkbox if your SMTP server requires authorization.',
- 'smtp_username' => 'Username',
- 'smtp_password' => 'Password',
- 'smtp_port' => 'SMTP Port',
- 'smtp_ssl' => 'SSL connection required',
- 'sendmail' => 'Sendmail',
- 'sendmail_path' => 'Sendmail Path',
- 'sendmail_path_comment' => 'Please specify the path of the sendmail program.',
],
'settings' => [
'menu_label' => 'Inställningar',
'missing_model' => 'Inställningssidan saknar en modell-definition',
'update_success' => 'Inställningar för :name har uppdaterats',
+ 'return' => 'Återgå till systeminställningar',
+ ],
+ 'email' => [
+ 'menu_label' => 'Epost-konfiguration',
+ 'menu_description' => 'Hantera epost-inställningar',
+ 'general' => 'Generellt',
+ 'method' => 'Email-metod',
+ 'sender_name' => 'Avsändarnamn',
+ 'sender_email' => 'Avsändarens epost-adress',
+ 'smtp' => 'SMTP',
+ 'smtp_address' => 'SMTP-adress',
+ 'smtp_authorization' => 'SMTP-autentisering krävs',
+ 'smtp_authorization_comment' => 'Om din server kräver autentisering, markerar du denna checkbox',
+ 'smtp_username' => 'Användarnamn',
+ 'smtp_password' => 'Lösenord',
+ 'smtp_port' => 'SMTP-port',
+ 'smtp_ssl' => 'SSL-anslutning krävs',
+ 'sendmail' => 'Sendmail',
+ 'sendmail_path' => 'Sendmail-sökväg',
+ 'sendmail_path_comment' => 'Var god ange sökvägen till sendmail',
],
'install' => [
'project_label' => 'Länka till Projekt',
@@ -69,15 +69,15 @@ return [
'install_success' => 'Pluginet har installerats',
],
'updates' => [
- 'title' => 'Manage Updates',
+ 'title' => 'Hantera uppdateringar',
'name' => 'Uppdatera mjukvara',
'menu_label' => 'Uppdateringar',
'check_label' => 'Kontrollera uppdateringar',
'retry_label' => 'Försök igen',
- 'plugin_name' => 'Name',
- 'plugin_description' => 'Description',
+ 'plugin_name' => 'Namn',
+ 'plugin_description' => 'Beskrivning',
'plugin_version' => 'Version',
- 'plugin_author' => 'Author',
+ 'plugin_author' => 'Skapare',
'core_build' => 'Nuvarande build',
'core_build_old' => 'Nuvarande build :build',
'core_build_new' => 'Build :build',
diff --git a/modules/system/lang/tr/lang.php b/modules/system/lang/tr/lang.php
index 7bafbe6f0..e9e9a9c8a 100644
--- a/modules/system/lang/tr/lang.php
+++ b/modules/system/lang/tr/lang.php
@@ -33,8 +33,13 @@ return [
'help' => 'Proje ID\'sini nasıl bulurum?',
'missing' => 'Lütfen kullanılacak Proje ID\'sini belirleyin.',
],
- 'detach_confirm_' => 'Are you sure you want to detach this project?',
+ 'detach_confirm' => 'Are you sure you want to detach this project?',
'unbind_success' => 'Project has been detached successfully.',
+ ],
+ 'settings' => [
+ 'menu_label' => 'Ayarlar',
+ 'missing_model' => 'The settings page is missing a Model definition.',
+ 'update_success' => 'Settings for :name have been updated successfully.',
'return' => 'Return to system settings',
],
'email' => [
@@ -56,11 +61,6 @@ return [
'sendmail_path' => 'Sendmail Path',
'sendmail_path_comment' => 'Please specify the path of the sendmail program.',
],
- 'settings' => [
- 'menu_label' => 'Ayarlar',
- 'missing_model' => 'The settings page is missing a Model definition.',
- 'update_success' => 'Settings for :name have been updated successfully.',
- ],
'install' => [
'project_label' => 'Projeye bağla',
'plugin_label' => 'Eklenti Yükle',
diff --git a/modules/system/traits/ConfigMaker.php b/modules/system/traits/ConfigMaker.php
index 1d85aca14..dbf9e8775 100644
--- a/modules/system/traits/ConfigMaker.php
+++ b/modules/system/traits/ConfigMaker.php
@@ -1,12 +1,13 @@
$configFile, 'location' => get_called_class()]));
$config = Yaml::parse(File::get($configFile));
+
+ /*
+ * Extensibility
+ */
+ $publicFile = File::localToPublic($configFile);
+ if ($results = Event::fire('system.extendConfigFile', [$publicFile, $config])) {
+ foreach ($results as $result) {
+ if (!is_array($result)) continue;
+ $config = array_merge($config, $result);
+ }
+ }
+
$config = $this->makeConfigFromArray($config);
foreach ($requiredConfig as $property) {
@@ -61,7 +74,7 @@ trait ConfigMaker
/**
* Makes a config object from an array, making the first level keys properties a new object.
* Property values are converted to camelCase and are not set if one already exists.
- * @param string $configArray Config array.
+ * @param array $configArray Config array.
* @return stdObject The config object
*/
public function makeConfigFromArray($configArray = [])
diff --git a/server.php b/server.php
new file mode 100644
index 000000000..ddc21fba7
--- /dev/null
+++ b/server.php
@@ -0,0 +1,19 @@
+