Re: Controllers with same name

2012-07-31 Thread rchavik
On Tuesday, July 31, 2012 11:28:57 AM UTC+7, André Luis wrote: Well, i´ve disabled the Cache and it works fine now, it must be a issue... latter i will submit as a issue. Em segunda-feira, 30 de julho de 2012 10h55min45s UTC-3, André Luis escreveu: Hi all, i am in a big trouble, and i

Re: [Models] saveAll doesn't work

2012-07-31 Thread TWEESTY
Up. Thanks ! -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to

Choose what field show when depth level is 2

2012-07-31 Thread Mariano C.
In CakePHP 2.1 I have prepared a Json webservice. This is an excerpt of what I get: { Offices:[ { Office:{ id:1, Company:{ id:1, name:ABC Software } },

Re: Choose what field show when depth level is 2

2012-07-31 Thread jodator
You can use Containable behavior and write something like this: $Office-find('all', array( ... 'contain' = array(//or 'contains' - check manual ;) 'Company' = array('fields' = array('name')), 'Person' = array( 'fields' = array('mail'), 'OfficePersonTask' = array( )

Re: Error: The requested address was not found on this server.

2012-07-31 Thread Luís de Sousa
Any further suggestions on this issue are very welcome. Thank you. -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from

find with complex conditions (AND and OR)

2012-07-31 Thread scs
I'm trying to perform what has been called a complex condition in some of the documentation I have found. I want to use AND and OR in the conditions portion of my query via find('all', $params). I haven't been able to find anything that seems to match my issue (although I'm sure it's out

How to upload and retrieve an image from databse/dir?

2012-07-31 Thread rahul
Hi i am new to cakephp.I have created a registration form and i want when i fill this form and select an image for a person i can save information with image in database.After saving information i will be able to view that information along with that image. Can anyone help me? -- Our newest

Re: find with complex conditions (AND and OR)

2012-07-31 Thread Carlos Lavin
Try something like this: $params = array('contain' = 'Product.name', 'fields' = array('DISTINCT(Equipment.product_id) AS id', 'Product.name'), 'order' = array('Product.name'), 'group' = array('Equipment.product_id'), 'conditions' =

Re: control visibility of field with second level of depth

2012-07-31 Thread Carlos Lavin
Have you tried using the 'Containable' behavior? http://book.cakephp.org/1.3/view/1323/Containable 2012/7/30 Mariano C. mariano.calan...@gmail.com: I have this json: { Offices: [ { Office: { address: JR street Company: { id: 3, name: ABC Software }, }, Person: { id: 1,

html2pdf and cakephp 1.3

2012-07-31 Thread Christian
Hi there, I'm getting a weird error with html2pdf, which I'm using as described here: http://bakery.cakephp.org/articles/Casmo/2010/06/26/creating-pdf-files-with-html2ps-html2pdf I have two domains, both are pointing to the same folder on my web server (both tld's and sub domains are

Re: Linking Models Together

2012-07-31 Thread newt_e
Hi, Thanks for the response, but I'm not entirely sure what your suggesting. An author has many books, and so I can amend the author model to point author.id at book.authorid. Conversely, many books have the same author, so I want the book model to allow book.authorid to reference author.id.

Re: Linking Models Together

2012-07-31 Thread Daniel Baird
http://book.cakephp.org/2.0/en/models/associations-linking-models-together.html#belongsto ...is where belongsTo is documented, you should look over that. But -- even though I hate to be that jerk who points out problems other than the one you asked about -- before you get too far, the data model

Re: Attempting to reparent a TreeBehavior node -- assign new parent_id, lft, and rght values

2012-07-31 Thread lowpass
On Mon, Jul 30, 2012 at 5:58 PM, Kevin Mitchell ke...@ncbible.com wrote: public function reparent($id=null) { $this-TopicTree-id = $id; $newParentId = 51191; $this-TopicTree-save(array('parent_id' = $newParentId)); } I'm no expert but I think that should work. Without diving into the

Selecting hasMany fields

2012-07-31 Thread lirc201
I have an Order that hasMany LineItems. I only want to extract an Order if certain LineItems.fields meet my conditions. I'm using $this-Order-find('list', array( 'conditions' = array('LineItem.event_id' = '3', 'LineItem.pulled' = '1'),

Re: Attempting to reparent a TreeBehavior node -- assign new parent_id, lft, and rght values

2012-07-31 Thread Kevin Mitchell
cricket: Thank you, so very much. It was definitely spinning its wheels because of the lack of redirect statement. Thank you. In addition, in my model, I had added SELF ASSOCIATIONS: belongsTo ParentTopic and hasMany ChildTopic. As soon as I commented those out and added the redirect, it

Is CakePHP more suitable for web services or Zend Framework?

2012-07-31 Thread Lightee
Dear CakePHP gurus, I have no intention to start an emotional thread about which framework is better. Asking this question on this forum is also rather stupid because members here are likely to be biased. Nevertheless, I hope to get objective replies. I would like to build a website that

Re: Is CakePHP more suitable for web services or Zend Framework?

2012-07-31 Thread Dr. Tarique Sani
If you are sure that your project is always going to be web service only I would suggest start with a framework dedicated for such task. eg: Slim http://www.slimframework.com/ Both CakePHP and ZendFW will be an overkill HTH Tarique On Wed, Aug 1, 2012 at 6:55 AM, Lightee lightai...@gmail.com