Re: Proper design of networks with CakePHP...

2007-06-24 Thread Grant Cox
Well, don't write the SQL yourself of course, something like $user_story_conditions = array( 'city_id' => $Session->read('logged_in_user_city_id') ); $user_stories = $this->Story->findAll( array('Story'=> $user_story_conditions) ); would be better. For rating, the only thing that springs to m

Re: Proper design of networks with CakePHP...

2007-06-24 Thread Grant Cox
> Although, I will have variables in the user file > for things like "show thread where user_location_id=city_id" Do you mean that the controller action will need to retrieve database information (ie posts, news articles, threads) based upon the current user's details (ie location)? This should

Re: Proper design of networks with CakePHP...

2007-06-23 Thread inVINCable
On Jun 23, 6:00 pm, Grant Cox <[EMAIL PROTECTED]> wrote: > Unless the views are quite different between cities, definitely use a > single view file. > > In MVC your controller should load whatever data is appropriate for > the request, and the view just renders that data (into HTML, or RSS, > or

Re: Proper design of networks with CakePHP...

2007-06-23 Thread Grant Cox
Unless the views are quite different between cities, definitely use a single view file. In MVC your controller should load whatever data is appropriate for the request, and the view just renders that data (into HTML, or RSS, or JSON, or whatever particular format the request needs). In what you

Proper design of networks with CakePHP...

2007-06-23 Thread inVINCable
I have been creating various websites for hire the past few months. Most have been basic logins, shopping carts, etc. And they have all been using PHP and the SMARTY template system. I have been fuddling around with CakePHP for about 10 hours already the past few days to get a feel for it. I have