Peter Amiri
07/07/2022, 10:24 PMBrian Lang
07/07/2022, 10:30 PMBrian Lang
07/07/2022, 10:41 PMPeter Amiri
07/07/2022, 10:48 PMPeter Amiri
07/07/2022, 10:50 PMBrian Lang
07/07/2022, 10:52 PMPeter Amiri
07/07/2022, 10:54 PMPeter Amiri
07/07/2022, 10:55 PMBrian Lang
07/07/2022, 10:55 PMPeter Amiri
07/07/2022, 10:59 PMBrian Lang
07/07/2022, 11:00 PMBrian Lang
07/07/2022, 11:01 PMPeter Amiri
07/07/2022, 11:03 PMristo
07/27/2022, 8:15 PMWheels.InvalidAuthenticityToken
This POSTed request was attempted without a valid authenticity token.
Any way to turn off requiring authenticity token on post? I setup a post route to use a wysiwyg editor's upload url javascript parameter. csrfMetaTags() is in the <head>. It's obviously not getting the token so can I turn off requiring the token on post? I don't see any setting here - https://guides.cfwheels.org/cfwheels-guides/working-with-cfwheels/configuration-and-defaults#csrf-protection-settingsristo
07/27/2022, 8:31 PMPeter Amiri
07/27/2022, 8:51 PMprotectsFromForgery(with = "ignore")
in your controller to make it ignore the checkristo
07/27/2022, 8:52 PMPeter Amiri
07/27/2022, 8:54 PMchapmandu
07/27/2022, 11:09 PMristo
07/27/2022, 11:34 PMchapmandu
07/27/2022, 11:40 PMchapmandu
07/27/2022, 11:41 PMchapmandu
07/27/2022, 11:44 PMristo
07/28/2022, 3:52 PMAdam Cameron
addRoute(
name="myRoute",
pattern="myPattern",
controller="myController",
action="myAction"
)
If I then reload the app, I can then browse to http://localhost/myPattern/myAction, and it runs. Cool.
However if I try to do this on the fly, eg:
addRoute(
name="myRoute",
pattern="myPattern",
controller="myController",
action="myAction"
)
http method="get" url="<http://localhost/myPattern/myAction>";
Then the request is handled by the /
route.
If I dump out application.wheels.routes
immediately after the addRoute
call, I see myRoute
in the array.
Equally, if I dump it out in the /
route view, then I also see it there.
So I'm wondering what the missing piece of the puzzle is that I need to do so that it's actually... used. It's like I've set it up, but I've not loaded it or something?David Belanger
08/09/2022, 6:05 PMDavid Belanger
08/09/2022, 6:07 PMDavid Belanger
08/09/2022, 6:26 PMAdam Cameron
Adam Cameron