# |
Apr 16th 2017, 21:16 |
damiano |
i am doing that into a middleware |
# |
Apr 16th 2017, 21:16 |
damiano |
hi guys how to return 200 on response without content (without calling the controller etc) |
# |
Apr 16th 2017, 19:42 |
joop |
whats the way to use deeper association in $this->Auth->user() like $this->Auth->user(Role.name)? |
# |
Apr 16th 2017, 19:01 |
Yuv |
Description or Descriptions? |
# |
Apr 16th 2017, 18:46 |
developer1211 |
$this->loadModel('Description'); $this->layout = "admin_layout"; $this->set('title_for_layout', "Edit Page"); //echo 'id'.$id; if (!$id) { throw new NotFoundException(__('Invalid content')); } $description = $this->Description->findById($id); pr($description); exit; if (!$description) { throw new NotFoundException(__('Invalid content') |
# |
Apr 16th 2017, 18:46 |
developer1211 |
can anyone highlight mistake in the code? |
# |
Apr 16th 2017, 18:46 |
developer1211 |
I have a simple problem in edit |
# |
Apr 16th 2017, 18:45 |
developer1211 |
Hello guys |
# |
Apr 16th 2017, 18:25 |
joop |
thank you for your answer slackbot5 |
# |
Apr 16th 2017, 18:23 |
admad |
joop: AppController::beforeRender() { if ($admin) $this->viewBuilder()->layout('admin_layout'); } |
# |
Apr 16th 2017, 18:19 |
joop |
but don't know how can i do that in the controller |
# |
Apr 16th 2017, 18:19 |
joop |
i have already written admin_layout.ctp,user_layout.ctp |
# |
Apr 16th 2017, 18:18 |
joop |
is anyone who can tell me how can i use different layout for different users? |
# |
Apr 16th 2017, 18:17 |
joop |
Happy Easther to you all |
# |
Apr 16th 2017, 18:17 |
joop |
hello |
# |
Apr 16th 2017, 17:51 |
obinoob |
Yuv: my next move is to write it at the validator ;) |
# |
Apr 16th 2017, 17:40 |
Yuv |
:D |
# |
Apr 16th 2017, 17:39 |
obinoob |
Yuv: hehe ok not a problem I'm glad you had the the opportunity to say it ;) |
# |
Apr 16th 2017, 17:38 |
Yuv |
My net connect is slow, couldnt help you |
# |
Apr 16th 2017, 17:38 |
Yuv |
Cool |
# |
Apr 16th 2017, 17:38 |
obinoob |
*as |
# |
Apr 16th 2017, 17:37 |
obinoob |
Yuv: got it I can compare dates I wasn't sure I could do it has they are objects... |
# |
Apr 16th 2017, 17:29 |
obinoob |
Yuv: what I mean is that $given_date will never go behind Time::now()->subDays(7) |
# |
Apr 16th 2017, 17:28 |
obinoob |
but I need to assure that $given_date is never less that Time::now()->subDays(7) |
# |
Apr 16th 2017, 17:27 |
obinoob |
yes it works I mean I get now less 7 days |
# |
Apr 16th 2017, 17:25 |
Yuv |
doesn't work? |
# |
Apr 16th 2017, 17:24 |
obinoob |
yes |
# |
Apr 16th 2017, 17:24 |
Yuv |
obinoob: you posted this. did you try? Time::now()->subDays(7) |
# |
Apr 16th 2017, 17:20 |
obinoob |
*within |
# |
Apr 16th 2017, 17:20 |
obinoob |
How can I determine if a given date is width 7 days from now() ? |
# |
Apr 16th 2017, 17:11 |
obinoob |
I need to check if given date goes behind 7 days than Time::now(), can i use Time::now()->subDays(7) and compare dates? |
# |
Apr 16th 2017, 17:00 |
slackebot5 |
on the new page (the users is forwarded to a cake 2 page) and than he is logged out and has a new value in its cookie.. any ideas how to resolve this or do it in a better way? |
# |
Apr 16th 2017, 17:00 |
jojomartius |
hello all, i’m trying to share a session between two different cake instances (cake 2 and cake 3), the users logs in in cake 2, does most of its stuff but some pages are already implemented already in cake 3, so that pages are delivered by cake 3. that works great as long as its a static page - after changing the cookie name of both instances to the same the first request is served correctly and the users appears to be logged in, but if |
# |
Apr 16th 2017, 14:29 |
joop |
all happy Eater to you all! |
# |
Apr 16th 2017, 14:29 |
joop |
hello |
# |
Apr 16th 2017, 11:43 |
dereuromark |
in case anyone is interested in this cakephp internal backend driven translations plugin let me know, guys |
# |
Apr 16th 2017, 11:38 |
hiromi2424 |
and every php frameworks uses po files but bored. |
# |
Apr 16th 2017, 11:37 |
hiromi2424 |
iOS translation: sucks, android translation: normal.. but not bored work needed |
# |
Apr 16th 2017, 11:36 |
hiromi2424 |
yeah I’d not like to think about long/many translations… though my translations almostly for 2 languages. |
# |
Apr 16th 2017, 11:34 |
dereuromark |
for me translating longer static texts is so painful right now.. lucky me I only have one bi-lang website to manage |
# |
Apr 16th 2017, 11:34 |
bravo-kernel |
remember, I'm your average end-user, no pro. Most of those features are totally alien to me ;) |