Re: After validation data is getting cleared

2010-04-08 Thread Jeremy Burns
redundant too. Next step is to: code debug($this-data); /code ...in both your controller function and your view - see what's in there. If you are still having problems, post the contents of the data array back here. Jeremy Burns jeremybu...@me.com On 9 Apr 2010, at 06:42, Ambika Kulkarni wrote: Hi

Re: Page caching ??

2010-04-07 Thread Jeremy Burns
I would remove everything in your folders under app/tmp/cache/ (models, persistent and views), then fire up your app with debug set to 2 (then back to 0 if you choose) to rebuild the cache and see what happens. Jeremy Burns jeremybu...@me.com On 7 Apr 2010, at 00:14, Ed Propsner wrote: I'm

Re: Should I migrate from RC 1.1 to RC 1.2 or 1.3 ????

2010-04-07 Thread Jeremy Burns
had no issues since the migration. I agree with Dr Loboto - if you are going to feel some pain now anyway, why not get it all over and done with, else you are going to have to do it all again later. Jeremy Burns jeremybu...@me.com On 7 Apr 2010, at 04:26, altermod wrote: Thanks for the input

Re: Passing variable from a controller to another controller

2010-04-07 Thread Jeremy Burns
: $this-Applicant-Document-add($applicantId); This assumes that the two models are related. Jeremy Burns jeremybu...@me.com On 7 Apr 2010, at 05:59, aveev wrote: Hi, I'm designing a travel document application ... In this application, after we confirm user data, the application will assign a travel

Re: Page caching ??

2010-04-07 Thread Jeremy Burns
Cool (that sounds totally normal!) - what was the solution, and what are you stuck on now? Jeremy Burns jeremybu...@me.com On 7 Apr 2010, at 07:15, Ed Propsner wrote: Thanks Jeremy I worked it out. It had me stumped at first but turned out to be a really simple fix which usually ends up

Re: displaying login details

2010-04-07 Thread Jeremy Burns
harder). Jeremy Burns jeremybu...@me.com On 7 Apr 2010, at 14:02, Ambika Kulkarni wrote: Hey Sana, function fetchData() { $this-loadModel('MainCategory','MenuItem','GroupUser','User'); $main_category = $this-query(SELECT mi.*, ga.* FROM menu_items as mi

Re: setup in production server

2010-04-06 Thread Jeremy Burns
Consider the folder that contains app, cake etc as the root. Move everything in that folder into your root and it should work. Don't forget the .htaccess files, which might be invisible. Jeremy Burns jeremybu...@me.com On 5 Apr 2010, at 04:29, adeveloper guy wrote: Hi, I need help

Re: Blog to discuss cakePHP issues

2010-04-06 Thread Jeremy Burns
And this is for - what? Jeremy Burns jeremybu...@me.com On 6 Apr 2010, at 07:01, bhushan A wrote: My blog CakePHP issues: http://bhooshanahirrao.wordpress.com/2010/04/05/cakephp-problems/ Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP

Re: HABTM QUestio: Getting all non related data

2010-04-06 Thread Jeremy Burns
There is a reference to NOT IN in the guide - I am sure you could adapt that? http://book.cakephp.org/view/1030/Complex-Find-Conditions Jeremy Burns jeremybu...@me.com On 6 Apr 2010, at 17:13, Renato de Freitas Freire wrote: Hi all. Sorry if its a noob question, but I cant find it anywhere

Re: Naming convention

2010-04-02 Thread Jeremy Burns
It's not ideal to move away from conventions, but you can use var $useTable = 'myname'; in your Myname model. Jeremy Burns jeremybu...@me.com On 2 Apr 2010, at 10:17, Ambika Kulkarni wrote: Hi there, I am pretty new to cake. I am aware of naming conventions in cakePHP as I have created

Re: Split controller into many files

2010-04-01 Thread Jeremy Burns
You could move the functionality to a component? http://book.cakephp.org/view/993/Components Jeremy Burns jeremybu...@me.com On 1 Apr 2010, at 11:25, Jonas wrote: Hello, Is there some recommended way of splitting a controller into several files? It's getting a bit too large for my taste

Re: Information History

2010-04-01 Thread Jeremy Burns
Could you be more specific? Jeremy Burns jeremybu...@me.com On 1 Apr 2010, at 14:19, julix wrote: Hi, i need information about the history of CakePHP. Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions. You received

Re: Can I filter on models deep in a 'contains' ?

2010-04-01 Thread Jeremy Burns
It's a bit tricky, but you can do 'ORs' and ANDs': http://book.cakephp.org/view/1030/Complex-Find-Conditions Jeremy Burns jeremybu...@me.com On 1 Apr 2010, at 15:58, Lucca Mordente wrote: I don't know whether it's possible... I think custom query would be the best solution. Lucca Mordente

Re: Blank page when CakePHP is uploaded to the server

2010-04-01 Thread Jeremy Burns
That sounds like a weird cop out! That's like saying We won't let you run PHP! Jeremy Burns jeremybu...@me.com On 1 Apr 2010, at 17:14, WhyNotSmile wrote: I eventually contacted the hosting company about this, and they said 'We see you are using cake. We don't support that.'. Aaargh

Re: Multiple Table-Model, Multiple DB

2010-03-31 Thread Jeremy Burns
at these sections of the book for starters: http://book.cakephp.org/view/1039/Associations-Linking-Models-Together http://book.cakephp.org/view/1323/Containable http://book.cakephp.org/view/1017/Retrieving-Your-Data Jeremy Burns jeremybu...@me.com (Skype) +44 208 123 3822 (jeremy_burns) (m) +44 7973 481949

Re: Cake 1.2.6 - Can't bake anything

2010-03-31 Thread Jeremy Burns
Is it worth posting your database configuration file (with username, password and server details obscured)? Jeremy Burns jeremybu...@me.com On 31 Mar 2010, at 13:17, Jay Childers wrote: The connection parameters are solid, the authenticAtion is solid, and theserver def. Receives remote

Re: always use singular model and controller names

2010-03-31 Thread Jeremy Burns
Try adding some custom inflections (plurals): http://book.cakephp.org/view/953/Inflections Jeremy Burns jeremybu...@me.com On 31 Mar 2010, at 22:42, tekcorap wrote: Hi everyone, I have a small problem. I'm using CakePHP 1.2.6. Unfortunately, not as in English plurals in Turkish. eg makale

Re: I can't get the value of session in controller

2010-03-30 Thread Jeremy Burns
Have you tried using the session component and helper instead of accessing the session directly? Jeremy Burns jeremybu...@me.com On 30 Mar 2010, at 09:33, Rimoe wrote: hi, everyone, I have set a session in aa.php ( session_start(); $_SESSION['aa'] = '12345'; ) I can read

Re: Initial loading of Cake problem: Trying to get property of non-object in ...

2010-03-30 Thread Jeremy Burns
MAMP and MAMP Pro works well too. Jeremy Burns jeremybu...@me.com On 30 Mar 2010, at 13:58, Jon Bennett wrote: How have you installed Apache and PHP? I suggest you use a package such as WampServer 2 (what I use) or Xampp. Don't use xampp, least not on OSX - it caused me no end of pain

Re: recommendable to write view inside html tags?

2010-03-30 Thread Jeremy Burns
My opinion... I think these tags belong inside the layout, and have layout tags (div etc) in the view so that they appear inside the body tags rendered by the layout. As a view is always rendered inside a layout (isn't it?) there is no need for html etc inside the view. Jeremy Burns jeremybu

Re: CakePHP 1.3.0-RC3 unleashed

2010-03-30 Thread Jeremy Burns
I believe that whilst both work, the first is the way to go now; i.e. $this-Html, $this-Form etc. Jeremy Burns jeremybu...@me.com On 30 Mar 2010, at 17:26, Sam Sherlock wrote: Congratulations and thanks to Mark and all those who contributed 1.3 is very fast; upgrading is smooth. Baking

Re: reusable component

2010-03-29 Thread Jeremy Burns
This sounds like a behaviour to me... http://book.cakephp.org/view/1071/Behaviors Jeremy Burns jeremybu...@me.com On 29 Mar 2010, at 07:13, sooraj francis wrote: hi, i need to Create a “REUSABLE” class file which accepts the input parameters as (“data”,”type”,”parameter”) Data

Re: DataTables, cakePHP, and Pagination through Ajax

2010-03-29 Thread Jeremy Burns
Ajax pagination is quite simple - here's a good link using MooTools (I do exactly the same but using JQuery). Also, see the guide. Then look at the pagination section of the book, which spells out the pagination options (such as the footer text you refer to). Jeremy Burns jeremybu...@me.com

Re: open cake projects

2010-03-29 Thread Jeremy Burns
In my opinion you are best off creating your own problem then developing a solution for it. At least, that's how I learn. Jeremy Burns jeremybu...@me.com On 29 Mar 2010, at 14:10, dole.doug wrote: Hi there I;m on the learning stage of CakePHP. I've passed the blog totorial and i think

Re: help me with some logic

2010-03-29 Thread Jeremy Burns
with the right id (die(debug($this-data)); to check it out). Then all you need to do inside your Post's controller is $this-Post-Comment-save($this-data['Comment']); I have just typed that, not tested it, but it ought to work. If not. it'll be close enough. Jeremy Burns jeremybu...@me.com

Re: Blank page when CakePHP is uploaded to the server

2010-03-29 Thread Jeremy Burns
How about creating a really simple app with one model/controller and no security, auth, acl, routing or anything? Just see if a vanilla app works. That might help work out if it is infrastructure or code. Jeremy Burns jeremybu...@me.com On 29 Mar 2010, at 15:47, WhyNotSmile wrote: Thanks

Re: Newbie question for best practice on how to combine CakePHP with a (given) design

2010-03-29 Thread Jeremy Burns
of other ideas too. Jeremy Burns jeremybu...@me.com On 29 Mar 2010, at 13:49, janitor048 wrote: Hi there, I'm pretty new to CakePHP (and MVC in general for that matter) and I'm just working through the docs etc. And since the cookbook is quite informative, I think I've got a pretty good idea

Re: Undefined index

2010-03-28 Thread Jeremy Burns
dividends. I have also found that straying too far off the path and trying to do my own thing is bad - sticking to conventions is good in so many ways. Jeremy Burns jeremybu...@me.com On 28 Mar 2010, at 09:15, WebbedIT wrote: Can you explain why you believe Cake/Auth is removing Username

Re: Undefined index

2010-03-27 Thread Jeremy Burns
I'm no Ajax expert, but that sounds about right! Jeremy Burns jeremybu...@me.com On 27 Mar 2010, at 06:22, Ed Propsner wrote: I think part of the problem here is that $ajax-observeField is only is only focusing on a single form field and that is the element being passed to the controller

Re: retrieve related model data

2010-03-26 Thread Jeremy Burns
Can you show me your entire $hasMany and $belongsTo declarations, and your find statement? Jeremy Burns jeremybu...@me.com On 26 Mar 2010, at 06:24, sebb86 wrote: Jeremy Burns Hello again :) Code in the model of my port-table: (the $hasOne association from my origionally question

Re: retrieve related model data

2010-03-26 Thread Jeremy Burns
('Port.hardware_unit_id' = 'asc'), 'contain' = array( 'ChildPort' = array('HardwareUnit'),'HardwareUnit','Vlan','PortEmploymentGroup') ); Jeremy Burns jeremybu...@me.com On 26 Mar 2010, at 06:54, sebb86 wrote: sure! :-) [code of model port] public $belongsTo = array

Js helper forms

2010-03-26 Thread Jeremy Burns
Does anyone have an example of how to create an Ajax form from start to end using the Js helper in 1.3? Which components/helpers to include, how to set up the view and the controller, how to get the right layout etc? The information is all out there somewhere, but in bits. I'd love to see a simple

Re: $html-link Path Problem

2010-03-26 Thread Jeremy Burns
(show = view?). Jeremy Burns jeremybu...@me.com On 26 Mar 2010, at 10:01, Alper K. Tunç wrote: Hi all, I'm going over the QuickWall example in CakePHP Application Development book by Ahsanul Bari and Anupom Syam. In the example, there is a line where the questions are produced: ?php e($html

Re: $html-link Path Problem

2010-03-26 Thread Jeremy Burns
I have found this book to be by far the best. It covers all of the bases and does what it says on the tin. Second place goes to Practical CakePHP Projects. But you're right - CakePHP books are thin on the ground. Jeremy Burns jeremybu...@me.com On 26 Mar 2010, at 11:44, Alper K. Tunç wrote

Re: Undefined index

2010-03-26 Thread Jeremy Burns
it. If the path is not right, you get the undefined index error. Is it worth pasting the output here? Jeremy Burns jeremybu...@me.com On 27 Mar 2010, at 02:59, Ed Propsner wrote: I'm not sure why but I'm relatively sure that it's not recognizing the form fields for username and password

Re: Undefined index

2010-03-26 Thread Jeremy Burns
So all you can get is $this-data['User']['confirm_password']... Are you expecting more fields to be in the array? Are the fields you want inside the form in the view? Jeremy Burns jeremybu...@me.com On 27 Mar 2010, at 05:00, Ed Propsner wrote: The only thing showing in the array

Re: Undefined index

2010-03-26 Thread Jeremy Burns
But are they inside the form in the view? Jeremy Burns jeremybu...@me.com On 27 Mar 2010, at 05:15, Ed Propsner wrote: Yes, I'm expecting to see $this-data['User'][''password'] as well. Both fields exist and are displayed in the view. On Sat, Mar 27, 2010 at 1:09 AM, Jeremy Burns

Re: Undefined index

2010-03-26 Thread Jeremy Burns
You say they are being recognised OK, but they weren't in the $this-data array? Have you checked the actual page source to examine the form in the view? Only yesterday I debugged a similar problem where the browser was ending the form for me (I had embedded it incorrectly into a table). Jeremy

Re: Multiple Table-Model, Multiple DB

2010-03-25 Thread Jeremy Burns
later. Welcome to Cake, by the way. It's great. Jeremy Burns jeremybu...@me.com On 25 Mar 2010, at 10:06, cupidoly wrote: I am newbie in CakePHP, using it only for 2 days. I am using PHP 5.2.10, MySQL 5.0.84, CakePHP 1.2.6. I have two questions. Scenario 1. While designing my site

Re: Multiple Recordsets in Same View

2010-03-25 Thread Jeremy Burns
to an existing array and get back a single block of data (my preferred route) or ask the controller to trigger a number of separate queries and process the arrays in the controller. Jeremy Burns jeremybu...@me.com On 25 Mar 2010, at 16:02, Alper K. Tunç wrote: Hello all, I'm one of the latest

Re: Blank page when CakePHP is uploaded to the server

2010-03-25 Thread Jeremy Burns
The .htaccess files can be hidden and therefore missed when doing an upload. Seems like a basic thing - but are the .htaccess files on the sever? Jeremy Burns jeremybu...@me.com On 25 Mar 2010, at 22:59, cricket wrote: On Mar 25, 4:31 pm, WhyNotSmile sharongilmor...@googlemail.com wrote

Re: Undefined index

2010-03-25 Thread Jeremy Burns
Have you debugged the data that is being presented to the controller function? Set debug to 2 and type die(debug($this-data)); as the first instruction, then take a look at what you see. Is password there? You might need to do something like $this-data[0]['password'], for example. Jeremy Burns

Re: 3rd party app - installation issues

2010-03-25 Thread Jeremy Burns
and accessed it via http://xxx.yoursite.com Jeremy Burns jeremybu...@me.com On 25 Mar 2010, at 18:50, ltix wrote: I need to use a 3rd party app (phpsitemapng), but not sure where to install it. I'm using the app to create a site wide sitemap.xml and then I will submit it to the search engines

Re: retrieve related model data

2010-03-25 Thread Jeremy Burns
'), 'contain' = array( 'ParentPort' = array('HardwareUnit', 'Port' ),'HardwareUnit','Vlan','PortEmploymentGroup') ); Jeremy Burns jeremybu...@me.com On 26 Mar 2010, at 05:41, sebb86 wrote: I use this in my controller: [controller code] var $paginate

Re: retrieve related model data

2010-03-24 Thread Jeremy Burns
To work this, start at the top and work your way down through the array: $this-data['Port'][0]['HardwareUnit']['schenker_number'] Jeremy Burns jeremybu...@me.com On 24 Mar 2010, at 14:25, sebb86 wrote: cricket Again... thanks a lot for your help. It seems to work. When i debug, i get

Re: Blank page when CakePHP is uploaded to the server

2010-03-24 Thread Jeremy Burns
) Jeremy Burns jeremybu...@me.com On 24 Mar 2010, at 15:17, WhyNotSmile wrote: I've built a site in CakePHP 1.2, which is working fine locally. However, when I upload it to the server and then navigate to it, I get a blank page. The setup is exactly the same, and the .htaccess files haven't been

Re: Blank page when CakePHP is uploaded to the server

2010-03-24 Thread Jeremy Burns
Does your home page need db access? If so, try removing that code (or create a temporary dummy) and see if that comes through. Have you checked that mod_rewrite is enabled on the server too? Jeremy Burns jeremybu...@me.com On 24 Mar 2010, at 15:58, WhyNotSmile wrote: An update - I've

Re: Building a submenu based on the current page_id

2010-03-24 Thread Jeremy Burns
This might help... http://articles.classoutfit.com/2009/11/cakephp-dynamic-navigation-bars/ Jeremy Burns jeremybu...@me.com On 24 Mar 2010, at 19:12, mattyh88 wrote: Hello, I'm building a submenu (which holds sub pages of the current page) into my cakephp site. This submenu is based

Js helper and multiple effects

2010-03-24 Thread Jeremy Burns
I'm using the Js helper in 1.3 for Ajax pagination, adding a fadeOut fadeIn effect to my content div. Can I produce two simultaneous effects? For example, can I fade out my content div and show my progress/spinner div, then hide my progress/ spinner div and fade in my content div? Check out the

Re: Class 'AppController' not found.

2010-03-23 Thread Jeremy Burns
Just a small extra point - did you mean var $scaffold? Jeremy Burns jeremybu...@me.com On 23 Mar 2010, at 07:53, Martin Duris wrote: check, if you you have AppController in C:\xampp\htdocs\cakephp\app\ ... maybe you have deleted it ... 2010/3/23 Sean sean...@gmail.com: Hey, guys. I'm

Re: Multi-level form

2010-03-23 Thread Jeremy Burns
Yes, this is totally possible - see this section: http://book.cakephp.org/view/1031/Saving-Your-Data. The secret is in getting your $this-data array into the right shape, then using either saveAll or save each model at a time. Jeremy Burns jeremybu...@me.com On 23 Mar 2010, at 18:13, Gianni

Re: Fata error: non-object ?

2010-03-22 Thread Jeremy Burns
Sounds like Cake is trying to interpret this as a join table as part of HABTM (users - details). Try renaming the table/model/controller/views structure to user_details. Jeremy Burns jeremybu...@me.com On 22 Mar 2010, at 00:24, redcat wrote: I have a database table called users_details I

Re: Creating a simple search form

2010-03-20 Thread Jeremy Burns
into a variable ($results?). Then have a view called process.ctp (at this point, having a function and view called process sounds wrong - 'results' sounds more intuitive?). In the view, you can pick up your $results and display them. Jeremy Burns jeremybu...@me.com On 20 Mar 2010, at 12:32, aveev

Re: find('list') - 'fields'-parameter in model?

2010-03-19 Thread Jeremy Burns
Yes. Place this in your model: var $displayField = 'fieldName'; Jeremy Burns jeremybu...@me.com On 19 Mar 2010, at 07:46, LDSign wrote: Hi Is it possible to move the fields-parameter for find('list') into the model so it can be used with every find('list') command? Thanks, Frank

Re: Making my app accessible on www.cdchayofa.com instead of www.cdchayofa.com/cdchayofa/

2010-03-18 Thread Jeremy Burns
Try renaming 'cdchayofa' to 'app'. Jeremy Burns jeremybu...@me.com On 18 Mar 2010, at 09:59, mattyh88 wrote: Hi, I'm having some troubles setting up my website on my webserver (hosted @ siteground.com) I have uploaded this to the root (public_html) cake cdchayofa (cake app folder

Re: Making my app accessible on www.cdchayofa.com instead of www.cdchayofa.com/cdchayofa/

2010-03-18 Thread Jeremy Burns
The most complex, baffling and time consuming problems always seem to come back down to something blindingly obvious! Pleased it helped. Jeremy Burns jeremybu...@me.com On 18 Mar 2010, at 10:12, mattyh88 wrote: Thanks a lot ! Can't believe it was something that stupid lol. Been googling

Re: cakephp 1.3 $this-Session-setFlash

2010-03-18 Thread Jeremy Burns
You need to do: echo $session-flash(); now. Jeremy Burns jeremybu...@me.com On 18 Mar 2010, at 13:06, Johannes Goll wrote: Hi, I am migrating from 1.2 to cakephp 1.3 and am trying to switch to the new $this-Session-setFlash functionality that uses elements: Projects Controller

Re: pagination -changing labels in th tags?

2010-03-18 Thread Jeremy Burns
You can insert the label as the first argument, like this: th?php echo $this-Paginator-sort('#A', 'NumberOfAdults');?/th Jeremy Burns jeremybu...@me.com (Skype) +44 208 123 3822 (jeremy_burns) (m) +44 7973 481949 (h) +44 208 530 7573 On 18 Mar 2010, at 16:21, mivogt-LU wrote: Hello, me

Re: pagination -changing labels in th tags?

2010-03-18 Thread Jeremy Burns
' = 'cssSytle')), etc... ) ) ); Jeremy Burns jeremybu...@me.com On 18 Mar 2010, at 16:25, Jeremy Burns wrote: You can insert the label as the first argument, like this: th?php echo $this-Paginator-sort('#A', 'NumberOfAdults');?/th Jeremy Burns

Ajax search form

2010-03-18 Thread Jeremy Burns
I'm not terribly strong on Ajax or Javascript, so this might be obvious to some of you. I have a view with a form that, when submitted, triggers a find and returns some search results to the same view. The search criteria is shown in the original search form fields. The view also contains an

Re: Ajax search form

2010-03-18 Thread Jeremy Burns
Sounds inspired John - I will try it. Thanks! Jeremy Burns jeremybu...@me.com On 18 Mar 2010, at 18:54, John Andersen wrote: Hi Jeremy, I am still not using Ajax, but I do think that information on my search solution may be usefull to you. When a user submits a search, I save the search

Re: Ajax search form

2010-03-18 Thread Jeremy Burns
Works great thanks John. I'm saving $this-data (that's the search criteria) into the session and now they are nice and sticky. Now I need some tips on sorting the Ajax stuff - are there any takers please? Jeremy Burns jeremybu...@me.com On 18 Mar 2010, at 18:54, John Andersen wrote: Hi

Re: Model help

2010-03-17 Thread Jeremy Burns
' = 'Boston' // mostly going to be a variable, e.g. $cityLabel ) ) ) ); I haven't tested that - just typed it here - but it ought to work. Jeremy Burns jeremybu...@me.com On 18 Mar 2010, at 01:27, Andrew wrote: Hello, Thank you for your time

Re: store session data and form data to database

2010-03-16 Thread Jeremy Burns
I do this and it works well. Follow these instructions: http://book.cakephp.org/view/1310/Sessions Jeremy Burns jeremybu...@me.com On 16 Mar 2010, at 07:11, stevec wrote: I would like store session data (e.g. login id) and form data to database Anyone know how to do this?? Please help

Re: Bake Screencast not Working?

2010-03-15 Thread Jeremy Burns
I have this problem too. If you view the page source you'll see the URL to where the screen casts actually are. I find that if you place that URL directly into your browser's address bar you can play them. However, some of them have no sound. Jeremy Burns jeremybu...@me.com On 14 Mar 2010

Re: Question related to database engine usage in CakePHP

2010-03-14 Thread Jeremy Burns
Never leave foreign keys, indexes, or anything else that the database should do to PHP. http://www.classoutfit.com/articles/2010/02/cakephp-basic-database-table-tuning-tips/ Jeremy Burns jeremybu...@me.com (Skype) +44 208 123 3822 (jeremy_burns) (m) +44 7973 481949 (h) +44 208 530 7573 On 13

Re: Start with 1.2 or 1.3?

2010-03-12 Thread Jeremy Burns
I upgraded a commercial application from 1.2 to 1.3 in about half an hour with no problems at all, and so far it's very solid. I have had a few problems getting some new Ajax stuff working, but that's about it. I'd say adopt 1.3 now. Jeremy Burns jeremybu...@me.com On 12 Mar 2010, at 09:05

Re: Start with 1.2 or 1.3?

2010-03-12 Thread Jeremy Burns
, but - to repeat - it's probably me being dumb. Jeremy Burns jeremybu...@me.com On 12 Mar 2010, at 09:22, jonathan wrote: Shoot - it's getting pretty busy around these parts at the 3:00a CT hour! Jeremy, thanks for weighing in - I use Prototype for all my AJAX stuff. Were you having trouble

Re: I have an ORM problem

2010-03-12 Thread Jeremy Burns
You don't need the echo - just debug() will suffice. Jeremy Burns jeremybu...@me.com On 12 Mar 2010, at 15:54, Mónico Briseño wrote: Hi, all. Paul, I did your suggestion. I got the following: ?php class BooksController extends AppController { echo debug($this-Book-Author-find('all

Re: pls help me in cake php model method

2010-03-10 Thread Jeremy Burns
application: http://book.cakephp.org/view/1527/Tutorials-Examples Jeremy Burns jeremybu...@me.com On 10 Mar 2010, at 12:47, nagendran wrote: i am beginner to cake php. my table name is tbl_admin i created one model with file name tbl_admin.php. Model code: class Eego_tbl_admin extends

Re: How to update multiple table data using saveall

2010-03-10 Thread Jeremy Burns
debug($this-data) and check that the primary keys (id) have values in them. If they do, Cake should update those rows. If they are blank, Cake assumes you want to add new ones. When you create the form, populate the id field (hidden, I guess) with the value from the $this-data array. Jeremy

Re: Enourms form. Can't save all the data.

2010-03-06 Thread Jeremy Burns
Have you cleared the files in /app/tmp/cache/models and set debug to 2? It sounds like your model could be cached, hence the new fields not being recognised or saved. Jeremy Burns jeremybu...@me.com On 6 Mar 2010, at 08:37, André Cardoso wrote: And btw again :( (sorry), I did try to save

Re: ACL with UUIDs

2010-03-03 Thread Jeremy Burns
I don't have any sample code to hand, but I have done this before yes it does work, so long as you update the ACL tables. See this for suggestions on improving those: http://pastie.org/823086 Jeremy Burns On 4 Mar 2010, at 04:10, bwelli...@gmail.com wrote: Hi all, Does anyone know

Re: Why Doesn't Anyone Know how to drop in a new URL in a cake framework

2010-03-01 Thread Jeremy Burns
Can you publish the contents of this file: /app/views/elements/steps.ctp ... to this forum? Jeremy Burns On 1 Mar 2010, at 16:33, APD wrote: I hired someone to add a blog to our website. I have noticed that there are always php errors anytime a new page is created. In my job description

Re: SSL and https

2010-03-01 Thread Jeremy Burns
I've only just got around to trying this - and it fits the bill really nicely thanks. Jeremy Burns On 18 Feb 2010, at 09:29, jperras wrote: http://github.com/plank/secured -jperras. On Feb 17, 12:54 am, Jeremy Burns jeremybu...@me.com wrote: Any takers on this please? Jeremy Burns

Debugging the Security component

2010-02-28 Thread Jeremy Burns
I have the Security component in my app_controller's $components array. The home page of a site has a simple text field to accept some data. When the form is submitted it is parsed through a controller with a very simple add function. This form submission is being intercepted and blackholed by the

Re: Debugging the Security component

2010-02-28 Thread Jeremy Burns
and started again, this time no blackhole. Doesn't really explain the reason behind this, but at least I know the cure. I placed a cake:nocache/cake:nocache block around the form for good measure. Jeremy Burns jeremybu...@me.com On 28 Feb 2010, at 11:01, Jeremy Burns wrote: I have the Security

Re: Debugging the Security component

2010-02-28 Thread Jeremy Burns
Issue not solved. The page is still being cached twice, which in and of itself is not a problem. With the form inside a nocache block, however, I am getting this error: Fatal error: Class 'Security' not found /cake/libs/view/helpers/form.php on line 378 Any clues please? Jeremy Burns

Re: Missing Action

2010-02-28 Thread Jeremy Burns
$this-Comment-vote is pointing to the vote action in the Comment model. If you want to call the vote action in the controller, use $this-vote instead. Jeremy Burns On 28 Feb 2010, at 17:08, Chuck wrote: I'm working through a tutorial (Beginning CakePHP book) and am getting an error I don't

Re: Apply https for a particular module

2010-02-28 Thread Jeremy Burns
This should get you started: http://book.cakephp.org/view/268/Usage This works in 1.2 and 1.3 - I can't confirm that the same for 1.1 though. Jeremy Burns On 1 Mar 2010, at 04:28, SeeVik wrote: Hello all I am using Cakephp 1.1 for my webapp and I want to use https when the user logs

Re: Cookies to Cart question

2010-02-26 Thread Jeremy Burns
from beginning to end without asking the user to log in or create an account first or revealing the id in the address bar, which also means it is difficult (but not impossible) for someone to spoof their way into another order. As Paul rightly says, you can then analyse abandoned orders. Jeremy

Re: Unit testing questions

2010-02-26 Thread Jeremy Burns
It's rarely a wasted post, even if it just makes others look and think. It's all a learning process... Jeremy Burns On 26 Feb 2010, at 10:12, WebRenovator wrote: Hi I had another look at the code. Turns out I had made a mistake in the model name. It was referencing the wrong model

Re: how to adress specific data from related models?

2010-02-24 Thread Jeremy Burns
that is creating your $this-data array and amend it, or find your value another way. Jeremy Burns jeremybu...@me.com On 24 Feb 2010, at 09:59, mivogt-LU wrote: Hi Jeremy, your suggested solution also results with an error because of a wrong Index. Notice (8): Undefined index: Lodging [APP\models

Re: Need help with custom validation please

2010-02-23 Thread Jeremy Burns
for the field and therefore appear on the form. Jeremy Burns jeremybu...@me.com On 23 Feb 2010, at 08:30, mivogt-LU wrote: hi there, I have some problems doing my first cake and adding some validation methods on my own. It would be great if someone in here might give me a good start and help me

Re: how to adress specific data from related models?

2010-02-23 Thread Jeremy Burns
want. Jeremy Burns jeremybu...@me.com (Skype) +44 208 123 3822 (jeremy_burns) (m) +44 7973 481949 (h) +44 208 530 7573 On 23 Feb 2010, at 08:41, mivogt-LU wrote: I am newbie to cakephp and after some looking up in books and google I need still help to start with cake... I try to do my first

Re: Answering a recurring challenge from clients

2010-02-23 Thread Jeremy Burns
to fight it. If you feel you can't/shouldn't/won't build the solution using the product they feel married to, be graceful and either do it anyway (as a professional), hire someone else in to do it for you (and retain the customer) or walk away (and maybe recommend someone for the job). Jeremy Burns

Re: Need help with custom validation please

2010-02-23 Thread Jeremy Burns
Probably - it sounds right. Debug $this-data and check. Jeremy Burns jeremybu...@me.com (Skype) +44 208 123 3822 (jeremy_burns) (m) +44 7973 481949 (h) +44 208 530 7573 On 23 Feb 2010, at 08:47, mivogt-LU wrote: Hi Jeremy, thank you, might I ask if I got the point: .. (something like

Re: Need help with custom validation please

2010-02-23 Thread Jeremy Burns
Good spot Paul - I replied too quickly! Jeremy Burns jeremybu...@me.com On 23 Feb 2010, at 09:21, WebbedIT wrote: Your data should have been available at: $this-data['BookingPosition']['amountofadult'] not $this-data['booking_positions']['amountofadult'] Just clarifying this in case

Re: How do I add custom validation in controller?

2010-02-23 Thread Jeremy Burns
Check for their presence/value in the controller, and then unset them from the array before saving. Jeremy Burns jeremybu...@me.com On 23 Feb 2010, at 12:16, Zac Tolley wrote: Ah but, the thing is I'm verifying fields that are not part of the model, I'm simply verifying that they agree

Re: Checking existence of variable passed to an element

2010-02-23 Thread Jeremy Burns
if (isset($variable)): do something; else: don't; endif; Jeremy Burns jeremybu...@me.com (Skype) +44 208 123 3822 (jeremy_burns) (m) +44 7973 481949 (h) +44 208 530 7573 On 23 Feb 2010, at 12:49, jbov wrote: I am a bit of newbie with CakePHP and DB-driven sites so bear with me. I have

Re: how to adress specific data from related models?

2010-02-23 Thread Jeremy Burns
work, so long as you have a relationship set up between BookingPosition and Lodging in the models. If you are accessing this from a controller, then you need to use $this-BookingPosition-Lodging...etc Jeremy Burns jeremybu...@me.com On 24 Feb 2010, at 07:26, mivogt-LU wrote: Hello Paul

Re: Another saveAll() problem

2010-02-22 Thread Jeremy Burns
Have you checked to see if your data array is missing any required fields? If so, it would still pass validation but fail at the database level. Also, is your validation right (does it match what the database expects)? Jeremy Burns jeremybu...@me.com On 22 Feb 2010, at 21:06, Lucca Mordente

Re: Screencasts won't play

2010-02-20 Thread Jeremy Burns
I have had similar problems (and I am all up to date) and play/pause controls are out of site (below the frame). I view the source go directly to the URL - e.g. http://www.archive.org/download/AdminRouting/admin_routing.mov and it all works fine. Jeremy Burns jeremybu...@me.com On 20 Feb 2010

Re: Error Code

2010-02-20 Thread Jeremy Burns
It looks as if you haven't set the $books array in your controller. Jeremy Burns jeremybu...@me.com On 20 Feb 2010, at 09:45, dido wrote: table thead thISBN/ththTitle/ththAuthor/th /thead ?php foreach($books as $book): ? tr td?php echo $book['Book

Multi model finds

2010-02-20 Thread Jeremy Burns
I am building a search form that retrieves data from four related models. The user can supply criteria against a number of fields from those models. What is the best method for doing a variable cross model search? To put that into context; If you have an Author model that hasMany Posts that

Re: How to make the paginator-sort link an image?

2010-02-19 Thread Jeremy Burns
You could do it with CSS? Jeremy Burns jeremybu...@me.com On 20 Feb 2010, at 02:15, MST wrote: How can I replace the text 'Paid' with an image at the top of my table? So, instead of this: th?php echo $paginator-sort('Paid', 'payment_received');?/th I get something like this: th?php

Re: ACL Question

2010-02-18 Thread Jeremy Burns
to help me set up Auth correctly. Of course, the tutorial also covers Acl, hence the mistake. Jeremy Burns jeremybu...@me.com On 15 Jan 2010, at 16:33, Dave wrote: Yeah it was only in the app_controller, but I just dumped cache folder and seemed to clear it up. Thanks, Dave

Re: Multiple forms on single page

2010-02-18 Thread Jeremy Burns
to the notes on how to shape your data array. Jeremy Burns jeremybu...@me.com On 18 Feb 2010, at 21:11, McScreech wrote: Is it possible to define several _independent_ data entry forms on a single page where each one posts data back to different models? Maybe with a redirect back to the same multi

Re: SSL and https

2010-02-17 Thread Jeremy Burns
Thanks John - I'll read, experiment and post back. Jeremy Burns jeremybu...@me.com On 17 Feb 2010, at 08:48, John Andersen wrote: Hi Jeremy, Take a look at the issue in this thread: http://groups.google.com/group/cake-php/browse_thread/thread/1c6b4727066173cf/19cf7202211f930d

Re: SSL and https

2010-02-16 Thread Jeremy Burns
Any takers on this please? Jeremy Burns jeremybu...@me.com On 12 Feb 2010, at 05:00, Jeremy Burns wrote: I am using the security component from app_controller. In some controllers I have this in my beforeFilter: if (in_array($this-params['action'], $action

<    11   12   13   14   15   16   17   18   >