Hello everyone… anyone can help me to solve my problem?
It my first time using dhtmlx scheduler, it’s awesome and beautiful Scheduler like google calendar. I was playing around with this javascript, but now I got stuck…
here is my code…
// javascript
// HTML
<div style='position:absolute; bottom:20px'>
<input type='button' value='Save data to un-secure feed' onclick='try_csrf("./data/events.php","Un-Secure")'>
<input type='button' value='Save data to secure feed' onclick='try_csrf("./data/events_safe.php","Secure")'>
</div>
the problem is… I always get error “WARNING: Can’t verify CSRF token authenticity”,
I think it because there is no authentication token when I submit new data / update existing data.
My application always reject this request and render 401 Unauthorized.
How can I add the authentication token, so… it will pass to my controller when I add / update data in my Scheduler page. I’m using rails 3.2