Re: Bakery is not updating?

2008-05-01 Thread Vangel
thanks all, but my original question was, if i submit an article to bakery, and nothing happens. No emails, no comments, and no update to the status, what do I do? Is this happening only to my pst or others as well? Because if thats the case, obviously we wont see any useful stuff ever show up in

Re: Looking for the Rapid in Cakephp

2008-05-01 Thread Chris Hartjes
On Thu, May 1, 2008 at 11:12 PM, Dardo Sordi Bogado <[EMAIL PROTECTED]> wrote: > No, I'm a free (not as in beer) software guy, so it will not work for > me, thanks anyway. I will hopefully end this thread by crushing someone's spirit: I use free software to code in Cake...on my MacBook...so un

Re: Looking for the Rapid in Cakephp

2008-05-01 Thread Dardo Sordi Bogado
On Thu, May 1, 2008 at 4:35 PM, mbavio <[EMAIL PROTECTED]> wrote: > > This group doesnt allow you to speak badly about Mac! :P > > No, seriously, have you tried some Mac development? I can asure you > that you wont go back never more to your PC. No, I'm a free (not as in beer) software guy, so

Re: Unique ID that could be referencing more than one model

2008-05-01 Thread validkeys
perfect. Thanks for the responses guys! On May 1, 9:35 pm, "Dardo Sordi Bogado" <[EMAIL PROTECTED]> wrote: > This may be of > help:http://bakery.cakephp.org/articles/view/polymorphic-behavior > > On Thu, May 1, 2008 at 10:28 PM, patcoll <[EMAIL PROTECTED]> wrote: > > > fwiw, that's what Cake AC

Re: Unique ID that could be referencing more than one model

2008-05-01 Thread Dardo Sordi Bogado
This may be of help: http://bakery.cakephp.org/articles/view/polymorphic-behavior On Thu, May 1, 2008 at 10:28 PM, patcoll <[EMAIL PROTECTED]> wrote: > > fwiw, that's what Cake ACL does as well to reference different models > in one table > > 'model' -- references the cake model > 'foreign_ke

Re: Unique ID that could be referencing more than one model

2008-05-01 Thread patcoll
fwiw, that's what Cake ACL does as well to reference different models in one table 'model' -- references the cake model 'foreign_key' -- references the unique id to that model's table. On May 1, 9:01 pm, Grant Cox <[EMAIL PROTECTED]> wrote: > That's the way I do it, and have had no problems.  It

Re: Unique ID that could be referencing more than one model

2008-05-01 Thread Grant Cox
That's the way I do it, and have had no problems. It is quite trivial to set up conditions on your associations, so that the associated rows are loaded automatically. On May 2, 9:52 am, validkeys <[EMAIL PROTECTED]> wrote: > Quick question.. > > I have a conversation going on between users and

Re: Unique ID that could be referencing more than one model

2008-05-01 Thread Marcin Domanski
Maybe use uuid based primary key? (char 36) On Fri, May 2, 2008 at 1:52 AM, validkeys <[EMAIL PROTECTED]> wrote: > > Quick question.. > > I have a conversation going on between users and managers. users and > managers are 2 seperate tables but the conversation posts are held in > one table.

why does cache view keep on regenerating

2008-05-01 Thread robert123
I am using the latest Cake build (1.2.0.6311 beta) I have enable caching on my system by the two statement in the core file Configure::write('Cache.disable', false); Configure::write('Cache.check', true); The first time I accessed the url, a cache view is generated in app \tmp\cache\views. Bu

Unique ID that could be referencing more than one model

2008-05-01 Thread validkeys
Quick question.. I have a conversation going on between users and managers. users and managers are 2 seperate tables but the conversation posts are held in one table. When i reference the post i reference it by id and then have a field called model. The model field would hold either the word Mana

Re: ACL Console issues

2008-05-01 Thread gmwebs
Sorry... forgot to tick save. Please see: http://bin.cakephp.org/saved/31645 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscr

ACL Console issues

2008-05-01 Thread gmwebs
I am trying to figure out the Auth/Acl component and have started to grasp how things *should* work, but am having problems creating Aros with the console command. Please would you have a look at http://bin.cakephp.org/view/2059927768 and provide any pointers? --~--~-~--~~

Re: LEFT JOIN association type

2008-05-01 Thread KooT
On 1 Maj, 13:03, validkeys <[EMAIL PROTECTED]> wrote: > Your film model belongs to your type model and your type model hasMany > of your film model. So use those associations and you will get hwat > you are looking.. let me know if that works for you Yes, its working! In Film model: var $belo

Re: Help with $this->Model->find('all')

2008-05-01 Thread [EMAIL PROTECTED]
Cake doesn't have an excellent way of doing this yet but grigri posted this method the other day: http://groups.google.com/group/cake-php/browse_thread/thread/863305f8a7267067 which is a lot better than writing out the SQL by hand. quoted (grigri): I know nothing about using MySQL views, but I

Help with $this->Model->find('all')

2008-05-01 Thread clrockwell
I have two associated models - Newproduct hasMany Newproductimage - Ideally, I need to do a find that only returns the Newproductimage where 'newproductimage.thumbnail' is set to 1 Doing: $conditions = array('Newproductimage.thumbnail' => 1) $this->Newproduct->find('all', array('conditions' => $

Re: Looking for the Rapid in Cakephp

2008-05-01 Thread mbavio
This group doesnt allow you to speak badly about Mac! :P No, seriously, have you tried some Mac development? I can asure you that you wont go back never more to your PC. And about writing HTML, it´s always about tastes, I love to write good and semantic html, without any kind of helpers. Cheers

Re: Looking for the Rapid in Cakephp

2008-05-01 Thread Dardo Sordi Bogado
> Lol, if you want to write html fast, use some ide with autocomplete > function, or the magic of Textmate. I dont see the benefits of using > CakePHP in that cases. Seems to me like shooting to flies with canons. I do use an ide with autocomplete, just I don't like to write HTML, is just easi

Re: Database adding unwanted entries

2008-05-01 Thread [EMAIL PROTECTED]
There was abug with saving HABTM data a while back: http://groups.google.com/group/cake-php/browse_thread/thread/2ad48c4e10f58fc0/c7c4511051071b52#c7c4511051071b52 not sure if it ever got fixed, but you might try out the suggested fix and see if that helps. On Apr 29, 5:28 pm, "b logica" <[EMAI

Re: Looking for the Rapid in Cakephp

2008-05-01 Thread [EMAIL PROTECTED]
I love the little t-rex next to the login link awesome. On May 1, 6:56 am, validkeys <[EMAIL PROTECTED]> wrote: > depending on your needs with this form as well, i would try something > likehttp://www.wufoo.com > > its a pretty great application and form builder. > > On May 1, 5:41 am, mbavio

Re: CakePHP css files

2008-05-01 Thread Sliv
which site are you talking about, and why can't you grab the links from the page source? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com

Re: CakePHP css files

2008-05-01 Thread Samuel DeVore
like this? http://cakeforge.org/themes/cake/css/forge.css On Thu, May 1, 2008 at 8:19 AM, Carl <[EMAIL PROTECTED]> wrote: > > Anybody know where I can find copies of the css files used on the > CakePHP site (forge.css, legacy.css, etc.) ? > > > -- -- (the old fart) the advice is free,

Re: Can cake do this or am I asking too much

2008-05-01 Thread Flipflops
Hi JoC For me one of the things I like most about cake isn't so much managing all the associations (although that is very nice (indeed)) it is the fact that the rigid MVC structure makes it easy to find bits of code because everything has its own place in the structure and is logically organised.

CakePHP css files

2008-05-01 Thread Carl
Anybody know where I can find copies of the css files used on the CakePHP site (forge.css, legacy.css, etc.) ? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake

Re: accents not working with __()

2008-05-01 Thread Ithaka
Correction to my previous post: (était = & #233tait (without space)) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from

Re: Can cake do this or am I asking too much

2008-05-01 Thread [EMAIL PROTECTED]
"HABTM is only meant for 2 entities. How can you tell cake to handle a relationship of more than 2 entities (i.e. the join table has 3 or more foreign keys)?" You can access more fields in a HABTM join table using the "with" key in the HABTM relationship definition. I've only used extra fields in

Re: Inserting records via a model

2008-05-01 Thread Dovdimus Prime
Ah thanks. I needed to call create first. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [

Re: CakePHP app without a View?

2008-05-01 Thread validkeys
The following is my ASSUMPTION When your non-cake app request XML info from your cake app, it is basically requesting a page with XML. In your posts controller, you would run your find all query and then pass it to the view. In the view you would construct your XML. When your requesting app went

CakePHP app without a View?

2008-05-01 Thread PST
Hello, I am trying to use CakePHP to create some basic webservices. I have an application that I would like to request data from a CakePHP webservice. For example, a basic findAll() performed on the posts table from the CakePHP tutorial, would need to pass back the records in XML format to the re

Re: Inserting records via a model

2008-05-01 Thread validkeys
If you are doing all of this in your prompt model, you dont need to specify $this->Prompt. Try this: if(!empty($this->data)){ $this->create(); if($this->save($this->data)){ return true; }else{ return false; } } On May 1, 9:23 am

Inserting records via a model

2008-05-01 Thread Dovdimus Prime
Hi there I'm having difficulty inserting a new record. Documentation is pretty thin on the ground. My 'prompts' table has an autogenerated id, and a content field. In the Prompt controller I am making the following call to the Prompt model: $this->Prompt->id = null; $this->Prompt->save(array('

Re: Looking for the Rapid in Cakephp

2008-05-01 Thread validkeys
depending on your needs with this form as well, i would try something like http://www.wufoo.com its a pretty great application and form builder. On May 1, 5:41 am, mbavio <[EMAIL PROTECTED]> wrote: > I was talking just about XHTML code and some simple forms... If you > are going to grow so much,

Re: Model conditions using session variable

2008-05-01 Thread validkeys
thanks zaboo. I guess what i was trying to figure out was: If in every query on the users table I need to put the condition that the user or users returned must belong to the session company, it seems a bit repetetive and therefore was trying to place that condition on the model to save me some t

Re: Simple MVC Question

2008-05-01 Thread validkeys
Hey Annie, I had similar problems when I started and still have problems sometimes (although less often now) regarding where things go and try to stick to the MVC architecture. This is sort of what i think about when i have this problem. 1. If i am doing a complicated query (more than one conditi

Re: simulating subdomains with the router rules?

2008-05-01 Thread validkeys
this is what i use for my subdomains: if(!isset($_GET['url'])){ $_GET['url'] = '/'; } if (env("HTTP_HOST") == "admin.mydomain.com") { $_GET["url"] = "admin/" . $_GET["url"]; }elseif(env("HTTP_HOST") == "admin.mydomain"){ if(!isset($_GET['url'])){

Re: LEFT JOIN association type

2008-05-01 Thread validkeys
in you wouldn't use left join explicity. cake will use left join to query your data. Your film model belongs to your type model and your type model hasMany of your film model. So use those associations and you will get hwat you are looking.. let me know if that works for you On May 1, 4:09 am, K

Re: simulating subdomains with the router rules?

2008-05-01 Thread Marcin Domanski
please search, there is a bakery article with great comments and a lot f resources in this group. On Thu, May 1, 2008 at 12:50 PM, Kupe3 <[EMAIL PROTECTED]> wrote: > > Hi > i have companies controler, so i have > site.com/companies/details/company_name > but now they want to have subdomains f

simulating subdomains with the router rules?

2008-05-01 Thread Kupe3
Hi i have companies controler, so i have site.com/companies/details/company_name but now they want to have subdomains for each company, so it should accept links like http://company_name.site.com and redirects to http://site.com/companies/details/company_name As i am not expirienced in regex and

JSObject Exception

2008-05-01 Thread oana
Hello, In my .php file I am trying to use an applet which calls JSObject.getWindow(this); I keep getting this: netscape.javascript.JSException at netscape.javascript.JSObject.getWindow(Unknown Source) When i test the applet alone (not in the cake suite it wotks perfect). I added to the

LEFT JOIN association type

2008-05-01 Thread KooT
How to make this query below, with one of this association type: hasOne, hasMany ,belongsTo, hasAndBelongsToMany ? Its just one simple LEFT JOIN, but i cant figure out how to make it... function getData() { $ret = $this->query("SELECT films.id, films.title, films.body, films.pubdate, types.

Re: Looking for the Rapid in Cakephp

2008-05-01 Thread mbavio
I was talking just about XHTML code and some simple forms... If you are going to grow so much, of course, use CakePHP, but that is a matter of application design. Cheers, mbavio On May 1, 5:58 am, "Marcin Domanski" <[EMAIL PROTECTED]> wrote: > But these flies could mutate into giant-human-eating

Re: Simple MVC Question

2008-05-01 Thread annie.r.knight
Thanks again, It's starting to make sense now -- switching views depending on the result of the validation wasn't something I was really contemplating but I see how that would be a cleaner solution. I may be on IRC later to confirm my understanding! Much appreciated. On May 1, 10:10 am, "Marcin

Re: Simple MVC Question

2008-05-01 Thread Marcin Domanski
if you do it my way - the error message from the validate array will be put under the dropdown on the same page. in the action there would be something similar to bake generates but with $this->Model->validates() iinstead of save() if it valdiates - show the other view with the table you can come

Re: Simple MVC Question

2008-05-01 Thread annie.r.knight
Thanks for the quick reply. I'm not sure whether that solves my problem: I'm okay with selecting which output to produce, my problem is in the construction of the books table/warning message. Where does this occur? What I've got at the moment is something like this in the view: if(!$showtable)

Re: Looking for the Rapid in Cakephp

2008-05-01 Thread Marcin Domanski
But these flies could mutate into giant-human-eating-flies and what will you do? throw mysql_connect at them ? ;) I'm using cake for simple stuff too, i hate when i have to maintain some crazy-spaghetti code (for italian peopl - belive it or not but spaghetti here isn't good ;) On Thu, May 1,

Re: Acl Cake 1.2

2008-05-01 Thread Q
I found this really useful, http://www.webdevelopment2.com/cakephp-auth-component-tutorial-1/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroup

Re: Simple MVC Question

2008-05-01 Thread Marcin Domanski
Hey, >From what you said you want to make a validation rule like >0 (if 0 is the value of ---please select a genre---) and Model::validate() it (you probably dont want to save it), if it valdiates - show the books On Thu, May 1, 2008 at 9:54 AM, annie.r.knight <[EMAIL PROTECTED]> wrote: > > ...

Re: Auth Componant question

2008-05-01 Thread Q
Hi, I've actuall just sussed this out so i'm going to post the solution here incase anyone else searches on this problem: I put this in my app_controller inside function beforeFilter: //this first line tests to see if the user is in the admin group - in this case with the ID of 1 if ($this->Au

Re: Auth Componant question

2008-05-01 Thread Marcin Domanski
look at Auth::autoRedirect [1], turn it off and redirect manually [1] http://api.cakephp.org/1.2/auth_8php-source.html#l00182 HTH, On Thu, May 1, 2008 at 8:24 AM, Q <[EMAIL PROTECTED]> wrote: > > Hi, > > I have a project setup to authorise access to both admin pages (admin > routes) and publ

Simple MVC Question

2008-05-01 Thread annie.r.knight
... at least I hope it's simple for you guys. Clearly it's not simple for me otherwise I wouldn't be asking here. I'm using 1.2. I'm trying to get the structure of my app 'right' in terms of MVC execution flow (and CakePHP's implementation of this flow). Here's my situation: I've got a page wher

Re: "save" oddity

2008-05-01 Thread annie.r.knight
ValidKeys - thanks very much for your helpful answer. On May 1, 2:20 am, validkeys <[EMAIL PROTECTED]> wrote: > p.s if you dont update, > > change your code to this: > function add() { > > if (!empty($this->data)) { > $this->Closeddate->create(); >

Re: Can cake do this or am I asking too much

2008-05-01 Thread zonium
1. Many times I create a complete MVC for the join table, especially when I need to build complicated/flexible admin interfaces to work directly with additional fields in the join table. 2. I am not sure if cake can handle compound primary key of more than 2 foreign keys. HABTM is only meant for 2

Re: Adding data in a One-To-Many Relationship

2008-05-01 Thread Reza Muhammad
That's right. It works now. Thank you :) On May 1, 2008, at 8:25 AM, validkeys wrote: > > if you hadn't figured this one out. > > If you are trying to access your models model from your parts model to > create a drop down of models in a parts view, use the following: > > latest 1.2: $this->Par