Re: SELECT IN in WHERE clause

2009-06-03 Thread jstein
On Jun 1, 10:13 pm, havanna wrote: > SQL Error: 1054: Unknown column 'Array' in 'where clause' Try to post your code - and a debug print of $conditions. Regards Jonathan --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Go

Re: SELECT IN in WHERE clause

2009-06-01 Thread jstein
On Jun 1, 7:25 pm, havanna wrote: > But if I use this one like > $conditions = array('OR' => array('Immobilien.zip' => array > ($svZipCodes))); Try to print the array: debug($conditions); You are telling cake, that the zip field should equal one string with your imploded zip codes. You are ac

Re: Error with HTTPS

2009-06-01 Thread jstein
On Jun 1, 7:30 pm, Pablo wrote: > Did anybody see this before? Any clue? Using HTTP or HTTPS should be the same to Cake. There must be a difference between the configurations on the server. It could look like your .htaccess file is not interpreted with the HTTPS-settings. Regards Jonath

Re: Change form action id

2009-06-01 Thread jstein
On Jun 1, 8:35 pm, Dave wrote: > When I view the rendered HTML it shows > > > where 3 is the user.id. I am using unique slugs in the app,can I > change 3 to the user.slug and if so how can I do this? If you want to know your users by the slug, you should consider modifying the User model. How

Re: Auto Increment ID in Form

2009-05-25 Thread jstein
On May 25, 6:55 pm, "fungied.cheese" wrote: > Where do I insert: > $this->Invoice->id:mail('@example.com', 'New order', 'Invoice id is: ' . > $this->Invoice->id); Inside the controller action - in your case it would be in the function index(). Try to go through the Blog tutorial (http://bo

Re: Auto Increment ID in Form

2009-05-25 Thread jstein
On May 25, 7:44 am, "fungied.cheese" wrote: > First person comes and filles out the form, on the top of the form it says > "Invoice 1" and once he hits submit I receive all the information in my > email including the ID number. And now second person will have invoice 2, > etc, etc. Let's say yo

Re: copying cakeapp from windows to linux

2009-05-24 Thread jstein
On May 24, 1:29 pm, forrestgump wrote: > i should also mention i downloaded and installed the latest version of > cakephp (CakePHP 1.2.3.8166) , and it seems to be working fine on my > ubuntu box. When you have a working installation of Cake, try to copy the content of your "app" folder from the

Re: $model->save - which id is used?

2009-05-10 Thread jstein
On May 10, 5:52 pm, Enrique wrote: > The id can be found in $this->data. No. My first thought was that the form helper would insert a hidden field with the id - but it doesn't (and debug($this->data) shows that the id is not present in the data). Now I did some investigations, and I guess that

Re: $model->save - which id is used?

2009-05-10 Thread jstein
On May 10, 4:35 pm, Rick wrote: > Take a look at $this->Recipe.  I think it is in there. > > debug($this->Recipe); Yes - $this->Recipe->id is set to the correct id - but then again: How? Regards Jonathan --~--~-~--~~~---~--~~ You received this message be

Re: Permission problem in baking script

2009-05-10 Thread jstein
On May 9, 7:30 am, zarbizade wrote: >  The error is something like this "Web Server has not Permission To > create file in /var/www/app/temp" . > Is there any Solution to These problem.If i try to give permission > using my root user will be work or not? No guarantee, but the /app/tmp directory

Re: $model->save - which id is used?

2009-05-10 Thread jstein
On May 10, 8:25 am, JamesF wrote: > on edit it uses the id of the record you pulled up. Thanks for your reply, - but I don't pull up anything before I call save... The id of the record to be modified is only present as a parameter to the edit function. In some "auto-magic" way, the model learn

Re: Poll: what do you hate about CakePHP?

2009-05-08 Thread jstein
On May 8, 10:39 am, Affinity wrote: > Lack of a good, proper support forum. I'll vote for that too. I would surely be more active, if the forum had an NNTP-interface. Regards Jonathan --~--~-~--~~~---~--~~ You received this message because you are subscr

Re: Need little help with a validation rule

2009-04-29 Thread jstein
On Apr 29, 6:00 pm, brian wrote: > Just use a rule (eg. notEmpty) for each of them. You'll get errors for > whichever fields were not set. No, "notEmpty" will fail validation, if the field is present but empty. It will NOT fail, if the field is not set at all. If the field MUST be set, use 'req

Re: Required form field NOT marked with "required" CSS class

2009-04-29 Thread jstein
> IF it doesn't have to be present, its NOT a required field ;-) > > To make CakePHP add the required classes you must include the addition > rule "required"=>true That's exactly the problem: From a model point of view, the field is NOT required, but from a form point of view, it IS required. I

Re: Required form field NOT marked with "required" CSS class

2009-04-29 Thread jstein
On Apr 28, 5:40 pm, brian wrote: > Add 'allowEmpty' = true for number. According to the documentation, that would bypass validation, if the field is present but empty. I need the opposite: IF the field is present, it must NOT be empty (and it must be unique). The validation seems to work, but