# |
Jul 10th 2017, 16:06 |
neon1024 |
Ah `redirectUrl` even, I always get those confused |
# |
Jul 10th 2017, 16:06 |
neon1024 |
https://book.cakephp.org/3.0/en/controllers/components/authentication.html#redirecting-users-after-login |
# |
Jul 10th 2017, 16:05 |
neon1024 |
I’d bet a cup of tea that the `loginRedirect` setting is set |
# |
Jul 10th 2017, 16:05 |
neon1024 |
Sounds like a configuration issue with the AuthComponent to me |
# |
Jul 10th 2017, 15:44 |
ericadeefox |
hey y'all, having basically this same problem: https://stackoverflow.com/questions/44257598/login-redirecting-in-cakephp-3-4 specifically: Now everything working fine but getting null query parameter string even though passing query parameter string like this `login?redirect=%2Farticles%2Fadd`. therefore, upon logging in, it just redirects to '/' rather than the string after redirect=. no query or session data from the redirect url. |
# |
Jul 10th 2017, 15:36 |
sturm |
Ah, that was it. I put the file in the project root, not in the /webroot folder. Thank you, @admad! |
# |
Jul 10th 2017, 15:35 |
admad |
The access yourapp/phpinfo.php |
# |
Jul 10th 2017, 15:35 |
admad |
@sturm Make webroot/phpinfo.php and put the statement in that |
# |
Jul 10th 2017, 15:33 |
sturm |
I apologize for another newbie question: How do I get a simple phpinfo(); with CakePHP? All I get is a “Missing Controller” error page. |
# |
Jul 10th 2017, 14:44 |
anvyst |
@neon1024 clickatell? (https://github.com/arcturial/clickatell) |
# |
Jul 10th 2017, 14:40 |
neon1024 |
Anyone have any service suggestions for me to send SMS messages with please? |
# |
Jul 10th 2017, 14:10 |
lorenzo |
:) |
# |
Jul 10th 2017, 14:08 |
birdy247 |
Thanks for the help |
# |
Jul 10th 2017, 14:07 |
birdy247 |
it was still using the array! |
# |
Jul 10th 2017, 14:07 |
birdy247 |
I hadnt update the config file in my app |
# |
Jul 10th 2017, 14:07 |
birdy247 |
ahhh |
# |
Jul 10th 2017, 14:06 |
birdy247 |
passing in the data from the webhook |
# |
Jul 10th 2017, 14:06 |
birdy247 |
middleware get it, and then calls the callable |
# |
Jul 10th 2017, 14:06 |
birdy247 |
I am sending a test webhook |
# |
Jul 10th 2017, 14:06 |
birdy247 |
Ok |
# |
Jul 10th 2017, 14:06 |
lorenzo |
but when doing what |
# |
Jul 10th 2017, 14:06 |
birdy247 |
It still think it should be static |
# |
Jul 10th 2017, 14:04 |
birdy247 |
@lorenzo Error: Fatal Error (1): Using $this when not in object context |
# |
Jul 10th 2017, 14:01 |
lorenzo |
I’m not following… what error do you get when doing what? |
# |
Jul 10th 2017, 13:57 |
birdy247 |
..or if you prefer move that to a function somewhere else you can import and put there as pure config instead of writing a function there.. |
# |
Jul 10th 2017, 13:57 |
birdy247 |
How would I do what you suggested? |
# |
Jul 10th 2017, 13:56 |
birdy247 |
So is this because I am reading it from config? |
# |
Jul 10th 2017, 13:56 |
birdy247 |
$handler = function (...$params) { return TableRegistry::get('Stripes')->webhookHandler(...$params); |
# |
Jul 10th 2017, 13:56 |
birdy247 |
@lorenzo even if I write this directly in the Middleware, it works |
# |
Jul 10th 2017, 13:54 |
birdy247 |
So it must be something to do with my callable |
# |
Jul 10th 2017, 13:54 |
birdy247 |
Its fine |
# |
Jul 10th 2017, 13:54 |
birdy247 |
$Stripes->webhookHandler($data); |
# |
Jul 10th 2017, 13:54 |
birdy247 |
$Stripes = TableRegistry::get('Stripes'); |
# |
Jul 10th 2017, 13:54 |
birdy247 |
If I add this into the Middleware |
# |
Jul 10th 2017, 13:51 |
birdy247 |
it thinks I am calling it statically |
# |
Jul 10th 2017, 13:49 |
birdy247 |
so refernecing $this |
# |
Jul 10th 2017, 13:49 |
birdy247 |
I am trying to dispatch an event from the webhookHandler function |
# |
Jul 10th 2017, 13:49 |
birdy247 |
I get that error |
# |
Jul 10th 2017, 13:49 |
birdy247 |
Using $this when not in object context |
# |
Jul 10th 2017, 13:48 |
lorenzo |
you don’t need to change that |
# |
Jul 10th 2017, 13:48 |
birdy247 |
thats what I was doing |