yii2 404 ?? ??
?????? ??? ?? ??? ?????. ???? ?????? ?????
1 ?? yii ?????? frontendconfig ??? ?????. ??? ?? ???? ?? ???? ??? ??? ??? ?????.
'errorHandler' => [ 'errorAction' => 'common/error', ],
?? ??: yii Framework
??? ??:
2. ?? ?? ????? ???? ????? ??? ??? ?????. ??:
/** * 404友好頁面 */ public function actions(){ return [ 'error' => [ 'class' => 'yii\web\ErrorAction', ], 'captcha' => [ 'class' => 'yii\captcha\CaptchaAction', 'fixedVerifyCode' => YII_ENV_TEST ? 'testme' : null, , ]; }
??? ??? ??:
3. ????? V ????? ?? ????(??? error.php???):
<?php $this->context->layout = false; //不加載公共樣式 ?> <!DOCTYPE html> <html> <head> <title>404錯誤,您所訪問的頁面不存在!</title> <meta charset="utf-8"> <link rel="stylesheet" href="css/style.css"/> <link rel="stylesheet" href="css/base.css"/> </head> <body> <div id="errorpage"> <div class="tfans_error"> <div class="logo"></div> <div class="errortans clearfix"> <div class="e404"></div> <p><b>出錯啦!</b></p> <p>您訪問的頁面不存在</p> <div class="bt" ><a href="?r=index/index">返回首頁</a></div> </div> </div> </div> </body> </html>
??? ??? ??:
? ??? yii2 404 ?? ??? ?? ?????. ??? ??? PHP ??? ????? ?? ?? ??? ?????!

? AI ??

Undress AI Tool
??? ???? ??

Undresser.AI Undress
???? ?? ??? ??? ?? AI ?? ?

AI Clothes Remover
???? ?? ???? ??? AI ?????.

Clothoff.io
AI ? ???

Video Face Swap
??? ??? AI ?? ?? ??? ???? ?? ???? ??? ?? ????!

?? ??

??? ??

???++7.3.1
???? ?? ?? ?? ???

SublimeText3 ??? ??
??? ??, ???? ?? ????.

???? 13.0.1 ???
??? PHP ?? ?? ??

???? CS6
??? ? ?? ??

SublimeText3 Mac ??
? ??? ?? ?? ?????(SublimeText3)

TO TOREABASICROUTEINYII, FIRSTEPACONTROLLERBYPLACINGITINTECONTROLLERSDIRECTORYWITHPROPENAMINAMINAMINAMINAMINAMINATDEFINITIONEPTENDENDINGYII \ WEB \ CONTROLLER.1) CREATEANCACTIONSTATRINGWITH "ACTION"

Ayiideveloper'skeyErsponsibilitiesIngindingandimplementingFeatures, ApplicationSecurity, ? ??? ? ??? ???? QualificationSneedeDareastronggraspofpp, Experience-EndTechnologies, DatabasemanagementsKills ? Problem-Solvingabi

YII?? ??? ?? ??? ???? ??? ????? ???? ???? ???? ???? ???? ????? ?? ??? ???? ????. ?? ?? ??? ?? ???? ????? ?? ?????? JSON? ??????. ????? ??? ??? ?? ??? ?????. ?? ???? ??? ?????. 1. ???? ???? ????. 2. ??? ????? ??????. 3. URL ?? ????? ? ????. 4. ?? ??, ??? ?? ??, ???? ?? ?? ???? ???; 5. AccessControl ?? ?? ?? ??? ???? ???? ??????. ?? ??, ActionProfile ($ id)? /site /profile? id = 123? ?? ????? ??? ??? ???? ??? ? ? ????. ?? ??????

ayiidevelopercraftswebapplicationsingtheyiiiframework, ?? ?? Killsinphp, yii-specificknowledge ? webdevelopmentlifecyclemanagement.keySponsibilitiesInclude : 1) WritingEfficientCodetOptimizeperFormance, 2) poploitizingsecurityTopectAppplications,

touseactivercordinyifeffectively, ??? ??? ??? createamodelclassforeachtableandinteractwiththeabaseusingobject-orientedmethods.first, defineamodelclasseptendingyii \ db \ activerecordandspecorrecorrespecorrespectecorrespectedtablenaMeAblename ()

?? ??? ????, ?? ??? ??? ?????, ?????? ??? ????, ??? ??? ???? ????? YII?? ?? ???? ?? ? ? ????. ?? ??? ??? ????. 1. filetarget ?? dbtarget? ?? ?? ???? ?? ?? ??? ???? ??? '??'?? ?????. 2. yii :: info () ?? yii :: ?? ()? ???? ??? ???? ??? ????? (? : ??? ?? ? ???? ???)? ??? ?; 3. ????? ?? ? ??? ?? ??????? ??? ???? ?? ???? ???? ?? ??? ?? ??? ???????. 4. ???? ??? ?? ? ? ?? ?? ??? ?? ??? ???? ???? ??? ???? ??? ???? IP ? ??? ??? ?? ? ? ????. 5

YII? AssetBundles? ???? ?? CSS ? JS ??? ???? ?? ?????. PHP ???? ?? ?? ??? ??? ???? ???? ???, ?? ? ??? ?????. 1. ??? ???? CSS, JS ? ?? ???? ???? ???? ???? ? ???? PHP ??????. 2. ? ?? ????? ??? ???? ???? HTML ??? ???? ?????. 3. ??? ?? ?? ??? ??? ?? ?? ??? ???? ??? ?? ? ? ????. 4. ??? ??? ????? ?/CSS ? ?/JS? ???? ??? ??? ?? ? ? ????. 5. AssetManager ??? ???? ?? ???? ???? ?? ??? ???? ???? ?? ??? ??????. ?? ???? ???? ???? ???? ?? ??? ? ?? ???? ???? ? ????.

YII?? ????? ??? ??, ??? ?? ? ??? ?? ???? ?? ???? ??? ?????. ????? ?? ???? ??? ?????. ① http ?? ??; data ???? ??? ???? ?? ??? ?? ?????. dase ???? ???? ??? ?? ?????. processing ?? ?? ??; HTML, JSON ?? ???? ?? ??. YII ????? ????? yii \ web \ ?????? ???? ? ?? ???? URL? ?? ??? ? ??? ??? ?????. ?? ??, http://example.com/site/index? ???? sitecontroller? actionIndex () ???? ?????. ???? ???? ?? ??, ?? ?? ? ???? ?????.
