slim

    0熱度

    1回答

    我怎樣才能調用laravel或苗條路線的方法? 比方說,我有課是這樣的: namespace App; class App { public function getApp(){ return "App"; } } ,我想在這條路上 $route->get('App\App','getApp'); 我怎麼能這樣叫?

    0熱度

    1回答

    我使用超薄框架2 etag()獲取緩存數據,所有工作正常,我得到與郵遞員或任何其他客戶端緩存中的數據,但我得到HTTP 200 OK響應在其餘的客戶端,但因爲所有的時間應該是HTTP 304當數據來自緩存 下面 是我苗條API: $app->get('/getNew', function() use ($app){ $app->etag('uniqueEtag12'); ech

    1熱度

    1回答

    我使用超薄框架,試圖實現slim token authentication中間件,現在每當我去 本地主機/項目/限制 我得到消息「令牌未找到」似乎工作正常,但是當我嘗試通過授權參數中的令牌按照中間件documentation 的locahost /項目/限制?授權= usertokensecret 我總是得到錯誤級 '應用程序\驗證' 未找到和我的錯誤追查之下, 0 /應用/ AMPPS/WWW

    0熱度

    1回答

    我有一個使用苗條框架的在線應用程序。該網站似乎工作正常,但當我檢查錯誤日誌,我得到下面。 [Mon Apr 17 13:26:45.349695 2017] [:error] [pid 30816] [client xx.xxx.xx.133:39856] PHP Notice: Undefined offset: 0 in /var/www/Sites/appName/vendor/slim/s

    0熱度

    1回答

    這裏是中間件流程: # Post edit $this->get('/edit/{id}/{slug}', \Rib\Src\Apps\Post\PostControllers\EditController::class . ':index') ->add(new EnforceEditDelay()) ->add(new RequireOwner('posts'))

    0熱度

    1回答

    我正在關注alex的how to build a shopping cart lesson,一切工作正常。但後來我不知道,所以我得到什麼即時做錯了這個錯誤: Fatal error: Uncaught Error: Class 'maimana\App' not found in /Applications/MAMP/htdocs/maimana/bootstrap/app.php:13 Stac

    4熱度

    1回答

    我想重定向到一個頁面(例如error.php),具體取決於我網站中表單中的信息。我設法登錄這樣的錯誤: if ($date > $curdate) { return $response ->withStatus(406) ->withHeader('Content-Type', 'text/html') ->write('You can\'t sele

    0熱度

    1回答

    我有很多在我的細長應用程序中聲明的路線。 其中的一些具有路由參數 $app->get("/:user/profile",function($user) use($app){ ... }); $app->get("/test/:id",function($id) use($app){ ... }); 例如,如果我稱之爲: http://myhost/test/1 它適用於兩條路線,則聲明順

    0熱度

    2回答

    在我app.php我成立了一個容器,我配置數據庫連接: $container['db'] = function ($c) { $db = $c['settings']['db']; $pdo = new PDO("sqlsrv:Server=" . $db['host'] . ";Database=" . $db['dbname'], $db['user'], $db['pas

    -1熱度

    1回答

    這是我的目錄結構 /path/www.mysite.com/ public_html/ api/ v1/ index.php .htaccess .htaccess Rule : RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f Rew