Re: How can I leave entered value even there is an errro and couldn't complete

2009-08-12 Thread Laeffe
On Aug 11, 11:06 am, leafchild wrote: > How can I get "$this->data" has "recursive = 6" data to avoid getting > "undefined index" error? I believe i had the same problem as you. Or in my case it was an overbelief in cakephp :P What you need to do is to ether re-read the original-data and then m

Re: How to use contained models in conditions?

2009-03-06 Thread laeffe
I guess that your best chance is to switch the direction that you talk with your models. On Mar 6, 7:26 am, Braindead wrote: > Miles, that's bad news. But how can I solve my problem? Is there any > workaround? --~--~-~--~~~---~--~~ You received this message becau

Manipulate data, or behavior, or something.

2008-12-05 Thread laeffe
Hi all. I have a problem that I don't really know how to solve. The actual problem is that I want to parse the way ppl enter time in forms, for instance i want "0600" to be 06:00:00 and 0234 to be 02:34:00 (and of course I want 07:00:00 to be valid as well). That is the basic problem. My solutio

Component and models

2008-05-22 Thread laeffe
Hi, I know this has been discussed before, but I just want it to be clarified. >From within a component I like to access a Model, what would be the "correct" approach? App::import("Model", "Modelname"); $modelname =& new Modelname(); maybe? --~--~-~--~~~---~--~

Re: Database wont update fast enough

2008-05-07 Thread laeffe
gt;create(); if(!$this->Modeltoinserto->save($tmpData)) { echo "QQ"; } } //Laeffe On 7 Maj, 13:09, Unite <[EMAIL PROTECTED]> wrote: > Whats not cakephp except the INSERT INTO. Yes i would use save but i > was trying everything to see if i can get it to work. And m

Dynamic Report/Report Creator.

2008-05-06 Thread laeffe
ct function and later on using pr() to resent it. Quite primitive but it proves the point anyway. Any way, has anyone done something similar or has another idea of approach? //Laeffe --~--~-~--~~~---~--~~ You received this message because you are subscribed to th

Off-topic, php function to ease isset usage?

2008-04-15 Thread laeffe
I wrote this function a couple of months ago for a Webtech course at my university. But I was wondering if anyone has anyother idea to ease this with more intregreated functions. Any way.. the problem is that in my code I often write this peace of code: $variable = isset($anothervariable)?$anothe

Re: saveAll, bug or miss in documentation?

2008-04-14 Thread laeffe
are you running? > If you are refering to cake/libs/model/model.php then it has been > fixed as far as I can see. > > On Apr 14, 1:09 pm, laeffe <[EMAIL PROTECTED]> wrote: > > > Hi all, if I havent missunderstod something I belive that there is > > ether a bug in saveAll o

saveAll, bug or miss in documentation?

2008-04-14 Thread laeffe
i found this is because saveAll stoped returning true after i added a behavior which alters the data for a related model. So, can anyone confirm my idea?' //Laeffe Ps. sorry if my english sucks :P --~--~-~--~~~---~--~~ You received this message because you are sub

Related data missing after a post request.

2008-04-08 Thread laeffe
Hi. So the problem is this. I fetch data for a model which has a couple of relations (hasMany, belongsTo...) and all of this end up in the data array. And then i present this data in my edit form, where some of this data is suppos to be edited, and some is suppos to be there just to support the us

Re: Hide php code in /app from FTP

2008-03-25 Thread laeffe
I would recommend you to look up ACL, if your box is *NIX based. With it you would be able to specify the access rights on a file system basis. I use it my self and it is very useful =D On Mar 25, 10:58 am, Marcel <[EMAIL PROTECTED]> wrote: > Hello, > > I was wondering what the best way would be

findAll and saveAll, question..

2008-02-16 Thread laeffe
Hi all. I'm just woundering if findAll and saveAll works in the "same way". In other words can I take a assoc Array from findAll and save it with saveAll? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" gr

Conditions on a hasMany query.

2008-02-14 Thread laeffe
l? Best Regards Laeffe --~--~-~--~~~---~--~~ 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 P

How to use Model->deconstruct()

2008-01-25 Thread laeffe
Hello all. Just plowed thru a couple of posts discussing (and looked in the api) this issue but I couldn't figure out to use Model->deconstruct().. I thought I could use it like this print_r($this->data); $data = $this->Section->deconstruct("publicationday", $this- >data["Section"]); var_dump($da

Save multipel posts at once

2007-11-22 Thread laeffe
I'm trying to create a page that will submit multipel posts for an model. But i cant figure out how to do it the cake way.. any ideas anyone? //Laeffe --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake

Re: mod rewrite or .htaccess issue

2007-11-17 Thread laeffe
add that to the .htaccess files in your folder, then i think it will work. (these files are in you root, /app/ and /app/webroot/ ) Good luck //Laeffe On Nov 16, 1:31 pm, Indian Baker <[EMAIL PROTECTED]> wrote: > Oh I thought.. I'd mention its a GoDaddy server, but its a dedica

Re: Security in model, will it break MVC?

2007-11-15 Thread laeffe
explain my self. //Laeffe On 21 Okt, 20:38, Gwoo <[EMAIL PROTECTED]> wrote: > this is integrated into the AuthComponent already. > > function beforeFilter() { > $this->Auth->authorize = array('model' => 'User'); > > } > > t

Security in model, will it break MVC?

2007-10-21 Thread laeffe
I've been thinking about wheter or not it's a good idea to place acl check things in the model or not. My idea is to maybe place some sort of generic access check in appModel to interupt the request if the user (of requester) dont have access. But i dont know if that will break the MVC pattern or

Re: homepage with CakePHP (newbie question)

2007-10-21 Thread laeffe
How about some custom-sql, think cake's model have support for that.. check the api.. :P On Oct 19, 2:47 pm, Eric <[EMAIL PROTECTED]> wrote: > Hey guys, > > I have just started using CakePhp, and I have a trouble to find how to > manage my idea. > > So, here is the principle: > I have 3 tables u

Re: Components, Controllers y Elements

2007-10-21 Thread laeffe
Hi, first of I think it's correct to talk about models since models are an abstraction for the tables. Second i think you can use loadModel() to get access to a model that's not in the uses variabel, but you will have to instantiate the object your self, $model = new Model(); Ps. Can anyone plz