Hi Andy,

so in conclusion, i should get into the habit of installing these cake
files as plugins.

Thank you.

I didn't try your one_query cause i tried reading it but i dont quite
understand how to use it.

Hope you dont mind.

however, you have been the most helpful to me so far in pointing me
the way.

Thank you.



On May 5, 3:58 am, AD7six <andydawso...@gmail.com> wrote:
> On May 4, 7:19 pm, Kei Simone <kimc...@gmail.com> wrote:
>
>
>
>
>
> > Hi Andy,
>
> > i got it to work using Linkable. as well as you suggested by using
> > bindModel which is slightly more readble than joins.
>
> > though i think linkable is really darn short and it looks good.
>
> > I am sorry, i apologise that i misunderstood.
>
> > I thought both the linkable and the onequery are the same. and i
> > thought you wrote both linkable and onequery.
>
> > i got a few questions for clarification purposes. please help to
> > clarify.
>
> > 1) i initially placed the linkable directly in app/models/behaviors/
> > linkable.php
>
> > having recalled my meio_upload, i realised that the behavior file was
> > actually stored at plugins/meio_upload/models/behaviors/
> > meio_upload.php.
>
> > so i did the same for linkable and called the file using $this-
>
> > >Behaviors->attach(Linkable.Linkable);
>
> > so i should place such code in plugins ALWAYS?
>
> I'd suggest: If it's distributed as a plugin yes otherwise: no. Plugin
> models and controllers extend a different class (PluginApp(Controller|
> Model)) which might mean if you follow your rule you come unstuck at
> some point although a behavior doesn't know if it's in a plugin or not
> so in this instance you can choose.
>
>
>
> > 2) your onequery is doing the same thing as Linkable yes?
>
> Yes - more or less. I didn't know of linkable when I wrote it.
>
> as in
>
> > optimizing the query. so to use it i need only placed it in plugins/mi/
> > models/behaviors/one_query.php
>
> kind of
>
>
>
> > do i need the other mi files?
>
> I don't think so but mi is a plugin - I'd suggest getting into the
> habit of installing plugins (cd plugins && git clone git://.....) -
> not individual files.
>
> If you choose to use it (attach it and just replace contain in your
> find call with oneQuery, OR attach it and tell the behavior to look
> for the param "contain") and it complains, then it does ;)
> hth,
>
> AD
>
> Check out the new CakePHP Questions sitehttp://cakeqs.organd help others with 
> their CakePHP related questions.
>
> 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
> cake-php+unsubscr...@googlegroups.com For more options, visit this group 
> athttp://groups.google.com/group/cake-php?hl=en

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

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
cake-php+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en

Reply via email to