how to change csrf field id from YII_CSRF_TOKEN to any other

别等时光非礼了梦想. 提交于 2020-01-24 10:30:55

问题


i am using Get method for form post but i am not interested if person could see if i am using yii framework. So instead of using YII_CSRF_TOKEN i need to make my own defined id name e.g. like only TOKEN.

I don't want to reveal what framework i am using , any kind of tip or help ???


回答1:


in your application config add the below code

'request'=>array(    
    'csrfTokenName'=>'YOUR_TOKEN_NAME_HERE',
),


来源:https://stackoverflow.com/questions/11809448/how-to-change-csrf-field-id-from-yii-csrf-token-to-any-other

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!