serge Posted December 4, 2014 Report Share Posted December 4, 2014 Hello, I created a custom form within my blesta theme in app/views/client/my-theme/structure.php, and I'm also using csrf token verify option enabled in my blesta config file, I understood I need to post a hidden field in my custom form, like this: <input type="hidden" name="_csrf_token" value="??????????????????" > but how to get the csrf_token variable? Quote Link to comment Share on other sites More sharing options...
0 Blesta Addons Posted December 8, 2014 Report Share Posted December 8, 2014 from wich file you want to obtain the csrf token . normally if you have used the class "Form" it should include it auto . Quote Link to comment Share on other sites More sharing options...
0 Blesta Addons Posted December 4, 2014 Report Share Posted December 4, 2014 let me say $_POST["_csrf_token"] Quote Link to comment Share on other sites More sharing options...
0 serge Posted December 5, 2014 Author Report Share Posted December 5, 2014 Thank You, by the way still no luck for having something that work Quote Link to comment Share on other sites More sharing options...
0 Blesta Addons Posted December 5, 2014 Report Share Posted December 5, 2014 $vars->_csrf_token Quote Link to comment Share on other sites More sharing options...
0 serge Posted December 8, 2014 Author Report Share Posted December 8, 2014 Thanks, still no luck for that work for me, so I passed on that by disabling csrf token check for this specific blesta url Quote Link to comment Share on other sites More sharing options...
0 serge Posted December 8, 2014 Author Report Share Posted December 8, 2014 THANK YOU for detail ok, I understand now my error, I got it working with the csrf token check enabled Quote Link to comment Share on other sites More sharing options...
Question
serge
Hello,
I created a custom form within my blesta theme in app/views/client/my-theme/structure.php,
and I'm also using csrf token verify option enabled in my blesta config file,
I understood I need to post a hidden field in my custom form, like this:
but how to get the csrf_token variable?
Link to comment
Share on other sites
6 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.