<tfoot id='CuXPd'></tfoot>

  • <legend id='CuXPd'><style id='CuXPd'><dir id='CuXPd'><q id='CuXPd'></q></dir></style></legend>
  • <small id='CuXPd'></small><noframes id='CuXPd'>

      • <bdo id='CuXPd'></bdo><ul id='CuXPd'></ul>

        <i id='CuXPd'><tr id='CuXPd'><dt id='CuXPd'><q id='CuXPd'><span id='CuXPd'><b id='CuXPd'><form id='CuXPd'><ins id='CuXPd'></ins><ul id='CuXPd'></ul><sub id='CuXPd'></sub></form><legend id='CuXPd'></legend><bdo id='CuXPd'><pre id='CuXPd'><center id='CuXPd'></center></pre></bdo></b><th id='CuXPd'></th></span></q></dt></tr></i><div id='CuXPd'><tfoot id='CuXPd'></tfoot><dl id='CuXPd'><fieldset id='CuXPd'></fieldset></dl></div>

        如何在 Laravel 中编辑和保存自定义配置文件?

        How to edit and save custom config files in Laravel?(如何在 Laravel 中编辑和保存自定义配置文件?)
          <bdo id='i4NsE'></bdo><ul id='i4NsE'></ul>
            • <legend id='i4NsE'><style id='i4NsE'><dir id='i4NsE'><q id='i4NsE'></q></dir></style></legend>

              <i id='i4NsE'><tr id='i4NsE'><dt id='i4NsE'><q id='i4NsE'><span id='i4NsE'><b id='i4NsE'><form id='i4NsE'><ins id='i4NsE'></ins><ul id='i4NsE'></ul><sub id='i4NsE'></sub></form><legend id='i4NsE'></legend><bdo id='i4NsE'><pre id='i4NsE'><center id='i4NsE'></center></pre></bdo></b><th id='i4NsE'></th></span></q></dt></tr></i><div id='i4NsE'><tfoot id='i4NsE'></tfoot><dl id='i4NsE'><fieldset id='i4NsE'></fieldset></dl></div>

                  <tbody id='i4NsE'></tbody>

                • <small id='i4NsE'></small><noframes id='i4NsE'>

                  <tfoot id='i4NsE'></tfoot>

                • 本文介绍了如何在 Laravel 中编辑和保存自定义配置文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我正在 Laravel 4 中创建简单的 Web 应用程序.我有用于管理应用程序内容的后端.作为后端的一部分,我希望有 UI 来管理应用程序设置.我希望我的配置变量存储在文件 [FOLDER: /app/config/customconfig.php] 中.

                  I am creating simple web application in Laravel 4. I have backend for managing applications content. As a part of backend i want to have UI to manage applications settings. I want my configuration variables to be stored in file [FOLDER: /app/config/customconfig.php].

                  我想知道 Laravel 中是否有可能拥有自定义配置文件,可以通过后端 UI 进行管理/更新?

                  I was wondering if there's any possibility in Laravel how to have custom config file, which can be managed/updated thru backend UI?

                  推荐答案

                  我是这样做的...

                  config(['YOURKONFIG.YOURKEY' => 'NEW_VALUE']);
                  $fp = fopen(base_path() .'/config/YOURKONFIG.php' , 'w');
                  fwrite($fp, '<?php return ' . var_export(config('YOURKONFIG'), true) . ';');
                  fclose($fp);
                  

                  这篇关于如何在 Laravel 中编辑和保存自定义配置文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  Laravel 4 - Connect to other database(Laravel 4 - 连接到其他数据库)
                  Call external API function from controller, LARAVEL 4(从控制器调用外部 API 函数,LARAVEL 4)
                  Empty string instead of null values Eloquent(空字符串而不是空值 Eloquent)
                  quot;laravel.logquot; could not be opened: failed to open stream(“laravel.log无法打开:无法打开流)
                  Displaying the Error Messages in Laravel after being Redirected from controller(从控制器重定向后在 Laravel 中显示错误消息)
                  Laravel Creating Dynamic Routes to controllers from Mysql database(Laravel 从 Mysql 数据库创建到控制器的动态路由)

                • <tfoot id='EoqWd'></tfoot>

                      <i id='EoqWd'><tr id='EoqWd'><dt id='EoqWd'><q id='EoqWd'><span id='EoqWd'><b id='EoqWd'><form id='EoqWd'><ins id='EoqWd'></ins><ul id='EoqWd'></ul><sub id='EoqWd'></sub></form><legend id='EoqWd'></legend><bdo id='EoqWd'><pre id='EoqWd'><center id='EoqWd'></center></pre></bdo></b><th id='EoqWd'></th></span></q></dt></tr></i><div id='EoqWd'><tfoot id='EoqWd'></tfoot><dl id='EoqWd'><fieldset id='EoqWd'></fieldset></dl></div>
                    1. <legend id='EoqWd'><style id='EoqWd'><dir id='EoqWd'><q id='EoqWd'></q></dir></style></legend>

                      <small id='EoqWd'></small><noframes id='EoqWd'>

                        <bdo id='EoqWd'></bdo><ul id='EoqWd'></ul>
                              <tbody id='EoqWd'></tbody>