Re: Vacancy for a CakePHP developer in London (Farringdon)

2016-04-08 Thread Jeremy Burns : Class Outfit
Thank you, but Delhi is a long commute. I don’t think that will work. This is an on site position. > On 8 Apr 2016, at 08:18, Kamal Deol wrote: > > > > On Fri, Apr 8, 2016 at 8:31 AM, Jeremy Burns <mailto:jeremybu...@classoutfit.com>> wrote: > An old client of

Vacancy for a CakePHP developer in London (Farringdon)

2016-04-07 Thread Jeremy Burns
An old client of mine is looking someone to take over and develop some code I built for them a year or so ago (CakePHP 2.6). They are only small, so it'd be more of a junior than a senior role (they might consider contract). The business is small but successful and is mainly based in Swindon, b

Re: Dealing with MASSIVE Model Files

2015-09-09 Thread Jeremy Burns : Class Outfit
I sometimes splice chunks out into behaviours for this reason. > On 9 Sep 2015, at 08:35, Michael Houghton wrote: > > I have some big projects in CakePHP and always follow the Fat Models, Skinny > Controllers approach. > > The issue I have now, is some of my model files are 5000 lines! > > Is

Re: CakePHP 3 Component

2015-07-18 Thread Jeremy Burns : Class Outfit
015 11:08:21 UTC+2 schrieb Jeremy Burns: > What about the situation where you have a multi-step process inside a model/s > and you want to make the progress status available to javascript calls? > >> On 17 Jul 2015, at 09:55, euromark > wrote: >> >> Your models should sta

Re: CakePHP 3 Component

2015-07-17 Thread Jeremy Burns : Class Outfit
What about the situation where you have a multi-step process inside a model/s and you want to make the progress status available to javascript calls? > On 17 Jul 2015, at 09:55, euromark wrote: > > Your models should stay stateless, as such you should never internally use > the session. > Inst

Re: AWS, Centos 7 and file caching

2015-05-24 Thread Jeremy Burns
Nope. We rebuilt the box with another version of Linux. > On 25 May 2015, at 04:15, HL wrote: > > I met the same error. Did you fixed it? Thanks > > -- > Like Us on FaceBook https://www.facebook.com/CakePHP > > Find us on Twitter http://twitter.com/CakePHP <

Re: Saving test results

2015-03-17 Thread Jeremy Burns
rce of the duplicate $this->TestQuoteSource->setDatasource('default'); // At the point I want to save back to the source table: $this->TestQuoteSource->id = $testQuote['TestQuote']['id']; $this->TestQuoteSource->saveField('actual_price', $actualPrice

Saving test results

2015-03-17 Thread Jeremy Burns
I have a fixture: public $import = array('model' => 'TestQuote', 'records' => true); ...which, as you'd expect, creates a table in my test database and imports the records. My test case iterates over the rows and runs a test quote for each row, comparing an expected price with a returned price.

Wordpress

2014-12-14 Thread Jeremy Burns
So I'm two and a half months into a project replacing an e-commerce site with a custom built CakePHP site. The current site starts in Wordpress (LAMP) and flips to a horribly written PHP site (WAMP) with all sorts of reverse proxies and stuff going on. The client has now decided they want to re

Re: The (bad) perception and image of CakePHP in the public

2014-10-01 Thread Jeremy Burns : Class Outfit
er or something related, so it doesn't always make sense. - Jeremy On 1 Oct 2014, at 19:56, mark_story wrote: > As someone who writes a pile of documentation, what kinds of advanced things > have you found lacking? I've found it challenging to add more advanced > examples as

Re: The (bad) perception and image of CakePHP in the public

2014-09-30 Thread Jeremy Burns : Class Outfit
My reasons are more practical than technical, but still very relevant: 1. Familiarity 2. Speed to get-go 3. Well maintained/supported Without deep knowledge of other frameworks it's hard to come up with technical arguments, but I'd love have them in my armoury. - Jeremy On 30 Sep 2

Re: Warning (512): cake_model cache was unable to write

2014-09-29 Thread Jeremy Burns
I had a similar issue when running MAMP locally. I fixed it by turning off MAMP's internal caching. Not sure if that's the same issue you're facing. On 30 Sep 2014, at 01:12, Andras Kende wrote: > Try deleting the files within app/tmp folders. > > and adding 'mask' => 0777 to > core.php > Cac

Re: The (bad) perception and image of CakePHP in the public

2014-09-29 Thread Jeremy Burns : Class Outfit
This is so true. I'm a huge fan of Cake but we do feel like the whipping boys sometimes. I recently hired someone into a project and the first thing he tried to do was change the framework for a whole bunch of vague reasons like 'Laravel is just so much better'. Perhaps someone can devise some

Re: Angular/Polymer web components and CakePHP

2014-09-22 Thread Jeremy Burns
gt; > Just my 2c > > T > > On Mon, Sep 22, 2014 at 2:27 PM, Jeremy Burns > wrote: > Canvassing some opinion... > > I'm just about to start a project that has an Angular and/or Polymer web > components front end, so the API only ever needs to send JSON respons

Angular/Polymer web components and CakePHP

2014-09-22 Thread Jeremy Burns
Canvassing some opinion... I'm just about to start a project that has an Angular and/or Polymer web components front end, so the API only ever needs to send JSON responses and receive normal posts/get requests. As such, there is no need for the 'V' part of an MVC framework. I know CakePHP can d

Re: 'In test' global variable?

2014-09-17 Thread Jeremy Burns : Class Outfit
I changed tack again as ajax requests (or requests that expect a json response) are setting debug to 0 in AppController. Instead, I Configure::write('in_test', true) in the setup of each test case, and check it in the main code. it works. On 17 Sep 2014, at 05:30, Jeremy Burns wrote:

Re: 'In test' global variable?

2014-09-16 Thread Jeremy Burns
ailConfig = (Configure::read('debug') > 0) ? 'database' : 'default' > Configure::write('Email.config', $emailConfig); > > //.. somewhere else > > $email = new CakeEmail(); > $email->config(Configure::read('Email.config'));

Re: 'In test' global variable?

2014-09-16 Thread Jeremy Burns : Class Outfit
Configure keys for my EmailLib (extends CakeEmail): > > Don't send emails without Configure::write('Email.live'), but log them away > verbosely. For testing. > Basically, you will have to add something like this on your own I am afraid > > mark > > > Am D

'In test' global variable?

2014-09-16 Thread Jeremy Burns
My model code sends out emails, so when I run my test suite the system triggers multiple emails - which is potentially bad for spam ratings. Is there a global variable I can check so that when 'in test' the messages aren't triggered? -- Like Us on FaceBook https://www.facebook.com/CakePHP Find

Re: problems while upgrading from cakephp 1.2.5 to 2.5.3

2014-08-24 Thread Jeremy Burns : Class Outfit
You'll need to add a beforeFilter function (you'll find yourself using this a lot in the future): http://book.cakephp.org/2.0/en/controllers.html On 23 Aug 2014, at 22:16, 'Dallas' via CakePHP wrote: > Hello again Jeremy, > Can you explain? I do not see beforeFilte

Re: Security salt issue

2014-08-22 Thread Jeremy Burns : Class Outfit
I'd use the value from your old installation as it is used to encrypt passwords - if the salt is different no one will be able to log in as the encrypted version of the password they enter will not match the encrypted value stored in the database. On 23 Aug 2014, at 03:25, 'Dallas' via CakePHP

Re: problems while upgrading from cakephp 1.2.5 to 2.5.3

2014-08-22 Thread Jeremy Burns : Class Outfit
The $this statements need to sit inside a function - probably beforeFilter in your case. On 23 Aug 2014, at 03:03, 'Dallas' via CakePHP wrote: > I have migrated from cakephp 1.2.5 to Cake 2.5.3 by installing new cake, > importing old database and importing files. I have made changes to file

Re: Advice on MVC pattern for stats site

2014-08-05 Thread Jeremy Burns : Class Outfit
I'd make them either separate controller actions or a single action that accepts a parameter and then tidy them up with a route. The controller function can then either render the view associated with the action(s), specify a view to render and/or specify a layout. On 5 Aug 2014, at 20:08, Rus

Testing fixtures

2014-08-02 Thread Jeremy Burns
When I run my 'All models' test I can get different results than when I run each model individually, presumably because loaded fixtures have been updated in previous tests. How can I clear down previously loaded fixtures at the beginning of each test suite? -- Like Us on FaceBook https://www.f

Re: 403 error

2014-07-31 Thread Jeremy Burns : Class Outfit
Thanks Andy. Turns out it was something much simpler. I use MAMP Pro and had the cache module set to APC. As soon as I turned that off the issue went away. On 31 Jul 2014, at 06:52, AD7six wrote: > That sounds like a consequence of web requests and CLI requests sharing the > same tmp folder. E

Re: 403 error

2014-07-24 Thread Jeremy Burns
It seems as if the cache files are being written as read only. Anyone got any suggestions please? On Tuesday, 15 July 2014 16:35:48 UTC+1, Jeremy Burns wrote: > > I have a site that works fine most of the time, but on occasion I'll get > 403 errors for a page even if I have previo

403 error

2014-07-15 Thread Jeremy Burns
I have a site that works fine most of the time, but on occasion I'll get 403 errors for a page even if I have previously viewed it successfully, sometimes when I refresh a page. Sometimes clearing the cache resolves the issue but on others I need to restart the browser. Any clues what's happeni

Re: Cookbook: database query in controller???

2014-07-06 Thread Jeremy Burns : Class Outfit
It is using the model. It's calling the 'find' method of the Post model with the 'all' parameter. The Post model is then using the core Model functions to do the database extraction. On 6 Jul 2014, at 11:59, Sam Clauw wrote: > I've a question about the MVC in CakePHP. Normally, the model shoul

User being logged out from iOS on missing image

2014-07-04 Thread Jeremy Burns
We've had an error that took a while to trace, and whilst we've solved it I'd like to get a better understanding of what was happening behind the scenes. We're building an app that also acts as an API for an iOS app. Profile pictures are stored inside the /webroot/img folder, and the path to th

CakePHP Queue Plugin

2014-07-03 Thread Jeremy Burns
I just set up the CakePHP Queue plugin ( https://github.com/dereuromark/cakephp-queue) and it works great. I’m building a messaging app where messages and replies are distributed via web sockets. Before the plugin the model layer was emitting the messages after save, which introduced a delay for

Re: Grouping Api controllers in a seperate sub directory

2014-07-02 Thread Jeremy Burns : Class Outfit
It's simpler than that. Each controller function can act as an API method, so leave the folder structure as it is.You can detect the json extension by using the RequestHandler component and adding Router::setExtensions(array('json')); near the bottom of routes.php. Then you can call /controller

Re: CakePHP Login redirect

2014-06-30 Thread Jeremy Burns : Class Outfit
Are you certain the Auth->logout action is being called? Is the session clear (destroyed) after logout? On 28 Jun 2014, at 12:54, Gagik Navasardyan wrote: > Hi everyone. > > I have one question. > > I'm working on an application which is working in local network and acting as > POS(Point of

Re: cross tables in cake 1.3

2014-06-30 Thread Jeremy Burns : Class Outfit
That is A LOT of models to load and there is almost certainly a better way of cracking your nut. What are you trying to achieve? On 30 Jun 2014, at 08:33, 'Chris' via CakePHP wrote: > hi guys,.. I'm using to many cross tables in a controller,... and getting > memory error not enough bites,...

Re: Auth Component

2014-06-27 Thread Jeremy Burns : Class Outfit
What happens if, when you define $user, you also include (contain?) the Person and Company models and log in with that $user variable? On 27 Jun 2014, at 00:57, Matt Myers wrote: > I've been hitting my head over this for quite some time now. When I login > using the Auth Component as such: >

Re: Help me for First Application with CakePHP!

2014-06-25 Thread Jeremy Burns : Class Outfit
Sure. What would like us to build for you? On 25 Jun 2014, at 06:30, Sankar V wrote: > > > -- > Like Us on FaceBook https://www.facebook.com/CakePHP > Find us on Twitter http://twitter.com/CakePHP > > --- > You received this message because you are subscribed to the Google Groups > "CakePH

Testing components

2014-06-06 Thread Jeremy Burns
I have a component that is called from the UsersController and a few others. Code in the component calls a find on the User model via the controller: $user = $this->Controller->User->findById($userId); How do I set up a reference to the UsersController inside the component test case so I can c

Re: How to Integrate paymentgateway in cakephp

2014-06-06 Thread Jeremy Burns | Class Outfit
By reading and researching. Sent from my iPhone > On 6 Jun 2014, at 07:00, vinothku...@constient.com wrote: > > This message has no content. -- Like Us on FaceBook https://www.facebook.com/CakePHP Find us on Twitter http://twitter.com/CakePHP --- You received this message because you are sub

Re: display data 3 tables

2014-06-05 Thread Jeremy Burns : Class Outfit
You are not doing something right. Can you show more code with the debugged output please? Cracking this and understanding what is happening will help you enormously with developing Cake apps from here. On 5 Jun 2014, at 15:18, ajt wrote: > I set recursive to -1 and it doesnt work as I get us

Re: display data 3 tables

2014-06-05 Thread Jeremy Burns : Class Outfit
With the Containable behaviour you should set recursive to -1. Recursion makes the model automatically attache related models n deep (where n is your recursion level) so can give unexpected (or at least uncontrolled) results. When it is -1 it only returns the model associations you specify. The

Re: display data 3 tables

2014-06-05 Thread Jeremy Burns : Class Outfit
Isn't $tutor['Teacher']['User']['username'] what you're looking for? On 5 Jun 2014, at 14:18, ajt wrote: > There just is no user being displayed with the below, there is with Teacher > in the find if I add it but every field is undefined in the view. > > $this->Tutorsession->recursive = 2;

Re: display data 3 tables

2014-06-04 Thread Jeremy Burns : Class Outfit
You are referencing the $user variable when you have set a $tutor variable. Add this to your view so you can inspect the shape of the $tutor variable and work out how to access the key you are looking for: die(debug($tutor)); It'll probably look something like this: array( 'Tutorsessio

Re: display data 3 tables

2014-06-04 Thread Jeremy Burns : Class Outfit
A couple of things... Why find all when presumably there is only one expected teacher? The contain statement doesn't go inside an array: $this->set( 'tutor', $this->Tutorsession->find( 'first', array( 'conditions' => array('

Re: display data 3 tables

2014-06-04 Thread Jeremy Burns : Class Outfit
Look at the Containable behaviour: http://book.cakephp.org/2.0/en/core-libraries/behaviors/containable.html On 4 Jun 2014, at 14:47, ajt wrote: > Hi, > > I just want to display fields from 3 tables which I have checked on how to do > this and I am not clear on this. Examples I have found conc

Re: Site down after restart

2014-06-04 Thread Jeremy Burns : Class Outfit
I had a weird error once where the Config folder was renamed to config (lower case c) after uploading some updates via FTP. The site just blanked out. After searching and debugging for a few hours I went to the test page and it presented the error to me. Might be worth a try. On 4 Jun 2014, at

Re: How to get URL parameters in cakephp with URL that ends with xml?

2014-06-04 Thread Jeremy Burns : Class Outfit
Have a look at http://book.cakephp.org/2.0/en/development/routing.html#Router::parseExtensions On 4 Jun 2014, at 10:41, Sam wrote: > I would like to pass URL parameters in cakephp with URL that ends with xml > like below; > > http://localhost/cp251/controller/api_get_info?page=1.xml > The con

Re: cant find a field

2014-06-03 Thread Jeremy Burns : Class Outfit
I missed a single speech mark when I typed my example For clarity it should be: $teacherId = $this->Teacher->field('id', array('Teacher.user_id' => $currentUserId)); On 4 Jun 2014, at 06:46, Jeremy Burns : Class Outfit wrote: > The code you pasted probably

Re: cant find a field

2014-06-03 Thread Jeremy Burns : Class Outfit
The code you pasted probably won't work. $currentuserid=AuthComponent::user('id'); // Use $this->Auth->user('id') instead. In the find you are using the user_id field as a condition but only returning the Teacher.id field - do the Teacher.id and Teacher.user_id fields contain the same value?

Re: cant find a field

2014-06-03 Thread Jeremy Burns : Class Outfit
You ask a lot of questions that are in the book... Look at Model-> field() : http://book.cakephp.org/2.0/en/models/retrieving-your-data.html#model-field On 3 Jun 2014, at 15:38, ajt wrote: > Hi, Is this is the correct way to find a 1 field in 1 row of data? > I just want the teacherID of a r

Re: button wont display as it should

2014-06-03 Thread Jeremy Burns : Class Outfit
Generally speaking you'd create your own CSS file and place it in /app/webroot/css and use that instead of the default Cake CSS. If you want to use both then call both in the head of your layout page. On 3 Jun 2014, at 12:48, jagguy wrote: > Hi, > > No I havent touched the css but where do I

Re: button wont display as it should

2014-06-02 Thread Jeremy Burns : Class Outfit
Then just use CSS. On 2 Jun 2014, at 15:01, jagguy wrote: > Form buttons should not be used as simple links, so this cant be the solution > > http://stackoverflow.com/questions/13491421/cakephp-create-simple-buttons-that-redirects-to-views > > > P: (03) 9866 7737 > E: i...@itfutures.edu.au >

Re: button wont display as it should

2014-06-02 Thread Jeremy Burns : Class Outfit
Use $this->Form->button... On 2 Jun 2014, at 14:37, jagguy wrote: > Hi, > > I simply want to display a button instead of a link but the button doesnt > appear as I cant override the link display with htmlHelper > In older versions of cake 2.x this does work. > > echo "" .$this->Html->link

Re: Order using Containable-Behaviour on deeper levels (>1)

2014-05-29 Thread Jeremy Burns : Class Outfit
ot;firstname" > > Or do I miss something? > > Frank > > Am Donnerstag, 29. Mai 2014 12:41:00 UTC+2 schrieb Jeremy Burns: > Look at Hash::sort - > http://book.cakephp.org/2.0/en/core-utility-libraries/hash.html#Hash::sort > > On 29 May 2014, at 11:28, LDSign

Re: Order using Containable-Behaviour on deeper levels (>1)

2014-05-29 Thread Jeremy Burns
Look at Hash::sort - http://book.cakephp.org/2.0/en/core-utility-libraries/hash.html#Hash::sort On 29 May 2014, at 11:28, LDSign wrote: > Hi > > This was discussed several times on the inet - it seems that it is not > possible to use an "orde"r on a deeper association connected with the > co

Re: cant edit but can add row cakephp

2014-05-28 Thread Jeremy Burns : Class Outfit
What happens when you try the save? Does it create a new row instead or does it fail somewhere? On 28 May 2014, at 15:10, jagguy wrote: > Hi, > > In cakephp I cant edit a row from my mysql db but I can add a new row on the > same table without error. > Not sure what to do or how to debug thi

Re: Access $this->Session from a model

2014-05-28 Thread Jeremy Burns : Class Outfit
Pass the current user's id to the model from the calling controller, which can reference the session. On 28 May 2014, at 09:23, Thomas von Hassel wrote: > If your model depends on knowing, by it self, who the user is, you are doing > it wrong .. > > /thomas > > > On 27 May 2014, at 20:59, H

Re: adding a new record with foreign key option

2014-05-25 Thread Jeremy Burns | Class Outfit
Try looking at find->list )http://book.cakephp.org/2.0/en/models/retrieving-your-data.html#find-list). It'll return a key => value array where key is the value you want to store (teacher_id or student_id) and value is the name of the teacher or student that will be displayed in the drop down. C

Re: filter data with controller or model?

2014-05-23 Thread Jeremy Burns | Class Outfit
As a general rule, let the model do all the heavy lifting (fat models, thin controllers). It keeps the business logic in one place. What you have described below are two different things. The first is a find command called by the controller. The second is the code that associates this model with

saveAssociated and $this->id

2014-05-19 Thread Jeremy Burns
I have a Message model that hasMany MessageRecipients. I have a form that posts data into a controller which passes it straight to a method in the Message model. Three questions really... 1) How should the form be set up? The MessageRecipient model expects two fields; message_id and user_id. Wh

Re: How to retrieve data from anther table in one model

2014-04-30 Thread Jeremy Burns | Class Outfit
> --- > You received this message because you are subscribed to the Google Groups > "CakePHP" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to cake-php+unsubscr...@googlegroups.com. > To post to this group, send email to c

json extensions and redirects

2014-04-23 Thread Jeremy Burns
Our iOS app now calls json extensions, which is great. But, if the app does an internal redirect it loses the json extension and renders full html instead of json. What is the best approach to keep the json extension throughout the request lifecycle? -- Like Us on FaceBook https://www.faceboo

Re: Mobile safari shows blank page

2014-04-20 Thread Jeremy Burns
Parse json extensions; that's the answer. On Sunday, 20 April 2014 05:45:07 UTC+1, Jeremy Burns wrote: > > So I guess my next question is: "What is the best way to determine if a > request is coming from an iOS device (or Android etc) rather than a mobile > browser so

Re: Mobile safari shows blank page

2014-04-19 Thread Jeremy Burns
So I guess my next question is: "What is the best way to determine if a request is coming from an iOS device (or Android etc) rather than a mobile browser so that I can return JSON data instead of rendered HTML? On Sunday, 20 April 2014 05:39:26 UTC+1, Jeremy Burns wrote: > > I ha

Re: Mobile safari shows blank page

2014-04-19 Thread Jeremy Burns
web app can get the JSON output it expects. It seems that isMobile is returning true even when viewed from mobile safari. On Saturday, 19 April 2014 08:20:22 UTC+1, Jeremy Burns wrote: > > I have a site (test.nudgedeck.com) that renders as expected in web > browsers. But when

Mobile safari shows blank page

2014-04-19 Thread Jeremy Burns
I have a site (test.nudgedeck.com) that renders as expected in web browsers. But when viewed in mobile Safari all I see is this: [] Any clues what this could be? CakePHP 2.4.7 fully installed. -- Like Us on FaceBook https://www.facebook.com/CakePHP Find us on Twitter http://twitter.co

Re: Image is not displaying

2014-04-17 Thread Jeremy Burns : Class Outfit
I've experienced this before and it was nothing to do with the images. Try checking that all of your CSS and JS files are being called correctly. I have noticed that if you are trying to load a non-existent file through the Html helper, other things break. Jeremy Burns Class Outfit

Re: Redirect to json extension

2014-04-04 Thread Jeremy Burns
ws/Users/login.ctp) even if the mobile app posts to the non json extension. On Friday, 4 April 2014 11:50:00 UTC+1, Jeremy Burns wrote: > > In our continued head long plunge into iOS app integration we have now got > the iOS app talking nicely with the Cake controller code using json,

Redirect to json extension

2014-04-04 Thread Jeremy Burns
In our continued head long plunge into iOS app integration we have now got the iOS app talking nicely with the Cake controller code using json, Router::parseExtensions(); and json views. The next challenge is redirecting. For example, the Auth component's loginRedirect is set to a non json view

iOS app development

2014-04-03 Thread Jeremy Burns
We're developing an iOS app alongside a CakePHP web app. At this point the iOS developer is using the XCode simulator. I have some questions about how the PHP code should be altered to handle requests from iOS. We are learning as we go along... - When I do a check for $this->request->isMobile()

Re: iOS app authentication

2014-04-02 Thread Jeremy Burns : Class Outfit
Thanks Jose - we'll try that. On 2 Apr 2014, at 21:19, José Lorenzo wrote: > Send the data encoded with application/x-www-form-urlencoded > > On Wednesday, April 2, 2014 10:04:40 PM UTC+2, Jeremy Burns wrote: > We're developing a CakePHP web site alongside an iOS app. O

iOS app authentication

2014-04-02 Thread Jeremy Burns
We're developing a CakePHP web site alongside an iOS app. Our iOS developer is trying to get the app to authenticate via the /users/login function of the web site (which uses form authentication) but it isn't working. The users controller cannot read $this->request-data. Are we missing something

Re: Testing a logged in user

2014-03-27 Thread Jeremy Burns : Class Outfit
end to your test command. > Otherwise the session based tests will fail. > > > Am Donnerstag, 27. März 2014 11:43:54 UTC+1 schrieb Jeremy Burns: > I've read and searched and am stumped. I have set up test cases and fixtures > for my (built) models and controllers. I want to

Testing a logged in user

2014-03-27 Thread Jeremy Burns
I've read and searched and am stumped. I have set up test cases and fixtures for my (built) models and controllers. I want to run a controller test that logs in a specific user (who exists in my users fixture) and then run a controller action. I want to test that the displayed values meet expec

Re: How to return json message inside controller?

2014-03-13 Thread Jeremy Burns | Class Outfit
I put this in AppController beforeFilter: if ($this->request->is('ajax')) { Configure::write('debug', 0); $this->autoRender = false; $this->layout = 'ajax'; $this->disableCache(); } On 13 Mar 2014, at 11:29, Wladimir Chopite wrote: > Use at the beginning of your

Re: Is Cake Dead Or Just Catching Up?

2014-03-12 Thread Jeremy Burns : Class Outfit
I was also surprised to see Zend so far down - any glance over the job boards suggests this is one of the most in demand frameworks. I'm not losing any sleep over this survey. On 12 Mar 2014, at 14:50, kdubya wrote: > I'm taking the bait: > > Looking at the article and the pie chart I have th

Re: Is Cake Dead Or Just Catching Up?

2014-03-11 Thread Jeremy Burns : Class Outfit
;t ask, or "Someone help me build a Facebook copy - and hurry! Its urgent!". I found it more and more difficult to contribute any value, so drifted away. I still read every question but rarely feel the urge to respond. But I still don't use that as a measure of the quality of

Re: Is Cake Dead Or Just Catching Up?

2014-03-10 Thread Jeremy Burns : Class Outfit
e core members left the team. It didn't die then and it isn't going to die now. It's all good. Jeremy Burns Class Outfit http://www.classoutfit.com On 11 Mar 2014, at 06:24, Dr. Tarique Sani wrote: > CakePHP is far from dead. Have been hearing about since a few years now ;-)

Re: Any problems if foreign key is defined in the table creation SQL script?

2014-02-23 Thread Jeremy Burns : Class Outfit
I always view them separately. The model associations tell Cake how different tables are related but doesn't enforce it. The SQL absolutely defines the relationships and enforces the integrity. I wouldn't omit the integrity as that is the golden source. Jeremy Burns Class Ou

Re: Does the choice of framework matter to ease of ajax dynamic front-end coding?

2014-01-20 Thread Jeremy Burns : Class Outfit
CakePHP is absolutely fine for Ajax. Your approach sounds right - it’s what I do. On 20 Jan 2014, at 14:58, Sam wrote: > I have an upcoming project which may use lots of ajax dynamic front-end > features. Does the choice of framework matter to ease of ajax dynamic > front-end coding? I have n

Re: Customise authError message class

2013-12-13 Thread Jeremy Burns : Class Outfit
Why not just specify the element you need as the second parameter then create an element for each message type - then you have complete control over layout, styling, classes and eventhing.? http://book.cakephp.org/2.0/en/core-libraries/components/sessions.html#SessionComponent::setFlash Jeremy

Re: Is it possible to retrieve webroot folder location in Javascript?

2013-10-29 Thread Jeremy Burns : Class Outfit
Not sure if it's the approved way, but I do this: var baseUrl = '<?php echo $this->Html->url('/', true); ?>'; ...before I load jQuery, which means I can use the baseUrl variable. Jeremy Burns Class Outfit http://www.classoutfit.com On 30 Oct 201

Re: How to relate table with one of many others?

2013-09-30 Thread Jeremy Burns | Class Outfit
Cake won't/can't but your code can make it happen. Jeremy Burns Class Outfit http://www.classoutfit.com On 30 Sep 2013, at 13:55:01, Kemal wrote: > I am using Mysql Workbench and it forces plural names. I will fix them. Will > cakephp decide whether it is a domain or a ho

Re: How to relate table with one of many others?

2013-09-30 Thread Jeremy Burns | Class Outfit
ng orders_id to something that doesn't end in _id as Cake will try to find a related table and build an association with it; perhaps client_reference would be better? If you made those changes you could get your basic models built using cake bake. Jeremy Burns Class Outfit http://www.class

Re: How to relate table with one of many others?

2013-09-30 Thread Jeremy Burns | Class Outfit
Surely there would be a 1->many relationship between: orders_types (which ought to be called order_types) and orders domains to orders hostings to orders? Jeremy Burns Class Outfit http://www.classoutfit.com On 30 Sep 2013, at 13:05:18, Kemal wrote: > Hello, > > I have create

Re: Cake PhP Beginner: nested associations and views

2013-09-16 Thread Jeremy Burns | Class Outfit
Have a look at the Containable behaviour, add it to your AppModel (so it is always available) and set recursive to -1 in your AppModel. Containable is your friend. It gives you complete control over what associated data is returned. Jeremy Burns Class Outfit http://www.classoutfit.com On 16

Unrelated data

2013-09-14 Thread Jeremy Burns
A question that I perhaps I should know the answer to, but I am not clear on the recommended approach - I am open to ideas. I want to add a wizard process to an app. A wizard takes a user through a series of steps by visiting pages in sequence. Wizard availability and progress is managed in the

Re: Putting custom code in a separate repository

2013-09-09 Thread Jeremy Burns : Class Outfit
You add submodules in a path relative to the root of the git repository. I am a Git command line coward so use SourceTree (http://sourcetreeapp.com) which does it all for me. I have all (most) of my plugins as submodules. On 9 Sep 2013, at 14:48, David Suna wrote: > Thanks for the suggestion.

Re: Putting custom code in a separate repository

2013-09-09 Thread Jeremy Burns : Class Outfit
Check out Git submodules - that's exactly what they are for. Jeremy Burns Class Outfit http://www.classoutfit.com On 9 Sep 2013, at 14:17, David Suna wrote: > I started a project locally by cloning the git repository for CakePHP (branch > 2.4). I would like to maintain the abil

Re: Ajax Login - Redirect Help

2013-09-05 Thread Jeremy Burns : Class Outfit
Don't know if this is the best way of handling this, but this is what I do: https://gist.github.com/classoutfit/6459420 It seems to work pretty well. Jeremy Burns Class Outfit Mob: +44 (0) 7973 481949 Tel: +44 (0) 208 123 3822 Skype: jeremy_burns classoutfit.com @classoutfit On

Re: My awesome flash system

2013-09-04 Thread Jeremy Burns : Class Outfit
How is that more awesome than what you do out of the box? On 4 Sep 2013, at 16:14, Prashant Shah wrote: > Hi, > > This is first time I am working with cakephp and I was not satisfied with the > flash message system in cakephp. > > Here is how to setup your own awesome flash system (MIT Licens

Re: decrypt password

2013-08-30 Thread Jeremy Burns : Class Outfit
It (deliberately) uses one way encryption. All it can do is encrypt your password attempt and see if it matches what is stored (which is also encrypted). Jeremy Burns Class Outfit http://www.classoutfit.com On 30 Aug 2013, at 10:53, raj kumar Pustela wrote: > hi to

Re: Where are the sites?

2013-08-17 Thread Jeremy Burns | Class Outfit
t a decent back end the pretty site will not work very well. You could say judging the mechanics of a site by focussing on how good it looks is like putting a vacuum cleaner motor inside a Ferrari body, no? Jeremy Burns Class Outfit http://www.classoutfit.com On 18 Aug 2013, at 05:40:03,

Re: Include count of nested associated object as virtual field.

2013-08-17 Thread Jeremy Burns | Class Outfit
counterCache is your friend. Jeremy Burns Class Outfit http://www.classoutfit.com On 17 Aug 2013, at 23:02:51, Nicholas Amon wrote: > Hi, > > I have the following model relationships > > Question belongs to Chapter > Chapter belongs to Unit > > I want to add a v

Re: Data validation: Client or Server?

2013-08-16 Thread Jeremy Burns | Class Outfit
or API? Then you'd need to load up your validation anyone. Just my 2c. Jeremy Burns Class Outfit http://www.classoutfit.com On 16 Aug 2013, at 12:32:29, jer...@anthemwebsolutions.com wrote: > I wanted to get some opinions on this. Cake's validation structure is easy to >

IE6 and IE7 losing sessions - can't log in - solved

2013-08-15 Thread Jeremy Burns
I'm posting this as I had a problem that was driving me nuts. I know IE7 is ancient, so there are some posts on this subject from 2008/9, but none solved it for me. I have a global banking client trying my software and their standard browser is IE6. That is not at all uncommon in large corporat

Re: Prefilling form data doesn't seem to work

2013-08-14 Thread Jeremy Burns : Class Outfit
$data = $this->Model->find etc... unset($data['Model']['id']; $this->data = $data; On 14 Aug 2013, at 19:40, Anja Liebermann wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > Hi David, > > > this is how I would do it: > > copy your edit method and rename it to "copy". Like with

Re: Security and Ajax

2013-08-08 Thread Jeremy Burns : Class Outfit
Because the keys are 'use once', so when submitted by ajax become invalid. See this page for a solution: http://book.cakephp.org/2.0/en/core-libraries/components/security-component.html#SecurityComponent::$csrfUseOnce Jeremy Burns Class Outfit http://www.classoutfit.com On 8 Aug 2

Re: rawurlencode() expects parameter 1 to be string, array given [CORE/Cake/Routing/Route/CakeRoute.php, line 503]

2013-08-06 Thread Jeremy Burns | Class Outfit
Looks like $menuList is an array but a string is expected. Jeremy Burns Class Outfit http://www.classoutfit.com On 6 Aug 2013, at 15:58:54, Nicholas Amon wrote: > Hi, > > I am making this requestAction call in my menu.ctp: > > $menus = $this->requestAction(array( >

Re: illuminate, remove Year in birthday field in cake 1.3

2013-06-22 Thread Jeremy Burns | Class Outfit
Have you thought about adding month and day fields to the table and populating them beforeSave? Less processing required when you want to run your cron job. Jeremy Burns Class Outfit http://www.classoutfit.com On 22 Jun 2013, at 21:13:01, Chris wrote: > Hi guys,... can anyone help me ple

Re: Order Tree output

2013-06-11 Thread Jeremy Burns
his node (between its lft and rght values) and updates those too. It works nicely and is quite snappy. I also built a temporary function to populate the file for migration. On Tuesday, 11 June 2013 16:02:01 UTC+1, Jeremy Burns wrote: > > I've got a multi-tenancy site that includes

Order Tree output

2013-06-11 Thread Jeremy Burns
I've got a multi-tenancy site that includes some tables that use the Tree behaviour. By multi-tenancy I mean that several different clients all store their data in the same database and they can only access and manage their own data. For example, each client stores their departments in the 'dep

  1   2   3   4   5   6   7   8   9   10   >