我想通过制作视图 RTL 并将整个面板翻译成波斯语来本地化我的管理包,以便有类似要求的人可以使用它。这将是我的喜悦( 你能告诉我我应该编辑哪些文件吗?
网站: http://xtex.ir/admin/login
user:demo@android.com
通行证:管理员
你必须执行以下任务
1-import CSS & JS bootstrap-rtl (LTR => RTL(
使用 bootstrap-rtl 而不是 bootstrap css & js 文件, 您可以访问此目录中的CSS和JS文件:
{YOUR-PROJECT-NAME}\resources\assets
(别忘了编译 css 和 js 文件,需要在项目目录下使用此命令 =>npm run watch
(
2-更改 lang 文件夹 Laravel用于显示消息和验证使用lang文件夹
,您应该在lang文件夹中添加fa
文件夹lang folder
。
{YOUR-PROJECT-NAME}\resources\lang
3-更改应用程序区域设置配置
,您可以在此目录中访问:
{YOUR-PROJECT-NAME}\config\app.php
/*
|--------------------------------------------------------------------------
| Application Locale Configuration
|--------------------------------------------------------------------------
|
| The application locale determines the default locale that will be used
| by the translation service provider. You are free to set this value
| to any of the locales which will be supported by the application.
|
*/
'locale' => 'fa',
4-使用引导 rtl 组件 在此目录中,您应该更改引导组件并在html
文件中使用 bootstrap-rtl 组件
:
{YOUR-PROJECT-NAME}\resources\views