定制 shibleshakil/dynamic-language 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

shibleshakil/dynamic-language

最新稳定版本:v1.2.1

Composer 安装命令:

composer require shibleshakil/dynamic-language

包简介

The dynamic-language Laravel package simplifies localization management, making it effortless to handle missing keys in language files. It seamlessly generates language files for each newly added language, enhancing the efficiency of your localization efforts. Additionally, it takes care of configur

README 文档

README

The dynamic-language Laravel package simplifies localization management, making it effortless to handle missing keys in language files. It seamlessly generates language files for each newly added language, enhancing the efficiency of your localization efforts. Additionally, it takes care of configuring locale settings, ensuring smooth transitions between languages. Developers seeking well-organized localization support for their Laravel applications will find this package to be an invaluable tool.

Installation

To incorporate the dynamic-language package into your Laravel project, use Composer:

composer require shibleshakil/dynamic-language

Next, add the service provider to your config/app.php file:

shibleshakil\DynamicLanguage\DynamicLanguageServiceProvider::class

Copy the package config to your local config and migration file to your local migration directory with the publish command:

php artisan vendor:publish --provider="shibleshakil\DynamicLanguage\DynamicLanguageServiceProvider" --tag="config"

Finally, migrate the language table:

php artisan migrate

Usage

Retrieve the default locale by calling:

shibleshakil\DynamicLanguage\TranslationHelper::getDefaultLanguage()

Add a new language file:

shibleshakil\DynamicLanguage\TranslationHelper::addLanguageFile($lang)

Get all Transabled Keys of a locale:

shibleshakil\DynamicLanguage\TranslationHelper::allTransabledKeys($locale)

Update language key values:

shibleshakil\DynamicLanguage\TranslationHelper::translateKey($key, $value, $lang)

Explore the eloquent model for retrieving your language list:

$languages = shibleshakil\DynamicLanguage\Language::get();

Make your Laravel application's localization journey smoother with dynamic-language.

Contribution

We welcome contributions from the community! Feel free to submit issues and pull requests to enhance this package.

License

This package is open-source and distributed under the MIT License.

统计信息

  • 总下载量: 40
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 7
  • 点击次数: 3
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 6
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2023-08-13

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固