ACL in helper

2013-01-10 Thread Jeremy Burns
I have a Navigation plugin that contains a helper. It's used for creating menus dynamically. I want to check a user's permissions via ACL before adding a menu item. How can I user the ACL component inside the plugin? -- Like Us on FaceBook https://www.facebook.com/CakePHP Find us on Twitter htt

Re: Mongo php process slowness

2013-01-10 Thread mulianto
hi have you try insert the record in 1 call like batch/bulk insert. i don't know if mongo can do this. Sent from my iPhone On 10 Jan 2013, at 16:16, Raju Bishnoi wrote: > Hi, > > I run the below php code with Mongo & MongoClient to insert 100k records. > Mongo took 70-75 second to complet

Re: Creating objects from the parent object of a hasmany relationship in a controller

2013-01-10 Thread polutan
Just pass your POST request http://davidwalsh.name/curl-post 2013/1/11 Sam Marland > I am creating a web application that stores user's journeys and I'm build > this application in CakePHP 2.2.5. > > I have a Journey model and that journey model has many coordinate objects > which store the lat

Authenticating in different controllers

2013-01-10 Thread CCorreia
I have 2 controllers that require authentication, let's say: - admins - users Each of this controllers requires a specific table for login information, so far I can use the Auth component to login correctly to each controller the issue I'm having is that once the user does the login into one o

Creating objects from the parent object of a hasmany relationship in a controller

2013-01-10 Thread Sam Marland
I am creating a web application that stores user's journeys and I'm build this application in CakePHP 2.2.5. I have a Journey model and that journey model has many coordinate objects which store the lat long coordinates. I want to create a REST API to create journeys that accepts JSON in the

Extending Plugin Question - location of new controllers/models/views

2013-01-10 Thread mk
Hi I’m using the cakedc users plugin in my app and have it working well. I’d like to extend it now and I have read through the readme “How to extend the plugin” https://github.com/CakeDC/users#how-to-extend-the-plugin, where they give example controller called AppUsersController and model c

Re: jquery validation helper not working in 2.2.4

2013-01-10 Thread Matt
Hi, That's a helper I created a while back and it will work on 2.2.4, although you might want to get the latest version from GitHub https://github.com/vz28bh/CakePHP-JqueryValidationHelper In that version I recommend opening the form like below, just to make things a little cleaner. JqueryVal

Re: Cake PHP doesn't work on Mac but on Windows

2013-01-10 Thread Jonathan Sundquist
What are your error logs telling you? There could be a number of issues causing the problem. On Thu, Jan 10, 2013 at 7:29 AM, Theresia Z wrote: > I have a big problem with Cakephp. We installed it and built an > application on windows, everything worked fine. Then I installed Cakephp on > two

Mongo php process slowness

2013-01-10 Thread Raju Bishnoi
Hi, I run the below php code with Mongo & MongoClient to insert 100k records. Mongo took 70-75 second to complete and MongoClient took 440-450 second. $start = microtime(true); $objBaseMongoRecord = new BaseMongoRecord(); $objBaseMongoRecord-> setCollectionName("mongotest"); $i = 0; while ($i

How Can I use different AppController with specific route prefix!?

2013-01-10 Thread Khaled Attia
Hello, I'm going to create API provider for my application, and I don't want to split the API from the main app because there is a lot of tables relations in models and components and other stuff that I want to use with the API, In same time I don't want to use the main AppController because th

Cake PHP doesn't work on Mac but on Windows

2013-01-10 Thread Theresia Z
I have a big problem with Cakephp. We installed it and built an application on windows, everything worked fine. Then I installed Cakephp on two other windows-computers and copy-pasted the app-Data, it worked. Now I tried the same thing on Mac and it wont work. The CakePHP installation works,

Help with sub domains and dynamic paths

2013-01-10 Thread Neil Berrow
I really hope someone could help. It's been driving me crazy for 2 days, I've tried so many configurations to get my app working. I moved it from 1 domain to another, and although it renders the 1 page it doesn't login or go to sign up like it used to. I have: mod_rewrite on Wildcard installed

Re: viewing PDF

2013-01-10 Thread euromark
You forgot the RequestHandler component, didnt you? Am Donnerstag, 10. Januar 2013 17:19:15 UTC+1 schrieb Dr. Drijk: > > I'm using the CakePdf-plugin to parse a view as pdf. > > I added to \app\config\bootstrap.php : > CakePlugin::load('CakePdf', array('bootstrap' => true, 'routes' => true)); >

viewing PDF

2013-01-10 Thread Dr. Drijk
I'm using the CakePdf-plugin to parse a view as pdf. I added to \app\config\bootstrap.php : CakePlugin::load('CakePdf', array('bootstrap' => true, 'routes' => true)); Configure::write('CakePdf', array( 'engine' => 'CakePdf.WkHtmlToPdf', 'margin' => array( 'bottom' =

Issue with removing records (unset) from data array in afterFind

2013-01-10 Thread Kevin
Hi All I'm experiencing a problem that I can't unset records from the data[] in the afterFind callback when the model a related model. To show my issue clearly I've add this aferFind function to a model (assume I'd like to filter all returned records out for some reason): public function afterF

CakeDC Comments & Users plugins together - issues?

2013-01-10 Thread designv...@gmail.com
I am running 2.1 and trying to use the CakeDC Users plugin alongside their Comments plugin but am running into an issue... *Error: * Call to a member function user() on a non-object > *File: > *C:\wamp\www\xxx\Plugin\Comments\Controller\Component\CommentsComponent.php > *Line: * 239 > I can

Best practice for naming ACOs in Cake?

2013-01-10 Thread LDSign
Hi Ive implemented a complete ACL-Solution in my app. I am using an administration form for acl-management (allow/deny) which I am building directly "on-the-fly" (from the aco-table). So now, I would like to make this "acl-form" accessible to some groups with non-technical knowledge. Of course