Re: 's' vs. 'ies' plural for table names

2006-08-22 Thread Zoltan


John David Anderson (_psychic_) wrote:
 On Aug 21, 2006, at 9:33 AM, Zoltan wrote:

 
  Yes, I tried it and it seemed to work at first, then got some errors
  about missing controllers. This was about a week ago, but going from
  memory I used something like:
 
  class City extends AppModel
  {
  var $name = 'City';
  }
 
  and
 
  class CitiesController extends AppController
  {..}

 var $name = 'Cities';

 (always a good idea to include $name, even in  your controllers).

  Does this look correct?

 Looks good to me - are you still getting errors?
 
 -- John

It's working fine now, Thanks!

Zoltan


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cake-php
-~--~~~~--~~--~--~---



Re: Re: 's' vs. 'ies' plural for table names

2006-08-22 Thread Samuel DeVore

So I usually have a .thtml page in my views/pages that looks like


http://cakephp.org/pastes/show/ebb93d95243037fcca3d73ae04c69b72

This lets me test my assumptions about how things are going to work.

Sam D

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cake-php
-~--~~~~--~~--~--~---



Re: 's' vs. 'ies' plural for table names

2006-08-22 Thread [EMAIL PROTECTED]

thanks mate :)


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cake-php
-~--~~~~--~~--~--~---



Re: Re: 's' vs. 'ies' plural for table names

2006-08-22 Thread Samuel DeVore

I really need to start a page of the 'old fart's oven o' baking hints'

On 8/22/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:

 thanks mate :)


 


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cake-php
-~--~~~~--~~--~--~---



Re: 's' vs. 'ies' plural for table names

2006-08-22 Thread [EMAIL PROTECTED]

then get cooking chef, i'm hungry ;-)


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cake-php
-~--~~~~--~~--~--~---



Re: 's' vs. 'ies' plural for table names

2006-08-21 Thread John David Anderson (_psychic_)


On Aug 21, 2006, at 9:21 AM, Zoltan wrote:


 A bit of a newbies question here, but what is the correct way to  
 handle
 tables like 'city', should I name it 'cities' or 'citys'?

Have you tried it?

Should be 'cities'.

-- John

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cake-php
-~--~~~~--~~--~--~---



Re: 's' vs. 'ies' plural for table names

2006-08-21 Thread Zoltan

Yes, I tried it and it seemed to work at first, then got some errors
about missing controllers. This was about a week ago, but going from
memory I used something like:

class City extends AppModel
{
var $name = 'City';
}

and

class CitiesController extends AppController
{..}

Does this look correct?


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cake-php
-~--~~~~--~~--~--~---



Re: 's' vs. 'ies' plural for table names

2006-08-21 Thread John David Anderson (_psychic_)


On Aug 21, 2006, at 9:33 AM, Zoltan wrote:


 Yes, I tried it and it seemed to work at first, then got some errors
 about missing controllers. This was about a week ago, but going from
 memory I used something like:

 class City extends AppModel
 {
 var $name = 'City';
 }

 and

 class CitiesController extends AppController
 {..}

var $name = 'Cities';

(always a good idea to include $name, even in  your controllers).

 Does this look correct?

Looks good to me - are you still getting errors?

-- John

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cake-php
-~--~~~~--~~--~--~---



Re: 's' vs. 'ies' plural for table names

2006-08-21 Thread Samuel DeVore
usually when I am starting a site that might have funky plurals I make a page that calls the Inflector class with the various calls for the words to see what cake thinks the plurals will be, if they are not what I expect, I either add them in the config/inflectors.php or change my thinking ;)
On 8/21/06, nate [EMAIL PROTECTED] wrote:
Our inflector is pretty darn good, and can properly inflect mostEnglish words without any extra hinting.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake PHP group.  To post to this group, send email to cake-php@googlegroups.com  To unsubscribe from this group, send email to [EMAIL PROTECTED]  For more options, visit this group at http://groups.google.com/group/cake-php  -~--~~~~--~~--~--~---