Created
June 8, 2011 14:37
-
-
Save lukesaunders/1014537 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
In Rails layout file: | |
<script> | |
function authToken(){ | |
return '<%= form_authenticity_token if protect_against_forgery? -%>'; | |
} | |
</script> | |
In FileUploader init code: | |
uploader = new qq.FileUploader({ | |
... | |
params: { authenticity_token: authToken() } | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment