Log message #4105506

# At Username Text
# Dec 22nd 2017, 11:36 hmic but use controller authorize instead
# Dec 22nd 2017, 11:36 hmic additionally, you should try not to put the authorization stuff in a beforefilter
# Dec 22nd 2017, 11:35 hmic i have not been talking about the crud beforeFilter
# Dec 22nd 2017, 11:34 lilhermit I know `beforeFilter` is being called as I've put debug in it
# Dec 22nd 2017, 11:34 lilhermit ``` $this->Crud->on('beforeFilter', function(Event $event) { if (!$this->isAuthorised()) { $event->stopPropagation(); return false; } });```
# Dec 22nd 2017, 11:33 lilhermit yes
# Dec 22nd 2017, 11:32 hmic lilhermit: tried returning false from the event?
# Dec 22nd 2017, 11:31 lilhermit Hi all, does anyone know how to stop Crud from invoking an action? in my beforeFilter (controller) I'm doing `$event->stopPropagation();` and returning a redirect. in Crud.beforeFilter I'm also doing `$event->stopPropagation();` yet the method is getting called
# Dec 22nd 2017, 09:39 braeden Okay, thanks again!
# Dec 22nd 2017, 09:08 ono-t god morning!
# Dec 22nd 2017, 08:47 neon1024 Perhaps a complete table method which does all the find the caching would be easier
# Dec 22nd 2017, 08:47 neon1024 Plus, you’d want to think about how the caching would work, as a custom finder method quite often just modifies an existing query object
# Dec 22nd 2017, 08:47 neon1024 @braeden I would suggest perhaps adding an option to the custom finder to control if the method should cache or not
# Dec 22nd 2017, 08:29 k4t o/
# Dec 22nd 2017, 08:28 neon1024 Morning all
# Dec 22nd 2017, 07:30 braeden thanks
# Dec 22nd 2017, 07:01 admad @braeden it's fine
# Dec 22nd 2017, 05:34 vignesh.pattalam @HippoCritical Check whether the port from which you are sending your emails is open or blocked, if it is blocked you might need to open it
# Dec 22nd 2017, 05:28 braeden This place is so dead for Australians :)
# Dec 22nd 2017, 00:26 braeden I can't see any downsides to doing so (at the moment), it centralises the whole process, and it's a query I am using quite frequently
# Dec 22nd 2017, 00:25 braeden Is it sensible to perform caching read/writes in a Table's custom finder method? e.g. $users->find('nameAndImage') which will either return the result from the cache or query the DB?
# Dec 22nd 2017, 00:08 itamer I'm looking at authentication in cake3 - at the moment the user is handed off to a cake2 site for authenication and then returned. If I use UseMuffin/OAuth2 all the passwords will be retained, right?
# Dec 21st 2017, 22:13 braeden debug( $this->request->data ) ?
# Dec 21st 2017, 21:34 genellern Hi guys, any idea how to test a request from a form to upload a photo?
# Dec 21st 2017, 20:11 admad justcharlz: https://github.com/UseMuffin/Tokenize/blob/master/src/Model/Behavior/TokenizeBehavior.php#L104 https://github.com/UseMuffin/Tokenize/blob/master/src/Model/Table/TokensTable.php#L76
# Dec 21st 2017, 19:53 HippoCritical Hello Everyone. Are SocketExceptions normally caused by sending emails using Cake? I have an application that's supposed to be sending emails once a user fills out a form, but it keeps giving errors. I looked in the apache error.log file and found a few errors relating to SocketException
# Dec 21st 2017, 16:56 ceeram there she is
# Dec 21st 2017, 16:53 ceeram .
# Dec 21st 2017, 16:47 ceeram or, almost
# Dec 21st 2017, 16:47 ceeram @neon1024 my colleague got you as mentor :slightly_smiling_face:
# Dec 21st 2017, 16:21 justcharlz It's alway empty. Also want to know if it is possible to have other data filled saved somewhere instead of making the user enter the details all over again
# Dec 21st 2017, 16:20 justcharlz Hello house, I think I have seen @admad here before. Developer of the UseMuffin/Tokenize plugin https://github.com/UseMuffin/Tokenize Need to know what is meant to be in the foreign_data[] of the tokenize table.
# Dec 21st 2017, 16:06 slackebot3 $this->Crud->listener(‘view’)->beforeRender($event); parent::beforeRender($event); // TODO: Change the autogenerated stub }
# Dec 21st 2017, 16:06 torvault I answered my own question: public function beforeRender(Event $event) { //Tell the view Builder that you want to render using the CrudView View class //This ensures that the correct layouts are applied to the view $this->viewBuilder()->setClassName(‘CrudView.Crud’); //This ensures that all of the menu and navigations variables are passed to the view
# Dec 21st 2017, 15:44 cgtag How do you guys get the country flag added to your names?
# Dec 21st 2017, 15:39 neon1024 Yep
# Dec 21st 2017, 15:39 ceeram hi @neon1024 you doing php mentorship :slightly_smiling_face:
# Dec 21st 2017, 15:14 neon1024 Yups
# Dec 21st 2017, 15:14 neon1024 https://github.com/cakephp/cakephp/blob/master/src/Http/ServerRequest.php#L1467
# Dec 21st 2017, 15:13 neon1024 I’ll stop being lazy and go check
# Dec 21st 2017, 15:12 neon1024 Well you can see that it isn’t from my given code I would hope.