实际上我需要通过 htaccess 文件在我的应用程序 URL 中添加 index.php 。
我的网址是这样的。
http://localhost:8080/myapp/xyz/abs.html
Run Code Online (Sandbox Code Playgroud)
我需要将其更改为。
http://localhost:8080/myapp/index.php/xyz/abs.html
Run Code Online (Sandbox Code Playgroud)
谁能告诉我需要在 htaccess 文件中写入什么内容。
任何帮助将不胜感激。
谢谢。
假设我有如下的数组.
Array
(
[0] => agent_name
[1] => first_name
[2] => my_last_name
[3] => job
[4] => job_description
)
Run Code Online (Sandbox Code Playgroud)
现在我想将此数组转换为以下格式.
Array
(
'agent_name' => 'Agent Name',
'first_name' => 'First Name',
'my_last_name' => 'My Last Name',
'job' => 'Job',
'job_description' => 'Job Description',
)
Run Code Online (Sandbox Code Playgroud)
所以任何人都可以帮助我,如何设置这样.
谢谢
任何人都可以告诉我,我需要在Laravel 5.4中创建一个自动运行的程序.
首先,我创建了一个文件FollowAdvisor.php at/app/Console/Commands/
<?php
namespace App\Console\Commands;
use Illuminate\Console\Command;
use DB;
class FollowAdvisor extends Command
{
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'follow:advisor';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Command description';
/**
* Create a new command instance.
*
* @return void
*/
public function __construct()
{
parent::__construct();
}
/**
* Execute the console command.
*
* @return …Run Code Online (Sandbox Code Playgroud)