Re: Subquery in join clause in CakePHP 2.2

2012-08-27 Thread Mark Wratten
Figured it out for myself, the subquery just goes in place of the table name. On Monday, August 27, 2012 6:17:05 PM UTC-4, Mark Wratten wrote: > > Is there a 'Cake' way of including subqueries in join clauses of SQL > select statements? > > I'm looking to generate something in the form of - > >

Re: New video tutorial: CakePHP basics part 5 - Layouts and Elements

2012-08-27 Thread soda sonic
Thank you my Bro. 2012/8/28 frederikjacques > Hi cake lovers, > > I've just uploaded part 5 of my cakePHP basics tutorial series. > In this one I'll explain how you can use layouts and view elements! > > http://blog.the-nerd.be/2012/08/cakephp-basics-tutorial-part-5/ > > Hope you like it! > > Ch

Re: Form validation and business logic

2012-08-27 Thread Dr. Tarique Sani
> Please help me with my doubts of form validation, is form validation a part > of business logic? > if yes, then why we put this in Controller? You are not supposed put form validation logic in Controller - if you are doing it then it is wrong Tarique -- ===

Re: Form validation and business logic

2012-08-27 Thread Greg Skerman
Not sure I follow.. "form validation" is data validation - it rightly belongs in the model. The concept of "fat models" suggests that business logic should be pushed back closer to the business objects (i.e. put business logic in the model), and leave controllers to manage flow. The authenticatio

Form validation and business logic

2012-08-27 Thread sanjay.pal
Hi all, As per my knowledge, Business Logic is the part of Model in MVC architecture. Please help me with my doubts of form validation, is form validation a part of business logic? if yes, then why we put this in Controller? if no, then what is actually a business logic in a authentication mod

Re: Fatal Error: Class 'String' not found in Model

2012-08-27 Thread Dmitriy Ermolin
http://book.cakephp.org/2.0/en/models/callback-methods.html#beforesave Specify 'array $options = array()' as parameter for beforeSave() and error message will disappear. четверг, 3 мая 2012 г., 4:21:16 UTC+4 пользователь Conor Manning написал: > > I have a web application that has been working f

Form validation and business logic

2012-08-27 Thread Sanjay
Hi all, As per my knowledge, Business Logic is the part of Model in MVC architecture. Please help me with my doubts of form validation, is form validation a part of business logic? if yes, then why we put this in Controller? if no, then what is actually a business logic in a authentication modul

Subquery in join clause in CakePHP 2.2

2012-08-27 Thread Mark Wratten
Is there a 'Cake' way of including subqueries in join clauses of SQL select statements? I'm looking to generate something in the form of - SELECT ... FROM table1 JOIN (SELECT DISTINCT key FROM table2 WHERE ...) table2 ON table2.key = table1.key I have been looking at joining tables in the docs

Re: Passing arguments to a Pages

2012-08-27 Thread lowpass
Yes, I meant "display" not "view". I can show what I did for one of my own sites wit a modified PagesController to fetch content from the database. public function display($slug = null) { if (empty($slug)) { $slug = 'index'; } $data = $this-

Re: Passing arguments to a Pages

2012-08-27 Thread Mariano C.
I have just one "problem". I used Page, cause I need no action, matter of fact, i'm using default action (i.e. display) I should ovverride the default display() and change on my need. It's possible? How could change it. Il giorno lunedì 27 agosto 2012 20:18:04 UTC+2, cricket ha scritto: > > And

Re: In CakePHP 2.x Extending Views not working.. I think the documentation for 2.0 is wrong. How to work Extending Views concept ?

2012-08-27 Thread Mancho
Remove white spaces and new lines before http://groups.google.com/group/cake-php?hl=en-US.

Re: CakePHP 2 and hyphens on the router

2012-08-27 Thread lowpass
Sorry, I can't help. I never use the ":action" placeholder in routes so I'm not clear on what the issue could be. I prefer to specify all the possible routes. There shouldn't be any trouble with updating Cake's libs unless there is a big change in how routing is done. On Mon, Aug 27, 2012 at 9:47

Re: Passing arguments to a Pages

2012-08-27 Thread lowpass
You could use SluggableBehavior in the Page model. Router::connect( '/clienti/:slug', array( 'controller' => 'pages', 'action' => 'view' ), array( 'slug' => '[-a-z]+' 'pass' => array('slug') ) )

Re: In CakePHP 2.x Extending Views not working.. I think the documentation for 2.0 is wrong. How to work Extending Views concept ?

2012-08-27 Thread AD7six
Well, when you access /users/add - where or what is supposed to be putting content in the "sidebar" content block? There's nothing in the add view to do that; the contents of your index.ctcp file are irrelevant because your add.ctp file neither references it nor extends it. AD On Monday, 27 Au

New video tutorial: CakePHP basics part 5 - Layouts and Elements

2012-08-27 Thread frederikjacques
Hi cake lovers, I've just uploaded part 5 of my cakePHP basics tutorial series. In this one I'll explain how you can use layouts and view elements! http://blog.the-nerd.be/2012/08/cakephp-basics-tutorial-part-5/ Hope you like it! Cheers, Frederik -- You received this message because you are s

Re: CakePHP Autobaker for v.1.3

2012-08-27 Thread Ivan Rimac
Mac version, is it planned? 2012/8/27 Łukasz Michalczyk > Welcome everybody. > I would like to announce a new CakePHP support application. > It's called AutoBaker, based on Adobe AIR. > It has UI for automatic baking projects entities. > More information on http://autobaker.xaa.pl > Sorry for

In CakePHP 2.x Extending Views not working.. I think the documentation for 2.0 is wrong. How to work Extending Views concept ?

2012-08-27 Thread Steve Babs
I have created . Views/Users/add.ctp --- fetch('title'); ?> fetch('content'); ?> Related actions fetch('sidebar'); ?> Views/Users/index.ctp --- extend('/User/add'); $this->assign('title', $users['User']['0']['us

CakePHP Autobaker for v.1.3

2012-08-27 Thread Łukasz Michalczyk
Welcome everybody. I would like to announce a new CakePHP support application. It's called AutoBaker, based on Adobe AIR. It has UI for automatic baking projects entities. More information on http://autobaker.xaa.pl Sorry for my english, I'm from poland. Thank You. -- You received this message

Re: Fatal error with fresh installation of CakePHP 2.2 and migrated 2.0 app

2012-08-27 Thread Daniel
That did the trick. Thanks. -- You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com. Visit this group at ht

Re: CakePHP 2 and hyphens on the router

2012-08-27 Thread Salines
Yes, you need tp re- read cake documentation. Start from here: http://book.cakephp.org/2.0/en/getting-started/cakephp-conventions.html Dana ponedjeljak, 27. kolovoza 2012. 15:47:17 UTC+2, korisnik Mohammad Naghavi napisao je: > > Hi again, > so I defined the routing approach but now I have a ne

Re: CakePHP 2 and hyphens on the router

2012-08-27 Thread Mohammad Naghavi
Hi again, so I defined the routing approach but now I have a new problem. I have defined this routing rule in app/Config/routes.php: Router::connect('/my-controller/:action/*', array('controller' => 'my_controller')); and in my view, I have a link like this: Html->link('some title', array('control

Re: Cake 2.1 Problem creating Aro records from existent users

2012-08-27 Thread kani
Yes me too On Tuesday, April 3, 2012 8:44:46 AM UTC+8, Arnold wrote: > > Hi, > > I'm trying to implement ACL for my already created application and > need to create the aro records for my current existent users. On IRC > Ceeram said i just need to load AclBehaviour into my User's model, > find all