Sunday, June 26, 2022

[FIXED] How to customize vendor view files?

Issue

In yii2 how do I customize vendor view files without modifying the original view files?

I'm using dektrium yii2-user and would like to make a few changes to the login page.


Solution

You can assign your view path for dektrium yii2-user in this way (assume @app your app alias) :

'components' => [
    'view' => [
        'theme' => [
            'pathMap' => [
                '@dektrium/user/views' => '@app/views/your_dir_views'  // mapping for override the views dektrium with  your views 
            ],
        ],
   .....
 ],


Answered By - ScaisEdge
Answer Checked By - Robin (PHPFixing Admin)

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.