CSRF with fetch API |
Can someone help me with this?
Code: fetch(SITE_CONSTANT+'/login/updateUser', { posting stuff with fetch api from javascript to a controller. It works when I turn off csrf, but does not when it's on. I tried to do like this: Code: let csrfs = document.querySelectorAll('input[name=csrf_token]'); Like how I do with Jquery ajax - but still no dice help?
You can see things I made with codeigniter here: itart.pro its not overly impressive as I have very little time to learn.
|
Messages In This Thread |
CSRF with fetch API - by Leo - 07-01-2020, 11:04 AM
RE: CSRF with fetch API - by MGatner - 07-07-2020, 10:26 AM
RE: CSRF with fetch API - by Leo - 07-07-2020, 12:51 PM
RE: CSRF with fetch API - by MGatner - 07-07-2020, 04:20 PM
RE: CSRF with fetch API - by Leo - 07-08-2020, 08:41 AM
RE: CSRF with fetch API - by InsiteFX - 07-08-2020, 11:40 AM
|