Re: Putting a component in a subdirectory?

2010-06-23 Thread ralph.marchil...@gmail.com
I think additional class paths are what you're looking for: http://book.cakephp.org/view/36/Additional-Class-Paths You can organized it practically any way that you want as long as your webserver process has read access to that location and you have the additional class path specified. Referencin

Putting a component in a subdirectory?

2010-06-23 Thread Rick Dane
I've been searching around about this and can't find an answer... can I put a component in a subdirectory (within the components director)? I want to do this to keep things more organized as I am going to have a lot of components in my cakephp app... if so, how do I reference it, or would it be the

Auth Question For Webroot App

2010-06-23 Thread bradmaxs
Hi Everybody, I am using the Auth component for a simple site. No ACL required. I have installed WordPress for the blogging and want to restrict users who are not signed in. I have WP installed in webroot. I thought maybe this would work but no avail. in app-controller.php if (isset($this->pa

Order of merged paths in App::build (bootstrapping in 1.3)

2010-06-23 Thread Corie
>From the API: App::build -- Build path references. Merges the supplied $paths with the base paths and the default core paths. How can I change the order in which the paths are merged, and thus called? In 1.2 I used bootstrapping to share controllers, models, views, etc. across multiple applicati

Re: Error I can't understand when trying to access specific field from array retrieved by query

2010-06-23 Thread Flavia Missi
Hi! Try to debug the $query_result variable and tell us what it returns. You can use the debug function: debug($query_result); just put this in your controller... =] 2010/6/23 Rick Dane > I'm having some problems using the standard cakephp myql queries with > some of my fields and I don't hav

Unexpected switch from Edit to Add Form and Problems with validation

2010-06-23 Thread Sarah
Hi, I'm having a problem I really can't even begin to explain; I'd appreciate any tips you could give. I have a form to edit a user's information. For one the validation does not seem to be working correctly. If I enter "Sarah" as a first name (should validate and save) the form reappears with

CakePHP developer required ASAP

2010-06-23 Thread Mind.M
Hello I am urgently looking for CakePHP developer for an extra pair of hands to help with a learning management system. There are functional specification and wireframes, but I am happy to provide even more details as we have already made a decent progress. I need to start the person ASAP, fee

Error I can't understand when trying to access specific field from array retrieved by query

2010-06-23 Thread Rick Dane
I'm having some problems using the standard cakephp myql queries with some of my fields and I don't have the time to troubleshoot this so I'm just trying to use standard mysql queries, using cakephp's query call... I'm calling my query (which I already set) with a code like this: $result11 = $thi

Breadcrumbs

2010-06-23 Thread Leszek Stachowski
Hi, is there any specific reason why HtmlHelper::getCrumbs() does not generate semantically correct list of links? I mean: (...) (...) If there isn't, I can contribute to cakephp and change it. Greetings, Leszek Stachowski Check out the new CakePHP Questions site http://cakeqs.org an

multiple pagination per page in ajax

2010-06-23 Thread NickPick
Is it possible in CakePHP to have multiple pagination in ajax on one page? If so, how? Cake uses the $paginator to hold pagination content. so this is why multiple ones are not possible, since there is only one paginator variable. How can I solve this? thanks Check out the new CakePHP Questions s

Re: how to disable query caching?

2010-06-23 Thread Dmitry Shevchenko
Thank you AD7six and alagar I will try your solutions 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

Re: Problems with AppController inheritance

2010-06-23 Thread bmcelhany
That's my assumption too since the code works fine in one environment but not in the other. Any ideas as to what settings I should be looking for (in php.ini, httpd.conf, etc)? I'm really not an Apache guy, so I'm not sure where to focus here. Thanks! On Jun 23, 10:09 am, rtconner wrote: > I woul

Re: Data validtation

2010-06-23 Thread Jeremy Burns | Class Outfit
I notice a couple of things. Surely you model name should be InviteApply (note the capital i)? When you check if ($this->inviteApply-validates()) you will only get true or false. In fact, you don't need to check if it validates as that is part of the save function. Try this instead: if (! $this

Re: Problems with AppController inheritance

2010-06-23 Thread rtconner
Also, make sure the database is setup correctly and you have the correct database.php file in the config folder. 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 Gro

Data validtation

2010-06-23 Thread Amit Kumar
Hi! I am new to cakePHP, and have been trying to develop an application with it. While using cakePHP i created a model with these validation rules... var $validate = array( 'name' => array( 'rule'=>array('minLength', 1), 'message'=>'Name is required' ), 'ema

Re: Problems with AppController inheritance

2010-06-23 Thread rtconner
I would highly doubt this is a problem with the code. More likely it's some server setting. Check your php.ini make sure its correct, and also make sure apache settings are configured correctly. Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related

Looking for a CakePHP developer for a full time telecommute position (US only)

2010-06-23 Thread alan
http://docs.google.com/View?id=dfw8qvgc_58dn9dpbdv Job Description – Core PHP Developer and IT Administration (CakePHP) We are interested in hiring another developer/IT support person. This person would join our team of 3 developers and we support a company of over 20 people with several major ap

Re: Possible bug in Tree, recover

2010-06-23 Thread cricket
On Wed, Jun 23, 2010 at 4:12 AM, AD7six wrote: > > > On Jun 23, 9:38 am, Erik Starck wrote: >> On Tue, Jun 22, 2010 at 6:56 PM, cricket wrote: >> > Interesting. You should post a ticket here: >> >> >http://cakephp.lighthouseapp.com/dashboard >> >> Ok, I added >> it:http://cakephp.lighthouseapp.

Problems with AppController inheritance

2010-06-23 Thread bmcelhany
Hi All, I'm running into a problem where my controllers don't seem to be inheriting from my AppController on my production server. I've put all of my authentication related code in my AppController and the child controllers just aren't recognizing it. The strange thing is that it works perfectly o

Re: ACL + allow question..

2010-06-23 Thread Sam
As far as I know, Cake's ACL only has to do with controllers and actions... nothing at all to do with models. Do you have your ARO and ACO trees set up properly? Is "controllers" set as your root node? On Jun 23, 7:07 am, nils wrote: > Got a bit further now: it looks as if it's due to used elemen

Re: updating record

2010-06-23 Thread mirfan
I think the problem is due to associated tables as when i read the record and update the fileds with new records then it is working properly, but it is strange again, why i am using cakephp? is there any short way in cake that i only save record of a few fields without experiencing the associated y

Re: ACL + allow question..

2010-06-23 Thread nils
Got a bit further now: it looks as if it's due to used elements (and controllers referenced in them) that I have to allow so many controllers.. Still: where does it start, where does it stop? I use an element that's referencing a controller/action. Now it *should* be enough to open up (just) that

Re: Authentication in cake!

2010-06-23 Thread Abraham Boray
I expect Admin to have full access, That's easy as a peace of cake (by default) BUT 4 the user I would like to allow him just command/index & command/ add actions 4 example !! Got it, I think I have to write some logic or so in the login action !!! Enjoy , AB On 17 juin, 17:19, John Andersen

Re: updating record

2010-06-23 Thread Master Ram...!
Send your post id here. i will work function update($id = 0) { if ( $_POST['a'] == "Save") { $this->Promoter->id = $_POST['data']['Promoter']['promoter_id'];// this is imp step. $this->Promoter->save($this->data); $this->redirect(array('controller'=>'promoters'

Re: updating record

2010-06-23 Thread mirfan
this array i ma getting and not able to save Array ( [Campaign] => Array ( [id] => 1 [name] => xcxcxz updated [average_users] => 6 [url] => http://abc.com ) ) On Jun 23, 3:09 pm, mirfan wrote: > yah i have the id hidden f

Re: updating record

2010-06-23 Thread mirfan
this array i ma getting and not able to save Array ( [Campaign] => Array ( [id] => 1 [name] => xcxcxz updated [average_users] => 6 [url] => http://abc.com ) ) On Jun 23, 3:09 pm, mirfan wrote: > yah i have the id hidden f

Re: updating record

2010-06-23 Thread mirfan
yah i have the id hidden field but not working On Jun 23, 2:14 pm, "Master Ram...!" wrote: > Hi, first u have to get the ID. and related fields using hidden format. > > you can refer this example. > > controller: > > function edit($id = null) { >    if (!$id) { >       $this->Session->setFlash('I

Re: Auth variables being ignored

2010-06-23 Thread Jeremy Burns | Class Outfit
I was making a stupid mistake. For the record, I was calling parent::beforeFilter(), which was overriding my values. Jeremy Burns Class Outfit jeremybu...@classoutfit.com http://www.classoutfit.com On 23 Jun 2010, at 08:55, Jeremy Burns wrote: > I have a site built on 1.3.2 with the following

Re: CakePHP 1.3 reverse routing in pagination

2010-06-23 Thread Alberto
I finally solved it, for those interested in knowing the solution, this is how I did it. routes.php Router::connect('/usuarios/:id/:action/*', array('controller' => 'usuarios','action' => ':action'),array('id'=>'[0-9]+')); view $url = array('url'=>array('controller' => 'usuarios','id' => $

Session and/or Cookie Problems

2010-06-23 Thread Taff
I upgraded my project to run on 1.3 and I seemed to have everything working. I recently added a new controller and model. For some reason though, I cannot access cookie or session stuff in that controller. I am defining all components globally in my app_controller and it looks like this: App::impo

Re: single find query involving HABTM and hasOne

2010-06-23 Thread jason001
OOoh! ok will try this :-) thanks again for your help! -- View this message in context: http://old.nabble.com/single-find-query-involving-HABTM-and-hasOne-tp28940627p28969482.html Sent from the CakePHP mailing list archive at Nabble.com. Check out the new CakePHP Questions site http://cake

Re: updating record

2010-06-23 Thread Master Ram...!
Hi, first u have to get the ID. and related fields using hidden format. you can refer this example. controller: function edit($id = null) { if (!$id) { $this->Session->setFlash('Invalid id'); $this->redirect(array('action'=>'index'), null, true); } if (empty($this->data)) {

updating record

2010-06-23 Thread mirfan
Hi guys, Again getting a problem as i am new to cake, I have a table having 10 fields, now i want to update three of them but cake did not allow me to do so table structure campaigns id name users url type category logo | and so on now i just want to update users and url my for

Re: birthday validate

2010-06-23 Thread jerry
Thanks Jeremy that's exactly what i wanted to do i mean check wether the user has entered a date greater than the current day ,month through validation but i did fail.Am more of a newbie in programing. On Jun 23, 11:17 am, Jeremy Burns | Class Outfit wrote: > That's going to be hard really. First

Re: Recursive find but not in all models

2010-06-23 Thread Jeremy Burns | Class Outfit
http://book.cakephp.org/view/1323/Containable Jeremy Burns Class Outfit jeremybu...@classoutfit.com http://www.classoutfit.com On 23 Jun 2010, at 05:12, cdvrooman wrote: > Fernando, > > you should use $this->User->unbindModel(array( >'belongsTo' => array('Company'), >'hasMany' => arra

Re: Recursive find but not in all models

2010-06-23 Thread cdvrooman
Fernando, you should use $this->User->unbindModel(array( 'belongsTo' => array('Company'), 'hasMany' => array('Table1', 'Table2', 'Table3'), 'hasAndBelongsToMany => array('Table4', 'Table5') )); before performing your query. Try unbinding all of the unwanted models associated with

Re: Cant edit records with primary is varchar (32)

2010-06-23 Thread a...@hard-soft.at
I got it, it was a little piece of code in my app_model, i have a init method where in which i transport session data to every model function init ($user_ID, $mandant_ID, $use_contactpool = 0) { $this->user = $user_ID; $this->mandant = $mandant_ID; }

Re: Cant edit records with primary is varchar (32)

2010-06-23 Thread a...@hard-soft.at
Meanwhile iam a bit further in finding the mistake When i do a echo $column; in the model method (http://github.com/ cakephp/cakephp/blob/master/cake/libs/model/model.php) i geht the following: Mandant.mandant_id modified dvr_nummer modified mandant.mandant_id The last entry is the bad entry beca

Re: birthday validate

2010-06-23 Thread Jeremy Burns | Class Outfit
That's going to be hard really. First I'd adapt the code sample (change maxYear to date('Y') which will give you this year and the previous 100 (which is probably enough for most people). If you limit the months to (say) June, how would I enter my birthday which is in a previous year but in July

The best way to quick login from front page and Auth issue

2010-06-23 Thread kondrat
Dear friends, I'm trying to set up the quick login form in my app on a front page (like on twitter). My problem is: I'm using Security component and Auth (of course). Since I'm logging not from myapp/users/ login page I'm black-holed (404). The only way I've found so far is : $this->Security->vali

Re: Possible bug in Tree, recover

2010-06-23 Thread AD7six
On Jun 23, 9:38 am, Erik Starck wrote: > On Tue, Jun 22, 2010 at 6:56 PM, cricket wrote: > > Interesting. You should post a ticket here: > > >http://cakephp.lighthouseapp.com/dashboard > > Ok, I added > it:http://cakephp.lighthouseapp.com/projects/42648-cakephp/tickets/848-s... > > Erik S.http

Re: birthday validate

2010-06-23 Thread jerry
Thanks for that response but that's not what i was looking for,what i need is for the form to only display previous month up to the current one.Am trying to not let users be able to enter a birthday that is not greater than the current day or month On Jun 23, 10:35 am, Jeremy Burns | Class Outfit

Re: how to disable query caching?

2010-06-23 Thread alagar
Sorry for my English. You can do this before executing query, in your model; $db =& ConnectionManager::getDataSource($this->useDbConfig); $db->_queryCache = array(); $this->model->query(); But this will clear all cached queries On Jun 22, 5:21 pm, Dmitry Shevchenko wrote: > Hi ! > Is there any wa

Auth variables being ignored

2010-06-23 Thread Jeremy Burns
I have a site built on 1.3.2 with the following app_controller.php file: class AppController extends Controller { var $components = array('Auth', 'Session'); var $helpers = array('Html', 'Form', 'Session', 'Text'); function beforeF

Re: Possible bug in Tree, recover

2010-06-23 Thread Erik Starck
On Tue, Jun 22, 2010 at 6:56 PM, cricket wrote: > Interesting. You should post a ticket here: > > http://cakephp.lighthouseapp.com/dashboard Ok, I added it: http://cakephp.lighthouseapp.com/projects/42648-cakephp/tickets/848-save-bug-in-treebehaviorrecover Erik S. http://twitter.com/erikstarck

Re: how to disable query caching?

2010-06-23 Thread AD7six
On Jun 23, 2:49 am, Dmitry Shevchenko wrote: > Hi > I have turned on debug and saw that query is called only one time. > So  when I have tried to call it many times in a loop - it was run > only in a first call, and for other calls it returned a cached values. > > Thank you. $this->query('some

Re: birthday validate

2010-06-23 Thread Jeremy Burns | Class Outfit
Do you mean in the form? If so, yes. For example, this code will give you a date field (without time) where the year is the the range [this year -100] and [this year -18]: $form->input( 'dob', array( 'type' => 'datetime', 'empty' => true,

Re: birthday validate

2010-06-23 Thread jerry
Is there a way to limit months just like maxYear or minYear? this would be a lot more easier. On Jun 22, 2:28 pm, Jeremy Burns | Class Outfit wrote: > Sorry - just read the post properly and my answer wasn't your solution, but > it can be adapted. The key is to write a function and within that c

Re: ACL + allow question..

2010-06-23 Thread nils
Hm, no takers? Ok, I now included *all* controllers with the other user-groups, and that works all right. But that can't be it, really, can it? What's the rule re what to allow here? - If I do a simple find (eg. $this->User->Country->find('list');), do I have to include the country controller in