結(jié)合設(shè)計(jì)經(jīng)驗(yàn)與營銷實(shí)踐,提供有價值的互聯(lián)網(wǎng)資訊
發(fā)布日期:2022-03-16瀏覽次數(shù):845 來源:福州網(wǎng)站建設(shè)
以上是由福州網(wǎng)站建設(shè)的小編為你分享了"tp6入口文件如何綁定控制器"文章,如果你在這方面有什么問題,隨時聯(lián)系我們
lgcoper 03月16日
剛剛也要這樣用,研究了一下,設(shè)置路由規(guī)則即可,代碼如下。
[code]
<?php
namespace think;
require __DIR__ . '/../vendor/autoload.php';
$app = new App();
$app->route->rule('','modulename/controllername/actionname');
$response = $app->http->name('modulename')->run();
$response->send();
$app->http->end($response);
/****
例如下面的寫法
$app->route->rule('','member/user/register');
$response = $app->http->name('member')->run();
$response->send();
$app->http->end($response);
***/
[/code]
好計(jì)謀 2020年10月12日
多應(yīng)用的咋搞
宋曉利 2020年09月05日
我也遇到這個問題了,你的解決了嗎