Re: Error in Database Connection BUT dabase.php is correct

2016-02-08 Thread John Andersen
Check that your user "user" has permissions to use the databases.

Enjoy, John

On Sunday, 7 February 2016 18:48:33 UTC+2, Douglas Diniz Landim wrote:
>
> It was a site that was running on a host.
>
> This accommodation accidentally got deleted the domain for the site.
>
> After restoring the area, occurred database errors.
>
> I downloaded the site's files to my localhost, and saved in the www folder 
> of wamp, imported bath in my localhost for testing, and edited the 
> database.php files and wordpress plugin and yet mistakes are the same as 
> they were in accommodation.
>
> Kept files on hosting the FTP because some images of addresses can still 
> point to the hosting.
>
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error: changing website server

2015-08-12 Thread abhijit kakade
As per my understanding ..Problem could be in following areas

Mod rewrite
Htaccess
Cakelib path

Pls look into that direction.
On 12 Aug 2015 20:38, "michel martins"  wrote:

>
> Hi people!
>
>
> I'm with problems in change my website's server. It use cakephp and when i
> moved the files for new server, it's losing all path data, don't load the
> images, don't load the data...
>
>
> I searched file Config/routes.php, i verified .htaccess and dont is
> resolving.
>
>
> If I set the path manually, it work, but dont is correct, because it going
> to give error in the future.
>
>
> Anybody can teach me?
>
> --
> 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
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error linking forum titles to individual posts.

2015-03-30 Thread Odedere Ayokunle
Thanks. It works perfectly now. You guys are quite nice here, unlike the 
people on Stackoverflow that are fond of banning me for some days just 
because I incorrectly asked a question.  

On Sunday, 29 March 2015 20:49:57 UTC+1, Odedere Ayokunle wrote:
>
> Greetings everyone here. I am combining one Andrew Perkin video tutorial 
> (which explains cakephp in a step by step manner but quite stale) with the 
> official cake forum example (more current but less explanatory) in learning 
> cakePHP. The first thing I learnt how to do was to view all posts on the 
> index page, which works very fine. Then I proceeded to using "id's" to view 
> individual posts through the "view" action, this also works perfectly. My 
> challenge started when I wanted to link titles on the index page to their 
> individual forum posts. I do not seem to get the link class well. I tried 
> Andrew Perkin's approach but I was showed errors. Then I updated his 
> version to the official cake example style (adding helpers, exception for 
> null id's, etc), but still I am being told that "Fatal Error
>
> *Error: *Cannot access empty property 
> *File: *C:\xampp\htdocs\cakephp\lib\Cake\View\View.php 
> *Line: *867" 
>
> The surprising thing about this error is that I have never edited the 
> contents on the ../lib directory. So I do not know how to rectify it. I am 
> only used to the ../app directory. 
>
> Kindly find my code below and the associated file paths:
>
>  MODEL 
> cakephp/app/Model/Writeup.php
>
>  class Writeup extends AppModel {
> var $name='Writeup';
> }
> ?>
>
> CONTROLLER
> cakephp/app/Controller/WriteupsController.php
>
> class WriteupsController extends AppController {
> public $helpers = array('Html','Form');
>
> public function index() {
> $this->set('writeups',$this->Writeup->find('all'));
> }
>
> public function view($id = null) {
> $this->set('writeup',$this->Writeup->findById($id));
> }
>
> public function hello_world() {
> }
> }
> ?>
>
> VIEW
> cakephp/app/Views/Writeups/index.ctp
>  View All Posts
>
> 
>
> Title
> Body
>
> 
>
>  $Html->link($writeup['Writeup']['title'],
>  array('controller'=>'writeups', 
> 'action'=>'view',$writeup['Writeup']['id']));?> 
>   
>
>
>  
> 
>
> ##
> cakephp/app/Views/Writeups/view.ctp
>
>  
> 
>
> Created on: 
>  Last modified on:  ?>
> ###
> Once again, the error being provided by the debugger is that "Cannot 
> access empty property" and the file path of the error is "
> C:\xampp\htdocs\cakephp\lib\Cake\View\View.php", a path that I have never 
> edited. 
>
> Thank you.
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error linking forum titles to individual posts.

2015-03-30 Thread José Lorenzo
The problem is doing  $this->$Html->

It should be  $this->Html->

On Sunday, March 29, 2015 at 9:49:57 PM UTC+2, Odedere Ayokunle wrote:
>
> Greetings everyone here. I am combining one Andrew Perkin video tutorial 
> (which explains cakephp in a step by step manner but quite stale) with the 
> official cake forum example (more current but less explanatory) in learning 
> cakePHP. The first thing I learnt how to do was to view all posts on the 
> index page, which works very fine. Then I proceeded to using "id's" to view 
> individual posts through the "view" action, this also works perfectly. My 
> challenge started when I wanted to link titles on the index page to their 
> individual forum posts. I do not seem to get the link class well. I tried 
> Andrew Perkin's approach but I was showed errors. Then I updated his 
> version to the official cake example style (adding helpers, exception for 
> null id's, etc), but still I am being told that "Fatal Error
>
> *Error: *Cannot access empty property 
> *File: *C:\xampp\htdocs\cakephp\lib\Cake\View\View.php 
> *Line: *867" 
>
> The surprising thing about this error is that I have never edited the 
> contents on the ../lib directory. So I do not know how to rectify it. I am 
> only used to the ../app directory. 
>
> Kindly find my code below and the associated file paths:
>
>  MODEL 
> cakephp/app/Model/Writeup.php
>
>  class Writeup extends AppModel {
> var $name='Writeup';
> }
> ?>
>
> CONTROLLER
> cakephp/app/Controller/WriteupsController.php
>
> class WriteupsController extends AppController {
> public $helpers = array('Html','Form');
>
> public function index() {
> $this->set('writeups',$this->Writeup->find('all'));
> }
>
> public function view($id = null) {
> $this->set('writeup',$this->Writeup->findById($id));
> }
>
> public function hello_world() {
> }
> }
> ?>
>
> VIEW
> cakephp/app/Views/Writeups/index.ctp
>  View All Posts
>
> 
>
> Title
> Body
>
> 
>
>  $Html->link($writeup['Writeup']['title'],
>  array('controller'=>'writeups', 
> 'action'=>'view',$writeup['Writeup']['id']));?> 
>   
>
>
>  
> 
>
> ##
> cakephp/app/Views/Writeups/view.ctp
>
>  
> 
>
> Created on: 
>  Last modified on:  ?>
> ###
> Once again, the error being provided by the debugger is that "Cannot 
> access empty property" and the file path of the error is "
> C:\xampp\htdocs\cakephp\lib\Cake\View\View.php", a path that I have never 
> edited. 
>
> Thank you.
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error on phar update cakephp3

2014-11-12 Thread cesar calvo
I recently just upgraded composer and cakephp smoothly. Please paste the error 
message

You are already using composer version 
ab37a294f3383c812d0329623f0a4ba45387.
Loading composer repositories with package information
Updating dependencies (including require-dev)
  - Updating cakephp/cakephp 3.0.x-dev (fc18336 => ae59fb5)
Checking out ae59fb5086071b09f422f39d9d99b29a9724c5f6

Writing lock file
Generating autoload files

El miércoles, 12 de noviembre de 2014 12:50:02 UTC-2, Jipson Thomas 
escribió:
>
> Hi,
> In our cakephp 3 project under development we were updating the library 
> files using php composer.phar self-update and php composer.phar update. For 
> last one week after this update I am getting an internal error message. 
> Would you please help me to fix this?
>
> Regards,
> Jipson
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error: Cannot use "matching" on "Personas" as there is another association with the same alias

2014-10-16 Thread Rob Cowie
OK, I have, it is issue #4895.

Thanks


On Wednesday, 15 October 2014 20:51:50 UTC+1, José Lorenzo wrote:
>
> Can you open a ticket in github about this problem? Make sure you include 
> a description of your associations.
>
> On Wednesday, October 15, 2014 7:29:34 PM UTC+2, Rob Cowie wrote:
>>
>> Hi all, I am attempting to use matching through a deep association, and 
>> am getting the above error message.
>>
>> I baked a sample app to test with, and cant reproduce the problem. here 
>> is the offending code in my controller:
>>
>> $contain_array = [
>> 'Applicants' => [
>> 'Personas'
>> ],
>> 'FinanceCompanies' => [
>> 'Personas'
>> ]
>> ];
>> $propQuery = $this->Proposals->find();
>> $propQuery->contain($contain_array);
>> $propQuery->matching( 'Applicants.Personas', function($q) {
>> return $q->where(['Personas.last_name LIKE' => '%cowie%']);
>> })->all();
>>
>> All my associations appear correct, and this code in a smaller app works 
>> just fine:
>>
>> $query = $this->Articles->find()->
>> contain([
>>  'Posts' => ['Users'],
>>  'Views' => ['Users']
>>  ]
>> );
>> $query->matching('Posts.Users', function ($q){
>> return $q->where(['Users.name' => 'dave']);
>> })->all();
>>
>> Any suggestions?
>>
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error: Cannot use "matching" on "Personas" as there is another association with the same alias

2014-10-15 Thread José Lorenzo
Can you open a ticket in github about this problem? Make sure you include a 
description of your associations.

On Wednesday, October 15, 2014 7:29:34 PM UTC+2, Rob Cowie wrote:
>
> Hi all, I am attempting to use matching through a deep association, and am 
> getting the above error message.
>
> I baked a sample app to test with, and cant reproduce the problem. here is 
> the offending code in my controller:
>
> $contain_array = [
> 'Applicants' => [
> 'Personas'
> ],
> 'FinanceCompanies' => [
> 'Personas'
> ]
> ];
> $propQuery = $this->Proposals->find();
> $propQuery->contain($contain_array);
> $propQuery->matching( 'Applicants.Personas', function($q) {
> return $q->where(['Personas.last_name LIKE' => '%cowie%']);
> })->all();
>
> All my associations appear correct, and this code in a smaller app works 
> just fine:
>
> $query = $this->Articles->find()->
> contain([
>  'Posts' => ['Users'],
>  'Views' => ['Users']
>  ]
> );
> $query->matching('Posts.Users', function ($q){
> return $q->where(['Users.name' => 'dave']);
> })->all();
>
> Any suggestions?
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error menu.ctp

2014-09-10 Thread Bprd Codin
Hi,

Problem resolved

Thank you all

rd

Le mercredi 3 septembre 2014 13:24:58 UTC+2, Bprd Codin a écrit :
>
> Hello,
>
> Problem with my menu.ctp
>
> error message 
>
>1. 
>
>Parse error: syntax error, unexpected 'array' (T_ARRAY), expecting ')' 
>in /app/View/Elements/menu.ctp on line 1
>
>
>
> my menu.ctp
>
>
>1. requestAction(array 
>('controller'=>'pages','action'=>'menu'array 
>('return')));?>
>
>
> and ma controller
>
>
> 
> class PagesController extends AppController {
>
>  public $uses = array('Post');
>
>  function menu(){
>
> $pages = $this-> Post->find('all',array(
>
>'conditions' => array('type'=>'page','online'=>1)
>
> ));
>
> return $pages;
>}
>
>  function show($id = null,$slug = null){
>
>   }
>
> }
> if you have a idéa thank you
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error menu.ctp

2014-09-04 Thread Mike Karthauser

stick a pr($pages) in your menu.ctp.


I bet you'll see the problem then..

you'll find you should have 

$v['Post']['link'];

$v['Post']['name'];

if in doubt, always PR();

On 4 Sep 2014, at 11:47, Deruel Roland  wrote:

> Hi
> 
> this part of my problem is resolv but i dont no  see now the link of the 
> navbar
> 
> but my resuest db is ok
> 
> my menu.ctp
> 
> 
>  $this->requestAction(array('controller'=>'pages','action'=>'menu')); ?>
> 
>   $v): $v =  current($v); ?>
>   Html->link($v['name'],$v['link']); ?>
>   
>   
> 
> 
> my PagesController.php
> 
> 
>  array('Post');  function menu(){
>$pages = $this->Post->find('all',array(
> 'conditions' => array('type'=>'page','online'=>1)
> ));   return $pages;
>   } function show($id = null,$slug = null){
> }
> 
> }
> 
> 
> my Post.php
> 
> 
>  $primary = false ){foreach($data as $k=>$d){  
> if(isset($d['Post']['slug']) && isset($d['Post']['id'])){ 
> $d['Post']['link'] = array(  'controller' => 'pages', 
>  'action' => 'show',  'id' => $d['Post']['id'],   
>'slug'   => $d['Post']['slug']  );
> }  $data[$k] = $d;}   return $data; }
> }
> 
> 
> my default.ctp
> 
> 
>   $this->element('menu'); ?>  
> 
> I normally have to see the result of my request my first page in the 
> navigation bar
> 
> 
> 
> 
> 
> Le mercredi 3 septembre 2014 13:24:58 UTC+2, Bprd Codin a écrit :
> Hello,
> 
> Problem with my menu.ctp
> 
> error message 
> 
> Parse error: syntax error, unexpected 'array' (T_ARRAY), expecting ')' in 
> /app/View/Elements/menu.ctp on line 1
> 
> 
> 
> my menu.ctp
> 
>  $this->requestAction(array('controller'=>'pages','action'=>'menu'array('return')));?>
> 
> and ma controller
> 
> 
>  array('Post');  function menu(){ $pages = $this-> 
> Post->find('all',array('conditions' => 
> array('type'=>'page','online'=>1) )); return $pages;
>}  function show($id = null,$slug = null){   }
> }
> 
> if you have a idéa thank you
> 
> -- 
> 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 
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/d/optout.


Mike Karthäuser
Director, Brightstorm Ltd.

1, Brewery Court
North Street
Bristol
BS3 1JS

mi...@brightstorm.co.uk
www.brightstorm.co.uk
+44(0) 7939252144


-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error menu.ctp

2014-09-04 Thread Deruel Roland
Hi

this part of my problem is resolv but i dont no  see now the link of the 
navbar

but my resuest db is ok

my menu.ctp


requestAction(array('controller'=>'pages','action'=>'
menu')); ?>



  $v): $v =  current($v); ?>

  Html->link($v['name'],$v['link']); ?>

  

  


my PagesController.php


Post->find('all',array(

'conditions' => array('type'=>'page','online'=>1)

   ));

  return $pages;

  }

function show($id = null,$slug = null){

}

}

my Post.php


$d){

 if(isset($d['Post']['slug']) && isset($d['Post']['id'])){

$d['Post']['link'] = array(

 'controller' => 'pages',

 'action' => 'show',

 'id' => $d['Post']['id'],

 'slug'   => $d['Post']['slug']

 ); 

   }   

   $data[$k] = $d;

   }

  return $data;

}

}

my default.ctp


 

   element('menu'); ?>

 

I normally have to see the result of my request my first page in the 
navigation bar




Le mercredi 3 septembre 2014 13:24:58 UTC+2, Bprd Codin a écrit :
>
> Hello,
>
> Problem with my menu.ctp
>
> error message 
>
>1. 
>
>Parse error: syntax error, unexpected 'array' (T_ARRAY), expecting ')' 
>in /app/View/Elements/menu.ctp on line 1
>
>
>
> my menu.ctp
>
>
>1. requestAction(array 
>('controller'=>'pages','action'=>'menu'array 
>('return')));?>
>
>
> and ma controller
>
>
> 
> class PagesController extends AppController {
>
>  public $uses = array('Post');
>
>  function menu(){
>
> $pages = $this-> Post->find('all',array(
>
>'conditions' => array('type'=>'page','online'=>1)
>
> ));
>
> return $pages;
>}
>
>  function show($id = null,$slug = null){
>
>   }
>
> }
> if you have a idéa thank you
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error menu.ctp

2014-09-03 Thread Thomas von Hassel
Your IDE is even marking the error with a red line :)


> On 03 Sep 2014, at 13:24, Bprd Codin  wrote:
> 
> Hello,
> 
> Problem with my menu.ctp
> 
> error message 
> 
> Parse error: syntax error, unexpected 'array' (T_ARRAY), expecting ')' in 
> /app/View/Elements/menu.ctp on line 1
> 
> 
> 
> my menu.ctp
> 
> requestAction(array 
> ('controller'=>'pages','action'=>'menu'array 
> ('return')));?>
> 
> and ma controller
> 
> 
>  array('Post');  function menu(){ $pages = $this-> 
> Post->find('all',array('conditions' => 
> array('type'=>'page','online'=>1) )); return $pages;
>}  function show($id = null,$slug = null){   }
> }
> 
> if you have a idéa thank you
> 
> -- 
> 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 
> "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 cake-php@googlegroups.com 
> .
> Visit this group at http://groups.google.com/group/cake-php 
> .
> For more options, visit https://groups.google.com/d/optout 
> .

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error menu.ctp

2014-09-03 Thread Mike Karthauser
your 
requestAction(array('controller'=>'pages','action'=>'menu'array('return')));?>

is at least missing a comma.



On 3 Sep 2014, at 12:24, Bprd Codin  wrote:

> Hello,
> 
> Problem with my menu.ctp
> 
> error message 
> 
> Parse error: syntax error, unexpected 'array' (T_ARRAY), expecting ')' in 
> /app/View/Elements/menu.ctp on line 1
> 
> 
> 
> my menu.ctp
> 
>  $this->requestAction(array('controller'=>'pages','action'=>'menu'array('return')));?>
> 
> and ma controller
> 
> 
>  array('Post');  function menu(){ $pages = $this-> 
> Post->find('all',array('conditions' => 
> array('type'=>'page','online'=>1) )); return $pages;
>}  function show($id = null,$slug = null){   }
> }
> 
> if you have a idéa thank you
> 
> -- 
> 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 
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/d/optout.


Mike Karthäuser
Director, Brightstorm Ltd.

1, Brewery Court
North Street
Bristol
BS3 1JS

mi...@brightstorm.co.uk
www.brightstorm.co.uk
+44(0) 7939252144


-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error: JsHelper could not be found. CakePHP3

2014-08-27 Thread Jipson Thomas
HI Jose,
Thank you.
Regards,
Jipson

On Wednesday, 27 August 2014 14:59:29 UTC+1, Jipson Thomas wrote:
>
> Hi,
> Is there any alternative for JS helper in cakephp 3? I tried to integrate 
> tinymceditor to my cakephp 3 website based on the tutorial on 
> http://bakery.cakephp.org/articles/galitul/2012/04/11/helper_tinymce_for_cakephp_2
> .
> When I am accessing the form , I get the following error.
> *Error: * *JsHelper* could not be found.
> *Error: * Create the class *JsHelper* below in file: 
> src/View/Helper/JsHelper.php
>
> Would you please help me to fix this?
> Regards,
> Jipson
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error: JsHelper could not be found. CakePHP3

2014-08-27 Thread José Lorenzo
Seems like someone converted it into a plugin:

https://github.com/oldskool/cakephp-js

On Wednesday, August 27, 2014 3:59:29 PM UTC+2, Jipson Thomas wrote:
>
> Hi,
> Is there any alternative for JS helper in cakephp 3? I tried to integrate 
> tinymceditor to my cakephp 3 website based on the tutorial on 
> http://bakery.cakephp.org/articles/galitul/2012/04/11/helper_tinymce_for_cakephp_2
> .
> When I am accessing the form , I get the following error.
> *Error: * *JsHelper* could not be found.
> *Error: * Create the class *JsHelper* below in file: 
> src/View/Helper/JsHelper.php
>
> Would you please help me to fix this?
> Regards,
> Jipson
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Error: Class 'SimplePasswordHasher' not found

2014-01-17 Thread Justin Atack
Make sure your loading the Auth component in the AppController.php

public $components = array(
'Session',
'Auth' => array(
'loginRedirect' => array(
'controller' => 'posts',
'action' => 'index'
),
'logoutRedirect' => array(
'controller' => 'pages',
'action' => 'display',
'home'
)
)
);



I have this in the top of my AppModel

App::uses('AppModel', 'Model');
App::uses('AuthComponent', 'Controller/Component');
App::uses('SimplePasswordHasher', 'Controller/Component/Auth');

On Friday, 17 January 2014 05:17:40 UTC+11, jose cavazos wrote:
>
> Hi all,
>  
> I am receiving this message
>
> * Error:Class 'SimplePasswordHasher' not found *I am following the 
> tutorial 
> http://book.cakephp.org/2.0/en/tutorials-and-examples/blog-auth-example/auth.htmlfor
>  Simple Authentication and Authorization.  I found this thread 
> https://groups.google.com/forum/#!topic/cake-php/wL6f3MG_M8c but it 
> doesn't have an answer for me . Any suggestions?
>
> I have this at top of User.php is models 
> App::uses('SimplePasswordHasher','Controlller/Component/Auth');
>
>
>
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Error: Class 'SimplePasswordHasher' not found

2014-01-14 Thread Justin Atack
Yes i meant User model.

I fixed the problem.

The following does not work
App::uses('AppModel', 'Model', 'SimplePasswordHasher', 
'Controller/Component/Auth');

The following does
App::uses('AppModel', 'Model');
App::uses('SimplePasswordHasher', 'Controller/Component/Auth');

On Saturday, 4 January 2014 00:47:35 UTC+11, Gerben Wartena wrote:
>
> I had exactly the same issue when I did the tutorial, but it had to do 
> with caching/refreshing because suddenly it worked.
> In your case: you do mean the 'User' model; it should not be 'Users'.
> I only have 'App::uses('SimplePasswordHasher', 
> 'Controller/Component/Auth');' and it works just fine.
>
> Op vrijdag 3 januari 2014 06:49:28 UTC+1 schreef Justin Atack:
>
>> Hi All,
>>
>> I hope you can point me in the right direction.
>>
>> I'm following the guide at: 
>> http://book.cakephp.org/2.0/en/tutorials-and-examples/blog-auth-example/auth.html
>>
>> I'm using CakePHP 2.4.3 and have followed the guide to the letter of the 
>> law. It mostly works correctly. If I try to access a controller/action it 
>> redirects as it should to the users/login action... so that's seems fine.
>>
>> The issue is when I try to add a new user at users/add. It throws this 
>> error: Error: Class 'SimplePasswordHasher' not found
>>
>> I have made sure that the following is pasted in the top of the Users 
>> model: App::uses('AppModel', 'Model', 'SimplePasswordHasher', 
>> 'Controller/Component/Auth');
>>
>> I then thought that perhaps this "SimplePasswordHasher" class was a new 
>> thing part of 2.4.4 so I set up another test project to test it and went 
>> through the entire Auth tutorial again with exactly the same results.
>>
>> Where am I going wrong? It there some code missing? 
>>
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Error: Class 'SimplePasswordHasher' not found

2014-01-09 Thread Ivo Wolgensinger
I have the same issue. Then I changed in the Model the App:uses... 
to App::uses('SimplePasswordHasher', 'Controller/Component/Auth'); and it 
works.
But my Problem is, that *only sha1* is working for adding passwords. 
Nothing else. Any ideas?

On Friday, January 3, 2014 6:49:28 AM UTC+1, Justin Atack wrote:
>
> Hi All,
>
> I hope you can point me in the right direction.
>
> I'm following the guide at: 
> http://book.cakephp.org/2.0/en/tutorials-and-examples/blog-auth-example/auth.html
>  
>
> I'm using CakePHP 2.4.3 and have followed the guide to the letter of the 
> law. It mostly works correctly. If I try to access a controller/action it 
> redirects as it should to the users/login action... so that's seems fine.
>
> The issue is when I try to add a new user at users/add. It throws this 
> error: Error: Class 'SimplePasswordHasher' not found
>
> I have made sure that the following is pasted in the top of the Users 
> model: App::uses('AppModel', 'Model', 'SimplePasswordHasher', 
> 'Controller/Component/Auth');
>
> I then thought that perhaps this "SimplePasswordHasher" class was a new 
> thing part of 2.4.4 so I set up another test project to test it and went 
> through the entire Auth tutorial again with exactly the same results.
>
> Where am I going wrong? It there some code missing? 
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Error: Class 'SimplePasswordHasher' not found

2014-01-06 Thread Steven Houldey


On Friday, 3 January 2014 05:49:28 UTC, Justin Atack wrote:
>
> Hi All,
>
> I hope you can point me in the right direction.
>
> I'm following the guide at: 
> http://book.cakephp.org/2.0/en/tutorials-and-examples/blog-auth-example/auth.html
>
> I'm using CakePHP 2.4.3 and have followed the guide to the letter of the 
> law. It mostly works correctly. If I try to access a controller/action it 
> redirects as it should to the users/login action... so that's seems fine.
>
> The issue is when I try to add a new user at users/add. It throws this 
> error: Error: Class 'SimplePasswordHasher' not found
>
> I have made sure that the following is pasted in the top of the Users 
> model: App::uses('AppModel', 'Model', 'SimplePasswordHasher', 
> 'Controller/Component/Auth');
>
> I then thought that perhaps this "SimplePasswordHasher" class was a new 
> thing part of 2.4.4 so I set up another test project to test it and went 
> through the entire Auth tutorial again with exactly the same results.
>
> Where am I going wrong? It there some code missing? 
>


 'App::uses('SimplePasswordHasher', 'Controller/Component/Auth');   ionly 
have this in the User.php and not the Appmodel etc like the other reply 
it started working fine 

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Error: Class 'SimplePasswordHasher' not found

2014-01-05 Thread Ivo Wolgensinger
Have you added this in the Model or in the Controller?

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Error: Class 'SimplePasswordHasher' not found

2014-01-03 Thread Gerben Wartena
I had exactly the same issue when I did the tutorial, but it had to do with 
caching/refreshing because suddenly it worked.
In your case: you do mean the 'User' model; it should not be 'Users'.
I only have 'App::uses('SimplePasswordHasher', 
'Controller/Component/Auth');' and it works just fine.

Op vrijdag 3 januari 2014 06:49:28 UTC+1 schreef Justin Atack:

> Hi All,
>
> I hope you can point me in the right direction.
>
> I'm following the guide at: 
> http://book.cakephp.org/2.0/en/tutorials-and-examples/blog-auth-example/auth.html
>
> I'm using CakePHP 2.4.3 and have followed the guide to the letter of the 
> law. It mostly works correctly. If I try to access a controller/action it 
> redirects as it should to the users/login action... so that's seems fine.
>
> The issue is when I try to add a new user at users/add. It throws this 
> error: Error: Class 'SimplePasswordHasher' not found
>
> I have made sure that the following is pasted in the top of the Users 
> model: App::uses('AppModel', 'Model', 'SimplePasswordHasher', 
> 'Controller/Component/Auth');
>
> I then thought that perhaps this "SimplePasswordHasher" class was a new 
> thing part of 2.4.4 so I set up another test project to test it and went 
> through the entire Auth tutorial again with exactly the same results.
>
> Where am I going wrong? It there some code missing? 
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Error: Index.phpController could not be found

2013-11-25 Thread Yvonne Liu
 I got this error at very beginning. I found out it is just because I 
forgot 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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Error 500 only in Controllers

2013-10-19 Thread Gaurav Matta
Try /index.php/controller/action
If it works ccheck yr .htaccess file
On 18-Oct-2013 3:17 PM, "Damian Kulon"  wrote:

> Hi
> When I move my app to another serwer and open in  controller see error 500.
> Adress / works fine and another serwer works all links.
>
> I think that is version php because on this serwer is 5.2.6 but I need
> 5.2.8. It is possible that lower version generate error 500?
> Maybe something else can generate this error. I can't access to logs.
>
> Thanks for help.
> Sorry for my English
>
> --
> 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
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Error array

2013-08-25 Thread Vanja Dizdarević
Had this issue a trillion times, don't remember the solution... 

- Just thinking out loud, you could extend the *invalidate* method of your 
models or AppModel and somehow collect all the errors to a static var?
- Check the source of FormHelper to see how errors are being collected.

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Error: Mysql requires a database connection

2013-07-28 Thread vikas bose
Hi Harish,

if you want to include this class or *.dll file in your application so I
mention following steps
1. check the phpinfo, is *.dll file or class file available in you *.ini
file or not.
2. if it is there then you might be follow that two steps
 a. ini_set function to include any *.dll or class file.
 b. either open *.ini file and enable it
3. if pdo driver is not in your list then you need to install it and then
access it

Thanks
Vikas Bose


On Fri, Jul 26, 2013 at 2:02 PM, Harish Tewari wrote:

>
>
> i am facing same problem pdo driver is not enabled by godaddy.
>
> --
> 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
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Error: Mysql requires a database connection

2013-07-26 Thread Harish Tewari


i am facing same problem pdo driver is not enabled by godaddy.

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Error using CakeEmail

2013-07-16 Thread sunny
hj, Daniel.
How to you fix.
Can you share with me.
i have a error:
Could not send email. 

*Error: * An Internal Error Has Occurred.
Stack Trace 
   
   - CORE\Cake\Network\Email\MailTransport.php line 
47→ MailTransport->_mail(string, 
   string, string, string, null)  
   - CORE\Cake\Network\Email\CakeEmail.php line 
1077→ 
   MailTransport->send(CakeEmail)  
   - CORE\Cake\Controller\Component\EmailComponent.php line 
347→ 
   CakeEmail->send(string)  
   - APP\Controller\ContactController.php line 
23→ 
   EmailComponent->send(string)  
   - [internal function]  → 
   ContactController->index()  
   - CORE\Cake\Controller\Controller.php line 
486→ 
ReflectionMethod->invokeArgs(ContactController, 
   array)  
   - CORE\Cake\Routing\Dispatcher.php line 
187→ 
   Controller->invokeAction(CakeRequest)  
   - CORE\Cake\Routing\Dispatcher.php line 
162→ Dispatcher->_invoke(ContactController, 
   CakeRequest, CakeResponse)  
   - APP\webroot\index.php line 110  → 
Dispatcher->dispatch(CakeRequest, 
   CakeResponse) 

but i don't know to fix

On Sunday, January 8, 2012 11:29:30 PM UTC+7, Daniel wrote:
>
> Thanks.  I got it working and I didn't need smtpOptions. 
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Error: Mysql requires a database connection

2013-06-20 Thread Raxit
Hi,

I have asked for PDO driver and godaddy is not providing support for it on 
windows hosting. So is there any other way to connect with mysql using 
cakephp without using PDO ? 

Regards,
Raxit
On Tuesday, June 18, 2013 4:56:48 PM UTC+5:30, Raxit wrote:
>
> *Hi,
> *
>
> *I am facing this problem from past 5 days. Didn't find any solution. I 
> have checked connection many times. my team have also checked all the 
> connections with Mysql. File is also present under same path.
> *
>
> *Error: * Confirm you have created the file : app\Config\database.php.
>
> *Notice: * If you want to customize this error message, create 
> app\View\Errors\missing_connection.ctp.
> Stack Trace 
>
>- ROOT\lib\Cake\Model\ConnectionManager.php line 
> 101→
>  
>
> DboSource->__construct(array)
>  
>- ROOT\lib\Cake\Model\Model.php line 
> 3417→
>  
>
> ConnectionManager::getDataSource(string)
>  
>- ROOT\lib\Cake\Model\Model.php line 
> 1083→
>  
>
> Model->setDataSource(string)
>  
>- ROOT\lib\Cake\Model\Model.php line 
> 3443→
>  
>
> Model->setSource(string)
>  
>- ROOT\lib\Cake\Model\Model.php line 
> 2698→
>  
>
> Model->getDataSource()
>  
>- APP\Model\Setting.php line 
> 16→
>  
>
> Model->find(string)
>  
>- APP\Controller\FunfordayController.php line 
> 268→
>  
>
> Setting->updateCache()
>  
>- APP\Controller\FunfordayController.php line 
> 47→
>  
>
> FunfordayController->_loadSettings()
>  
>- [internal 
> function]→
>  
>
> FunfordayController->beforeFilter(CakeEvent)
>  
>- ROOT\lib\Cake\Event\CakeEventManager.php line 
> 246→
>  call_user_func(array, 
>
> CakeEvent)
>  
>- ROOT\lib\Cake\Controller\Controller.php line 
> 670→
>  
>
> CakeEventManager->dispatch(CakeEvent)
>  
>- ROOT\lib\Cake\Routing\Dispatcher.php line 
> 100→
>  
>
> Controller->startupProcess()
>  
>- ROOT\lib\Cake\Routing\Dispatcher.php line 
> 85→
>  Dispatcher->_invoke(FunfordayController, 
>CakeRequest, 
> CakeResponse)
>  
>- APP\webroot\index.php line 
> 94→
>  Dispatcher->dispatch(CakeRequest, 
>
> CakeResponse)
>
>

-- 
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 
"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 cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Error: Mysql requires a database connection

2013-06-19 Thread Raxit
Gaurav,

I did it but result is still same.

Raxit

On Wednesday, June 19, 2013 9:53:02 AM UTC+5:30, gaurav wrote:
>
> Faced same error while migration of project from 1.2 to 2.x. Try clearing 
> cache
>
> /App/temp/cache
> You will find some folders...like model,view etc..dont delete those but 
> delete all files in them..
> On 18-Jun-2013 6:54 PM, "Raxit" > wrote:
>
>>  *Hi,
>> *
>>
>> *I am facing this problem from past 5 days. Didn't find any solution. I 
>> have checked connection many times. my team have also checked all the 
>> connections with Mysql. File is also present under same path.
>> *
>>
>> *Error: * Confirm you have created the file : app\Config\database.php.
>>
>> *Notice: * If you want to customize this error message, create 
>> app\View\Errors\missing_connection.ctp.
>> Stack Trace 
>>
>>- ROOT\lib\Cake\Model\ConnectionManager.php line 
>> 101→
>>  
>>
>> DboSource->__construct(array)
>>  
>>- ROOT\lib\Cake\Model\Model.php line 
>> 3417→
>>  
>>
>> ConnectionManager::getDataSource(string)
>>  
>>- ROOT\lib\Cake\Model\Model.php line 
>> 1083→
>>  
>>
>> Model->setDataSource(string)
>>  
>>- ROOT\lib\Cake\Model\Model.php line 
>> 3443→
>>  
>>
>> Model->setSource(string)
>>  
>>- ROOT\lib\Cake\Model\Model.php line 
>> 2698→
>>  
>>
>> Model->getDataSource()
>>  
>>- APP\Model\Setting.php line 
>> 16→
>>  
>>
>> Model->find(string)
>>  
>>- APP\Controller\FunfordayController.php line 
>> 268→
>>  
>>
>> Setting->updateCache()
>>  
>>- APP\Controller\FunfordayController.php line 
>> 47→
>>  
>>
>> FunfordayController->_loadSettings()
>>  
>>- [internal 
>> function]→
>>  
>>
>> FunfordayController->beforeFilter(CakeEvent)
>>  
>>- ROOT\lib\Cake\Event\CakeEventManager.php line 
>> 246→
>>  call_user_func(array, 
>>
>> CakeEvent)
>>  
>>- ROOT\lib\Cake\Controller\Controller.php line 
>> 670→
>>  
>>
>> CakeEventManager->dispatch(CakeEvent)
>>  
>>- ROOT\lib\Cake\Routing\Dispatcher.php line 
>> 100→
>>  
>>
>> Controller->startupProcess()
>>  
>>- ROOT\lib\Cake\Routing\Dispatcher.php line 
>> 85→
>>  Dispatcher->_invoke(FunfordayController, 
>>CakeRequest, 
>> CakeResponse)
>>  
>>- APP\webroot\index.php line 
>> 94→
>>  Dispatcher->dispatch(CakeRequest, 
>>
>> CakeResponse)
>>  
>>
>>  -- 
>> 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 
>> "CakePHP" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to cake-php+u...@googlegroups.com .
>> To post to this group, send email to cake...@googlegroups.com
>> .
>> Visit this group at http://groups.google.com/group/cake-php.
>> For more options, visit https://grou

Re: Error: Mysql requires a database connection

2013-06-19 Thread Raxit
Eric,

Yes i have created one file to test Mysql connection and it is working 
fine. But when i write my domain name, it directly gives me error of 
missing database connection. I did some research and i found that it is 
using some different path. 

This site is running under apache server. but i want to make it running 
under IIS7.

*
In Apache server output *

*[base] => /funforday
[webroot] => /funforday/

**In IIS server output 

[base] => /funforday/app/webroot/index.php
[webroot] => /funforday/app/webroot/*


So How can i change this path ? I try to change web.config file but result 
is same.

Raxit

On Wednesday, June 19, 2013 8:00:53 AM UTC+5:30, Eric Haskins wrote:
>
> Raxit,
>
>Did you edit the settings to match your User and password for your 
> Mysql instance? Mysql is running?
>
> Eric
>
> On Tuesday, June 18, 2013 12:28:00 PM UTC-4, Raxit wrote:
>>
>> Hi raj kumar,
>>
>> I have added database.php file with same content under config folder 
>> still it gives same error. I am using cake php so it might be reason for 
>> this problem. I have check the mysql connection file under webroot, it is 
>> working perfectly fine but problem occurs when i call index.php.
>>
>> Thanks
>> Raxit
>>
>> On Tuesday, June 18, 2013 8:53:12 PM UTC+5:30, raj kumar Pustela wrote:
>>>
>>> Hi..
>>>  do u have database.php file in your config folder.
>>>  
>>>  If don't create database.php file in your config folder
>>>
>>>   Follow below process .. it's as a simple.
>>>
>>> create the database.php file and past the below code.
>>>
>>> >> class DATABASE_CONFIG {
>>>
>>> public $default = array(
>>> 'datasource' => 'Database/Mysql',
>>> 'persistent' => false,
>>>  'host' => 'localhost',
>>> 'login' => 'root',
>>> 'password' => '',
>>>  'database' => 'test',
>>> 'prefix'=>'zp_',
>>> );
>>> }
>>>
>>>
>>> On Tue, Jun 18, 2013 at 4:56 PM, Raxit  wrote:
>>>
 *Hi,
 *

 *I am facing this problem from past 5 days. Didn't find any solution. 
 I have checked connection many times. my team have also checked all the 
 connections with Mysql. File is also present under same path.
 *

 *Error: * Confirm you have created the file : app\Config\database.php.

 *Notice: * If you want to customize this error message, create 
 app\View\Errors\missing_connection.ctp.
 Stack Trace 

- ROOT\lib\Cake\Model\ConnectionManager.php line 
 101→
  

 DboSource->__construct(array)
  
- ROOT\lib\Cake\Model\Model.php line 
 3417→
  

 ConnectionManager::getDataSource(string)
  
- ROOT\lib\Cake\Model\Model.php line 
 1083→
  

 Model->setDataSource(string)
  
- ROOT\lib\Cake\Model\Model.php line 
 3443→
  

 Model->setSource(string)
  
- ROOT\lib\Cake\Model\Model.php line 
 2698→
  

 Model->getDataSource()
  
- APP\Model\Setting.php line 
 16→
  

 Model->find(string)
  
- APP\Controller\FunfordayController.php line 
 268→
  

 Setting->updateCache()
  
- APP\Controller\FunfordayController.php line 
 47→
  

 FunfordayController->_loadSettings()
  
- [internal 
 function]→
  

 FunfordayController->beforeFilter(CakeEvent)
  
- ROOT\lib\Cake\Event\CakeEventManager.php line 
 246→
  call_user_func(array, 

 CakeEvent)

Re: Error: Mysql requires a database connection

2013-06-18 Thread Gaurav Matta
Faced same error while migration of project from 1.2 to 2.x. Try clearing
cache

/App/temp/cache
You will find some folders...like model,view etc..dont delete those but
delete all files in them..
On 18-Jun-2013 6:54 PM, "Raxit"  wrote:

> *Hi,
> *
>
> *I am facing this problem from past 5 days. Didn't find any solution. I
> have checked connection many times. my team have also checked all the
> connections with Mysql. File is also present under same path.
> *
>
> *Error: * Confirm you have created the file : app\Config\database.php.
>
> *Notice: * If you want to customize this error message, create
> app\View\Errors\missing_connection.ctp.
> Stack Trace
>
>- ROOT\lib\Cake\Model\ConnectionManager.php line 
> 101→
>
> DboSource->__construct(array)
>- ROOT\lib\Cake\Model\Model.php line 
> 3417→
>
> ConnectionManager::getDataSource(string)
>- ROOT\lib\Cake\Model\Model.php line 
> 1083→
>
> Model->setDataSource(string)
>- ROOT\lib\Cake\Model\Model.php line 
> 3443→
>
> Model->setSource(string)
>- ROOT\lib\Cake\Model\Model.php line 
> 2698→
>
> Model->getDataSource()
>- APP\Model\Setting.php line 
> 16→
>
> Model->find(string)
>- APP\Controller\FunfordayController.php line 
> 268→
>
> Setting->updateCache()
>- APP\Controller\FunfordayController.php line 
> 47→
>
> FunfordayController->_loadSettings()
>- [internal 
> function]→
>
> FunfordayController->beforeFilter(CakeEvent)
>- ROOT\lib\Cake\Event\CakeEventManager.php line 
> 246→
>  call_user_func(array,
>
> CakeEvent)
>- ROOT\lib\Cake\Controller\Controller.php line 
> 670→
>
> CakeEventManager->dispatch(CakeEvent)
>- ROOT\lib\Cake\Routing\Dispatcher.php line 
> 100→
>
> Controller->startupProcess()
>- ROOT\lib\Cake\Routing\Dispatcher.php line 
> 85→
>  Dispatcher->_invoke(FunfordayController,
>CakeRequest, 
> CakeResponse)
>- APP\webroot\index.php line 
> 94→
>  Dispatcher->dispatch(CakeRequest,
>
> CakeResponse)
>
>  --
> 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
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
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 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.

Re: Error: Mysql requires a database connection

2013-06-18 Thread Eric Haskins
Raxit,

   Did you edit the settings to match your User and password for your Mysql 
instance? Mysql is running?

Eric

On Tuesday, June 18, 2013 12:28:00 PM UTC-4, Raxit wrote:
>
> Hi raj kumar,
>
> I have added database.php file with same content under config folder still 
> it gives same error. I am using cake php so it might be reason for this 
> problem. I have check the mysql connection file under webroot, it is 
> working perfectly fine but problem occurs when i call index.php.
>
> Thanks
> Raxit
>
> On Tuesday, June 18, 2013 8:53:12 PM UTC+5:30, raj kumar Pustela wrote:
>>
>> Hi..
>>  do u have database.php file in your config folder.
>>  
>>  If don't create database.php file in your config folder
>>
>>   Follow below process .. it's as a simple.
>>
>> create the database.php file and past the below code.
>>
>> > class DATABASE_CONFIG {
>>
>> public $default = array(
>> 'datasource' => 'Database/Mysql',
>> 'persistent' => false,
>>  'host' => 'localhost',
>> 'login' => 'root',
>> 'password' => '',
>>  'database' => 'test',
>> 'prefix'=>'zp_',
>> );
>> }
>>
>>
>> On Tue, Jun 18, 2013 at 4:56 PM, Raxit  wrote:
>>
>>> *Hi,
>>> *
>>>
>>> *I am facing this problem from past 5 days. Didn't find any solution. I 
>>> have checked connection many times. my team have also checked all the 
>>> connections with Mysql. File is also present under same path.
>>> *
>>>
>>> *Error: * Confirm you have created the file : app\Config\database.php.
>>>
>>> *Notice: * If you want to customize this error message, create 
>>> app\View\Errors\missing_connection.ctp.
>>> Stack Trace 
>>>
>>>- ROOT\lib\Cake\Model\ConnectionManager.php line 
>>> 101→
>>>  
>>>
>>> DboSource->__construct(array)
>>>  
>>>- ROOT\lib\Cake\Model\Model.php line 
>>> 3417→
>>>  
>>>
>>> ConnectionManager::getDataSource(string)
>>>  
>>>- ROOT\lib\Cake\Model\Model.php line 
>>> 1083→
>>>  
>>>
>>> Model->setDataSource(string)
>>>  
>>>- ROOT\lib\Cake\Model\Model.php line 
>>> 3443→
>>>  
>>>
>>> Model->setSource(string)
>>>  
>>>- ROOT\lib\Cake\Model\Model.php line 
>>> 2698→
>>>  
>>>
>>> Model->getDataSource()
>>>  
>>>- APP\Model\Setting.php line 
>>> 16→
>>>  
>>>
>>> Model->find(string)
>>>  
>>>- APP\Controller\FunfordayController.php line 
>>> 268→
>>>  
>>>
>>> Setting->updateCache()
>>>  
>>>- APP\Controller\FunfordayController.php line 
>>> 47→
>>>  
>>>
>>> FunfordayController->_loadSettings()
>>>  
>>>- [internal 
>>> function]→
>>>  
>>>
>>> FunfordayController->beforeFilter(CakeEvent)
>>>  
>>>- ROOT\lib\Cake\Event\CakeEventManager.php line 
>>> 246→
>>>  call_user_func(array, 
>>>
>>> CakeEvent)
>>>  
>>>- ROOT\lib\Cake\Controller\Controller.php line 
>>> 670→
>>>  
>>>
>>> CakeEventManager->dispatch(CakeEvent)
>>>  
>>>- ROOT\lib\Cake\Routing\Dispatcher.php line 
>>> 100→
>>>  
>>>
>>> Controller->startupProcess()
>>>  
>>>- ROOT\lib\Cake\Routing\Dispatcher.php line 
>>> 85→
>>>  Dispatcher->_invoke(FunfordayController, 
>>>CakeRequest, 
>>> Cake

Re: Error: Mysql requires a database connection

2013-06-18 Thread Raxit
Hi raj kumar,

I have added database.php file with same content under config folder still 
it gives same error. I am using cake php so it might be reason for this 
problem. I have check the mysql connection file under webroot, it is 
working perfectly fine but problem occurs when i call index.php.

Thanks
Raxit

On Tuesday, June 18, 2013 8:53:12 PM UTC+5:30, raj kumar Pustela wrote:
>
> Hi..
>  do u have database.php file in your config folder.
>  
>  If don't create database.php file in your config folder
>
>   Follow below process .. it's as a simple.
>
> create the database.php file and past the below code.
>
>  class DATABASE_CONFIG {
>
> public $default = array(
> 'datasource' => 'Database/Mysql',
> 'persistent' => false,
>  'host' => 'localhost',
> 'login' => 'root',
> 'password' => '',
>  'database' => 'test',
> 'prefix'=>'zp_',
> );
> }
>
>
> On Tue, Jun 18, 2013 at 4:56 PM, Raxit  >wrote:
>
>> *Hi,
>> *
>>
>> *I am facing this problem from past 5 days. Didn't find any solution. I 
>> have checked connection many times. my team have also checked all the 
>> connections with Mysql. File is also present under same path.
>> *
>>
>> *Error: * Confirm you have created the file : app\Config\database.php.
>>
>> *Notice: * If you want to customize this error message, create 
>> app\View\Errors\missing_connection.ctp.
>> Stack Trace 
>>
>>- ROOT\lib\Cake\Model\ConnectionManager.php line 
>> 101→
>>  
>>
>> DboSource->__construct(array)
>>  
>>- ROOT\lib\Cake\Model\Model.php line 
>> 3417→
>>  
>>
>> ConnectionManager::getDataSource(string)
>>  
>>- ROOT\lib\Cake\Model\Model.php line 
>> 1083→
>>  
>>
>> Model->setDataSource(string)
>>  
>>- ROOT\lib\Cake\Model\Model.php line 
>> 3443→
>>  
>>
>> Model->setSource(string)
>>  
>>- ROOT\lib\Cake\Model\Model.php line 
>> 2698→
>>  
>>
>> Model->getDataSource()
>>  
>>- APP\Model\Setting.php line 
>> 16→
>>  
>>
>> Model->find(string)
>>  
>>- APP\Controller\FunfordayController.php line 
>> 268→
>>  
>>
>> Setting->updateCache()
>>  
>>- APP\Controller\FunfordayController.php line 
>> 47→
>>  
>>
>> FunfordayController->_loadSettings()
>>  
>>- [internal 
>> function]→
>>  
>>
>> FunfordayController->beforeFilter(CakeEvent)
>>  
>>- ROOT\lib\Cake\Event\CakeEventManager.php line 
>> 246→
>>  call_user_func(array, 
>>
>> CakeEvent)
>>  
>>- ROOT\lib\Cake\Controller\Controller.php line 
>> 670→
>>  
>>
>> CakeEventManager->dispatch(CakeEvent)
>>  
>>- ROOT\lib\Cake\Routing\Dispatcher.php line 
>> 100→
>>  
>>
>> Controller->startupProcess()
>>  
>>- ROOT\lib\Cake\Routing\Dispatcher.php line 
>> 85→
>>  Dispatcher->_invoke(FunfordayController, 
>>CakeRequest, 
>> CakeResponse)
>>  
>>- APP\webroot\index.php line 
>> 94→
>>  Dispatcher->dispatch(CakeRequest, 
>>
>> CakeResponse)

Re: Error: Mysql requires a database connection

2013-06-18 Thread raj kumar Pustela
Hi..
 do u have database.php file in your config folder.

 If don't create database.php file in your config folder

  Follow below process .. it's as a simple.

create the database.php file and past the below code.

 'Database/Mysql',
'persistent' => false,
'host' => 'localhost',
'login' => 'root',
'password' => '',
'database' => 'test',
'prefix'=>'zp_',
);
}


On Tue, Jun 18, 2013 at 4:56 PM, Raxit  wrote:

> *Hi,
> *
>
> *I am facing this problem from past 5 days. Didn't find any solution. I
> have checked connection many times. my team have also checked all the
> connections with Mysql. File is also present under same path.
> *
>
> *Error: * Confirm you have created the file : app\Config\database.php.
>
> *Notice: * If you want to customize this error message, create
> app\View\Errors\missing_connection.ctp.
> Stack Trace
>
>- ROOT\lib\Cake\Model\ConnectionManager.php line 
> 101→
>
> DboSource->__construct(array)
>- ROOT\lib\Cake\Model\Model.php line 
> 3417→
>
> ConnectionManager::getDataSource(string)
>- ROOT\lib\Cake\Model\Model.php line 
> 1083→
>
> Model->setDataSource(string)
>- ROOT\lib\Cake\Model\Model.php line 
> 3443→
>
> Model->setSource(string)
>- ROOT\lib\Cake\Model\Model.php line 
> 2698→
>
> Model->getDataSource()
>- APP\Model\Setting.php line 
> 16→
>
> Model->find(string)
>- APP\Controller\FunfordayController.php line 
> 268→
>
> Setting->updateCache()
>- APP\Controller\FunfordayController.php line 
> 47→
>
> FunfordayController->_loadSettings()
>- [internal 
> function]→
>
> FunfordayController->beforeFilter(CakeEvent)
>- ROOT\lib\Cake\Event\CakeEventManager.php line 
> 246→
>  call_user_func(array,
>
> CakeEvent)
>- ROOT\lib\Cake\Controller\Controller.php line 
> 670→
>
> CakeEventManager->dispatch(CakeEvent)
>- ROOT\lib\Cake\Routing\Dispatcher.php line 
> 100→
>
> Controller->startupProcess()
>- ROOT\lib\Cake\Routing\Dispatcher.php line 
> 85→
>  Dispatcher->_invoke(FunfordayController,
>CakeRequest, 
> CakeResponse)
>- APP\webroot\index.php line 
> 94→
>  Dispatcher->dispatch(CakeRequest,
>
> CakeResponse)
>
>  --
> 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
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this messa

Re: Error 406 - Not Acceptable with form

2013-05-19 Thread Robert Gravel
Changed to multipart/form-data   seems to solve issue.


On Sat, May 18, 2013 at 1:55 PM, rockbust  wrote:

>
> I have a form submit problem and looking for a solution.  Receiving a “406
> Not Acceptable” when I submit my form.
>
> I am passing a custom array that sometimes contains 100 or more users. The
> admin needs to select all and register them.  As you can see when the form
> is submitted there could be 1,000 separate elements in the form.
> In doing a little research it seems it is possibly an issue with some
> security feature of the server  (my xampp server does not return the
> error).
> The hosting company is not very helpful.
>
> Solutions please??
> I have come up with one possible solution to paginate the array sent to the
> view. That is a problem in itself because I am using a custom array that
> has
> been manipulated to the max and can not find out how to paginate it? Second
> this requires the admin to load the view and submit it maybe 20+ times to
> register all users. Not a great option..
>
> My form is set up as so.
> admin_add_eligible:
>
> Form->create('Testregistration', array('id' =>
> 'selectForm','action'=>'/add_eligible'));?>
>
>
> Select All  onclick="checkAll(document.getElementById('selectForm'), 'results1',
> this.checked);" />
> 
> 
> 
> 
> 
> 
> 
> 
>
>  $i = 0;
> if(!empty($eligibles)){
> foreach ($eligibles as $user):
> //debug($user);
> $class = null;
> if ($i++ % 2 == 0) {
> $class = ' class="altrow"';
> }
> ?>
> >
>
>  $this->Form->input('User.'.$user['user_id'].'.checked',
> array('type'=>'checkbox', 'multiple' => 'checkbox', 'class' => 'results1',
> 'label'=>false, 'options' => array('Testregistration'.$user['user_id']
> =>'Testregistration'.$user['user_id']))); ?> 
>  
>  
>  
>  
>  $this->Form->input('Bill.'.$user['user_id'].'.create_bill',
> array('label' => false,'type'=>'checkbox','checked'=>true)); ?> 
>  $this->Form->input('Bill.'.$user['user_id'].'.auto_pay',
> array('label' => false,'type'=>'checkbox')); ?> 
>  $this->Form->input('Bill.'.$user['user_id'].'.due_date',
> array('label' => false ,'type'=>'date', 'dateFormat' => 'MDY')); ?> 
>
> Html->link(__('View', true),
> array('controller' =>
> 'users','action' => 'view', $user['user_id'])); ?>
>
> Form->input('school_id', array(
> 'value' => 'hello' ,
> 'type' => 'hidden') );
>
> echo $this->Form->input('Testregistration.'.$user['user_id'].'.program_id',
> array( 'type' => 'hidden', 'value' =>  $user['program_id'] ));
> echo
> $this->Form->input('Testregistration.'.$user['user_id'].'.old_rank_id',
> array( 'type' => 'hidden', 'value' =>  $user['old_rank_id'] ));
> echo $this->Form->input('Testregistration.'.$user['user_id'].'.fee', array(
> 'type' => 'hidden', 'value' =>  $user['fee'] ));
> ?>
>
> 
>
>
>
>
> --
> View this message in context:
> http://cakephp.1045679.n5.nabble.com/Error-406-Not-Acceptable-with-form-tp5714980.html
> Sent from the CakePHP mailing list archive at Nabble.com.
>
> --
> 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
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

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




Re: Error on find on hasAndBelongsToMany relationed models

2013-04-26 Thread Saran Pal
Dear Ciul,

As *Reuben* said  HABTM generally doesn't do a join, but if you want to
joins then you will need to set up an extra table in the database to handle
this relationship.

For more details you can visit here -
http://book.cakephp.org/2.0/en/models/associations-linking-models-together.html#hasandbelongstomany-habtm

Cheers!..

Saran


On Thu, Apr 25, 2013 at 5:49 PM, Reuben  wrote:

> The HABTM generally doesn't do a join.  You would only use a straight find
> when you have conditions for only one of the models.
>
> Alternatives are to use contains, or use join to explicitly define the
> join and the join conditions.  Whilst contains is handy, I usually end up
> going with the join clause, because it matches mostly closely with what I'd
> do, if I was writing straight SQL.
>
> Regards
> Reuben Helms
>
>
> On Thursday, 25 April 2013 02:47:31 UTC+10, Ciul wrote:
>
>> I'm having troubles to restrict a find operation based on a related model
>> field within a hasAndBelongsToMany relationship.
>>
>> *// Wedding Model*
>> *public $hasAndBelongsToMany = array('Guest');*
>> *
>> *
>> *// Guest Model*
>> *public $hasAndBelongsToMany = array('Wedding');*
>> *
>> *
>> *Then, calling in Guest Controller:*
>> *
>> *
>> *// GuestsController Controller*
>> *$this->Guest->find('first', array(*
>> *  'conditions' => array(*
>> *  **  **'Guest.email' => 'te...@test.com',*
>> *  **  **'Wedding.alias' => 'maria-wedding'*
>> *  **),*
>> *  **'recursive' => 1*
>> *);*
>>
>>
>> *ERROR:*
>>
>> Column not found: 1054 Unknown column 'Wedding.alias' in 'where clause'
>>
>> *SQL Query: *SELECT `Guest`.`id`, `Guest`.`created`, `Guest`.`modified`,
>> `Guest`.`name`, `Guest`.`email`, `Guest`.`enabled`, `Guest`.`confirmed`
>>
>> FROM `weddingshare`.`demo_guests` AS `Guest` WHERE `Guest`.`email` = '
>> te...@test.com' AND `Wedding`.`alias` = 'maria-wedding' LIMIT 1
>>
>> I understand it is not event joining tables to make the request.
>>
>> Please, I'd appreciate any help.
>>
>> Regards
>>
>  --
> 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
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

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




Re: Error on find on hasAndBelongsToMany relationed models

2013-04-25 Thread Reuben
The HABTM generally doesn't do a join.  You would only use a straight find 
when you have conditions for only one of the models.  

Alternatives are to use contains, or use join to explicitly define the join 
and the join conditions.  Whilst contains is handy, I usually end up going 
with the join clause, because it matches mostly closely with what I'd do, 
if I was writing straight SQL.

Regards
Reuben Helms

On Thursday, 25 April 2013 02:47:31 UTC+10, Ciul wrote:
>
> I'm having troubles to restrict a find operation based on a related model 
> field within a hasAndBelongsToMany relationship.
>
> *// Wedding Model*
> *public $hasAndBelongsToMany = array('Guest');*
> *
> *
> *// Guest Model*
> *public $hasAndBelongsToMany = array('Wedding');*
> *
> *
> *Then, calling in Guest Controller:*
> *
> *
> *// GuestsController Controller*
> *$this->Guest->find('first', array(*
> *  'conditions' => array(*
> *  **  **'Guest.email' => 'te...@test.com ',*
> *  **  **'Wedding.alias' => 'maria-wedding'*
> *  **),*
> *  **'recursive' => 1*
> *);*
>
>
> *ERROR:*
>
> Column not found: 1054 Unknown column 'Wedding.alias' in 'where clause'
>
> *SQL Query: *SELECT `Guest`.`id`, `Guest`.`created`, `Guest`.`modified`, 
> `Guest`.`name`, `Guest`.`email`, `Guest`.`enabled`, `Guest`.`confirmed`
>
> FROM `weddingshare`.`demo_guests` AS `Guest` WHERE `Guest`.`email` = '
> te...@test.com ' AND `Wedding`.`alias` = 'maria-wedding' 
> LIMIT 1
>
> I understand it is not event joining tables to make the request.
>
> Please, I'd appreciate any help.
>
> Regards
>

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




Re: Error in productive Mode (Debug = 0): Class Security not found

2013-03-14 Thread kaiszy
Hi Euromark,

shame on me...ok. I've ordered the cakephp Book :)

Thanks for your afford (and your 
patiencewith me..).

Best regards,
   Kai.

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




Re: Error in productive Mode (Debug = 0): Class Security not found

2013-03-13 Thread euromark
App::uses() is supposed to be used this way, it only takes two arguments.
Please see the documentation on how to use it.


Am Mittwoch, 13. März 2013 17:02:32 UTC+1 schrieb kaiszy:
>
> Hi Euromakr,
>
> ok..problem solved. Next time i let me more time to understand your email 
> ;)
>
> When i use in my component:
>
> App::uses('Component', 'Controller','Security', 'Utility');
>
> i get the error in debug mode < 1
>
> If i use
>
> App::uses('Security', 'Utility');
> App::uses('Component', 'Controller');
>
> it works in all debug mode.
>
> I cant understand why, but it works ;)
>
> Best regards,
>   Kai.
>
>
>
> Am Mittwoch, 13. März 2013 16:09:22 UTC+1 schrieb euromark:
>>
>> Do not use classes in your files without properly App::uses() them at the 
>> top of your classes
>>
>> In your case
>>
>> App::uses('Security', 'Utility')
>>
>> right after the opening `> for all files where you use the core Security class.
>>
>>
>>
>> Am Mittwoch, 13. März 2013 15:39:22 UTC+1 schrieb kaiszy:
>>>
>>> Hi!
>>>
>>> In my some views and one component i use a method from Security Class 
>>> for encryption and decryption. On my dev-Server (debug > 0) everything 
>>> works fine.
>>>
>>> Today i try to deploy to the Liveserver and set debug to 0. But then i 
>>> get the error:
>>>
>>> 2013-03-13 15:21:04 Error: Fatal Error (1): Class 'Security' not found 
>>> in [/myRootpath/app/View/Campaigns/select.ctp, line 32]
>>> 2013-03-13 15:21:04 Error: [InternalErrorException] Internal Server Error
>>> Request URL: /Campaigns/select
>>> Stack Trace:
>>> #0 /myRootpath/lib/Cake/Error/ErrorHandler.php(183): 
>>> ErrorHandler::handleFatalError(1, 'Class 'Security...', '/myRootpath/...', 
>>> 32)
>>> #1 [internal function]: ErrorHandler::handleError(1, 'Class 
>>> 'Security...', '/myRootpath/...', 32, Array)
>>> #2 /myRootpath/lib/Cake/Core/App.php(926): 
>>> call_user_func('ErrorHandler::h...', 1, 'Class 'Security...', 
>>> '/myRootpath/...', 32, Array)
>>> #3 /myRootpath/lib/Cake/Core/App.php(899): App::_checkFatalError()
>>> #4 [internal function]: App::shutdown()
>>> #5 {main}
>>>
>>> Also when the Component is used i get:
>>>
>>> 2013-03-13 15:34:42 Error: Fatal Error (1): Class 'Security' not found 
>>> in [/myRootpath/app/Controller/Component/cbUtilsComponent.php, line 80]
>>> 2013-03-13 15:34:42 Error: [InternalErrorException] Internal Server Error
>>> Request URL: /Hashimports/add
>>> Stack Trace:
>>> #0 /myRootpath/lib/Cake/Error/ErrorHandler.php(183): 
>>> ErrorHandler::handleFatalError(1, 'Class 'Security...', '/myRootpath/...', 
>>> 80)
>>> #1 [internal function]: ErrorHandler::handleError(1, 'Class 
>>> 'Security...', '/myRootpath/...', 80, Array)
>>> #2 /myRootpath/lib/Cake/Core/App.php(926): 
>>> call_user_func('ErrorHandler::h...', 1, 'Class 'Security...', 
>>> '/myRootpath/...', 80, Array)
>>> #3 /myRootpath/lib/Cake/Core/App.php(899): App::_checkFatalError()
>>> #4 [internal function]: App::shutdown()
>>> #5 {main}
>>>
>>> When i set debug > 0 on Liveserver, everything works (but then i have 
>>> the debugkit toolbar).
>>>
>>> I use cakephp 2.3.0
>>>
>>> Best regards,
>>>   Kai.
>>>   
>>>
>>

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




Re: Error in productive Mode (Debug = 0): Class Security not found

2013-03-13 Thread kaiszy
Hi Euromakr,

ok..problem solved. Next time i let me more time to understand your email ;)

When i use in my component:

App::uses('Component', 'Controller','Security', 'Utility');

i get the error in debug mode < 1

If i use

App::uses('Security', 'Utility');
App::uses('Component', 'Controller');

it works in all debug mode.

I cant understand why, but it works ;)

Best regards,
  Kai.



Am Mittwoch, 13. März 2013 16:09:22 UTC+1 schrieb euromark:
>
> Do not use classes in your files without properly App::uses() them at the 
> top of your classes
>
> In your case
>
> App::uses('Security', 'Utility')
>
> right after the opening ` for all files where you use the core Security class.
>
>
>
> Am Mittwoch, 13. März 2013 15:39:22 UTC+1 schrieb kaiszy:
>>
>> Hi!
>>
>> In my some views and one component i use a method from Security Class for 
>> encryption and decryption. On my dev-Server (debug > 0) everything works 
>> fine.
>>
>> Today i try to deploy to the Liveserver and set debug to 0. But then i 
>> get the error:
>>
>> 2013-03-13 15:21:04 Error: Fatal Error (1): Class 'Security' not found in 
>> [/myRootpath/app/View/Campaigns/select.ctp, line 32]
>> 2013-03-13 15:21:04 Error: [InternalErrorException] Internal Server Error
>> Request URL: /Campaigns/select
>> Stack Trace:
>> #0 /myRootpath/lib/Cake/Error/ErrorHandler.php(183): 
>> ErrorHandler::handleFatalError(1, 'Class 'Security...', '/myRootpath/...', 
>> 32)
>> #1 [internal function]: ErrorHandler::handleError(1, 'Class 
>> 'Security...', '/myRootpath/...', 32, Array)
>> #2 /myRootpath/lib/Cake/Core/App.php(926): 
>> call_user_func('ErrorHandler::h...', 1, 'Class 'Security...', 
>> '/myRootpath/...', 32, Array)
>> #3 /myRootpath/lib/Cake/Core/App.php(899): App::_checkFatalError()
>> #4 [internal function]: App::shutdown()
>> #5 {main}
>>
>> Also when the Component is used i get:
>>
>> 2013-03-13 15:34:42 Error: Fatal Error (1): Class 'Security' not found in 
>> [/myRootpath/app/Controller/Component/cbUtilsComponent.php, line 80]
>> 2013-03-13 15:34:42 Error: [InternalErrorException] Internal Server Error
>> Request URL: /Hashimports/add
>> Stack Trace:
>> #0 /myRootpath/lib/Cake/Error/ErrorHandler.php(183): 
>> ErrorHandler::handleFatalError(1, 'Class 'Security...', '/myRootpath/...', 
>> 80)
>> #1 [internal function]: ErrorHandler::handleError(1, 'Class 
>> 'Security...', '/myRootpath/...', 80, Array)
>> #2 /myRootpath/lib/Cake/Core/App.php(926): 
>> call_user_func('ErrorHandler::h...', 1, 'Class 'Security...', 
>> '/myRootpath/...', 80, Array)
>> #3 /myRootpath/lib/Cake/Core/App.php(899): App::_checkFatalError()
>> #4 [internal function]: App::shutdown()
>> #5 {main}
>>
>> When i set debug > 0 on Liveserver, everything works (but then i have the 
>> debugkit toolbar).
>>
>> I use cakephp 2.3.0
>>
>> Best regards,
>>   Kai.
>>   
>>
>

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




Re: Error in productive Mode (Debug = 0): Class Security not found

2013-03-13 Thread kaiszy
Hi Euromark,

thanks for your answer.

> Do not use classes in your files without properly App::uses() them at the 
top of your classes

As you mention i put the following line in my Component:

  App::uses('Component', 'Controller', "Security", "Utility");

But also with this line in my component i get the "Security Class not 
found" error with debug < 1.

Its seems to be a problem with DebugKit. When i remove loading DebugKit in 
Bootstrap (remove CakePlugin::load('DebugKit'); ) i get the error in all 
debug modeshmmm

Best regards,
  Kai.

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




Re: Error in productive Mode (Debug = 0): Class Security not found

2013-03-13 Thread euromark
Do not use classes in your files without properly App::uses() them at the 
top of your classes

In your case

App::uses('Security', 'Utility')

right after the opening `
> Hi!
>
> In my some views and one component i use a method from Security Class for 
> encryption and decryption. On my dev-Server (debug > 0) everything works 
> fine.
>
> Today i try to deploy to the Liveserver and set debug to 0. But then i get 
> the error:
>
> 2013-03-13 15:21:04 Error: Fatal Error (1): Class 'Security' not found in 
> [/myRootpath/app/View/Campaigns/select.ctp, line 32]
> 2013-03-13 15:21:04 Error: [InternalErrorException] Internal Server Error
> Request URL: /Campaigns/select
> Stack Trace:
> #0 /myRootpath/lib/Cake/Error/ErrorHandler.php(183): 
> ErrorHandler::handleFatalError(1, 'Class 'Security...', '/myRootpath/...', 
> 32)
> #1 [internal function]: ErrorHandler::handleError(1, 'Class 'Security...', 
> '/myRootpath/...', 32, Array)
> #2 /myRootpath/lib/Cake/Core/App.php(926): 
> call_user_func('ErrorHandler::h...', 1, 'Class 'Security...', 
> '/myRootpath/...', 32, Array)
> #3 /myRootpath/lib/Cake/Core/App.php(899): App::_checkFatalError()
> #4 [internal function]: App::shutdown()
> #5 {main}
>
> Also when the Component is used i get:
>
> 2013-03-13 15:34:42 Error: Fatal Error (1): Class 'Security' not found in 
> [/myRootpath/app/Controller/Component/cbUtilsComponent.php, line 80]
> 2013-03-13 15:34:42 Error: [InternalErrorException] Internal Server Error
> Request URL: /Hashimports/add
> Stack Trace:
> #0 /myRootpath/lib/Cake/Error/ErrorHandler.php(183): 
> ErrorHandler::handleFatalError(1, 'Class 'Security...', '/myRootpath/...', 
> 80)
> #1 [internal function]: ErrorHandler::handleError(1, 'Class 'Security...', 
> '/myRootpath/...', 80, Array)
> #2 /myRootpath/lib/Cake/Core/App.php(926): 
> call_user_func('ErrorHandler::h...', 1, 'Class 'Security...', 
> '/myRootpath/...', 80, Array)
> #3 /myRootpath/lib/Cake/Core/App.php(899): App::_checkFatalError()
> #4 [internal function]: App::shutdown()
> #5 {main}
>
> When i set debug > 0 on Liveserver, everything works (but then i have the 
> debugkit toolbar).
>
> I use cakephp 2.3.0
>
> Best regards,
>   Kai.
>   
>

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




Re: Error on Model

2013-02-28 Thread Andras Kende
Thats not a CakePHP but a MySQL error message…
do you enough disk space available on you server ?

Andras Kende


On Feb 28, 2013, at 3:27 AM, rogerbenevento  wrote:

> Hello, sorry my english
> 
> I have a problem that I don't have idea what can be:
> Error: SQLSTATE[HY000]: General error: 126 Incorrect key file for table 
> '/tmp/#sql_405a_0.MYI'; try to repair it
> 
> Somebody can I help me?
> 
> -- 
> 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 
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  

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




Re: error on installation -db config file

2013-02-26 Thread Osgaldor Storm
OMG, I'm s stupid!  I found the whole problem, On my local mysql I 
didn't set up the same user and password I had on my remote machine. 
 Derhh!!  it's fixed now.  Close this thread.  Sorry folks, i'm not a 
newbie, i just make absentminded mistakes.

On Monday, February 25, 2013 6:40:14 PM UTC-6, Osgaldor Storm wrote:
>
> I have just set up a fresh install of Cake, When I set the db credentials, 
> it threw the following fatal error when I browsed to the cake directory.
>
> Fatal Error
>
> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting 
> ')' 
> *File: *C:\wamp\www\Cake\cakephp-2.2.7\app\Config\database.php 
> *Line: *67
>

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




Re: error on installation -db config file

2013-02-26 Thread Osgaldor Storm
I downloaded the debug kit, but i don't know how to install it.

On Tuesday, February 26, 2013 10:39:06 PM UTC-6, Osgaldor Storm wrote:
>
> Your version of PHP is 5.2.8 or higher.
>
> Your tmp directory is writable.
>
> The *FileEngine* is being used for core caching. To change the config 
> edit APP/Config/core.php
>
> Your database configuration file is present.
>
> Cake is NOT able to connect to the database.
>
> Database connection "Mysql" is missing, or could not be created.
> SQLSTATE[28000] [1045] Access denied for user 'root'@'localhost' (using 
> password: YES)
>
> DebugKit is not installed. It will help you inspect and debug different 
> aspects of your application.
> You can install it from github 
>
> On Monday, February 25, 2013 6:40:14 PM UTC-6, Osgaldor Storm wrote:
>>
>> I have just set up a fresh install of Cake, When I set the db 
>> credentials, it threw the following fatal error when I browsed to the cake 
>> directory.
>>
>> Fatal Error
>>
>> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting 
>> ')' 
>> *File: *C:\wamp\www\Cake\cakephp-2.2.7\app\Config\database.php 
>> *Line: *67
>>
>

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




Re: error on installation -db config file

2013-02-26 Thread Osgaldor Storm


Your version of PHP is 5.2.8 or higher.

Your tmp directory is writable.

The *FileEngine* is being used for core caching. To change the config edit 
APP/Config/core.php

Your database configuration file is present.

Cake is NOT able to connect to the database.

Database connection "Mysql" is missing, or could not be created.
SQLSTATE[28000] [1045] Access denied for user 'root'@'localhost' (using 
password: YES)

DebugKit is not installed. It will help you inspect and debug different 
aspects of your application.
You can install it from github 

On Monday, February 25, 2013 6:40:14 PM UTC-6, Osgaldor Storm wrote:
>
> I have just set up a fresh install of Cake, When I set the db credentials, 
> it threw the following fatal error when I browsed to the cake directory.
>
> Fatal Error
>
> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting 
> ')' 
> *File: *C:\wamp\www\Cake\cakephp-2.2.7\app\Config\database.php 
> *Line: *67
>

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




Re: error on installation -db config file

2013-02-26 Thread Osgaldor Storm
Now i have a whole different can of worms.  using the same credentials that 
errored before, i now get a green light on my db config file is present, 
but yellows on  cake could not connect to database, it says it can't find 
the MySQL connection.  i'm developing locally on WAMP, and my db is on 
localhost (I assume).

On Tuesday, February 26, 2013 10:19:38 PM UTC-6, Osgaldor Storm wrote:
>
> Ok, i started over with a brand new install.
>
> On Monday, February 25, 2013 6:40:14 PM UTC-6, Osgaldor Storm wrote:
>>
>> I have just set up a fresh install of Cake, When I set the db 
>> credentials, it threw the following fatal error when I browsed to the cake 
>> directory.
>>
>> Fatal Error
>>
>> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting 
>> ')' 
>> *File: *C:\wamp\www\Cake\cakephp-2.2.7\app\Config\database.php 
>> *Line: *67
>>
>

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




Re: error on installation -db config file

2013-02-26 Thread Osgaldor Storm
Ok, i started over with a brand new install.

On Monday, February 25, 2013 6:40:14 PM UTC-6, Osgaldor Storm wrote:
>
> I have just set up a fresh install of Cake, When I set the db credentials, 
> it threw the following fatal error when I browsed to the cake directory.
>
> Fatal Error
>
> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting 
> ')' 
> *File: *C:\wamp\www\Cake\cakephp-2.2.7\app\Config\database.php 
> *Line: *67
>

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




Re: error on installation -db config file

2013-02-26 Thread Osgaldor Storm
Now that IS strange, i deleted the file and still have the same error.

On Tuesday, February 26, 2013 10:06:27 PM UTC-6, Thiago Belem wrote:
>
> Rename or delete the file and see if the error go away.
>
> --
> Thiago Belem
>
> Enviado pelo celular
> Em 27/02/2013 00:58, "Osgaldor Storm" > 
> escreveu:
>
>> The file is renamed database.php  and I went and got a fresh copy of the 
>> file and the error was the same.  I tried commenting out  that prefix value 
>> and it made no difference.  The fresh copy throws the same error without 
>> any of my config values.
>>
>> On Monday, February 25, 2013 6:40:14 PM UTC-6, Osgaldor Storm wrote:
>>>
>>> I have just set up a fresh install of Cake, When I set the db 
>>> credentials, it threw the following fatal error when I browsed to the cake 
>>> directory.
>>>
>>> Fatal Error
>>>
>>> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting 
>>> ')' 
>>> *File: *C:\wamp\www\Cake\**cakephp-2.2.7\app\Config\**database.php 
>>> *Line: *67
>>>
>>  -- 
>> 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 
>> "CakePHP" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to cake-php+u...@googlegroups.com .
>> To post to this group, send email to cake...@googlegroups.com
>> .
>> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>  
>>  
>>
>

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




Re: error on installation -db config file

2013-02-26 Thread Thiago Belem
Rename or delete the file and see if the error go away.

--
Thiago Belem

Enviado pelo celular
Em 27/02/2013 00:58, "Osgaldor Storm"  escreveu:

> The file is renamed database.php  and I went and got a fresh copy of the
> file and the error was the same.  I tried commenting out  that prefix value
> and it made no difference.  The fresh copy throws the same error without
> any of my config values.
>
> On Monday, February 25, 2013 6:40:14 PM UTC-6, Osgaldor Storm wrote:
>>
>> I have just set up a fresh install of Cake, When I set the db
>> credentials, it threw the following fatal error when I browsed to the cake
>> directory.
>>
>> Fatal Error
>>
>> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting
>> ')'
>> *File: *C:\wamp\www\Cake\**cakephp-2.2.7\app\Config\**database.php
>> *Line: *67
>>
>  --
> 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
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

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




Re: error on installation -db config file

2013-02-26 Thread Osgaldor Storm
The file is renamed database.php  and I went and got a fresh copy of the 
file and the error was the same.  I tried commenting out  that prefix value 
and it made no difference.  The fresh copy throws the same error without 
any of my config values.

On Monday, February 25, 2013 6:40:14 PM UTC-6, Osgaldor Storm wrote:
>
> I have just set up a fresh install of Cake, When I set the db credentials, 
> it threw the following fatal error when I browsed to the cake directory.
>
> Fatal Error
>
> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting 
> ')' 
> *File: *C:\wamp\www\Cake\cakephp-2.2.7\app\Config\database.php 
> *Line: *67
>

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




Re: error on installation -db config file

2013-02-26 Thread Thiago Belem
I would say the problem is here:

'prefix' => '',);

Please, try again with the default database.php.default renamed to
database.php without altering anything.

--
***Thiago Belem*
Desenvolvedor
Rio de Janeiro - RJ - Brasil

*Assando Sites* - Curso online de *CakePHP*
assando-sites.com.br 

thiagobelem.net
cont...@thiagobelem.net

*Skype / gTalk **»* thiago.belem.web
*LinkedIn* *»* br.linkedin.com/in/thiagobelem/pt


On Wed, Feb 27, 2013 at 12:41 AM, Osgaldor Storm  wrote:

> ok, I updated it with the whole file Thiago.
>
>
> On Tuesday, February 26, 2013 9:36:43 PM UTC-6, Thiago Belem wrote:
>
>> There's the } from the class definition? That's why I asked for the whole
>> file.
>>
>> Maybe there's something wrong with your password? It contains ' ?
>>
>> And what about your PHP version?
>>
>> --
>> ***Thiago Belem*
>> Desenvolvedor
>> Rio de Janeiro - RJ - Brasil
>>
>> *Assando Sites* - Curso online de *CakePHP*
>> assando-sites.com.br 
>>
>> thiagobelem.net
>>
>> con...@thiagobelem.net
>>
>> *Skype / gTalk **»* thiago.belem.web
>> *LinkedIn* *»* 
>> br.linkedin.com/in/**thiagobelem/pt
>>
>>
>> On Wed, Feb 27, 2013 at 12:21 AM, Osgaldor Storm wrote:
>>
>>> https://gist.github.com/**osgaldor/5044721
>>>
>>>
>>> On Tuesday, February 26, 2013 8:47:24 PM UTC-6, Thiago Belem wrote:
>>>
 Please, copy the content of the file to: https://gist.github.com/ and
 post the link here.

 --
 ***Thiago Belem*
 Desenvolvedor
 Rio de Janeiro - RJ - Brasil

 *Assando Sites* - Curso online de *CakePHP*
 assando-sites.com.br 

 thiagobelem.net
 con...@thiagobelem.net


 *Skype / gTalk **»* thiago.belem.web
 *LinkedIn* *»* 
 br.linkedin.com/in/**thiagobelem**/pt


 On Tue, Feb 26, 2013 at 11:44 PM, Osgaldor Storm wrote:

> Yes, I read the message but this is in code written by the Cake team,
> it doesn't make sense that it wants a closing parenthesis because it's
> right in the middle of a long, multi-line array definition.  Look in your
> own copy of the code at that point.  That's not user code, that's just the
> place where we plug in our own database variables.  i'm used to dealing
> with code Igniter, but I'm new to Cake.
>
> On Tuesday, February 26, 2013 4:40:15 PM UTC-6, AD7six wrote:
>>
>> Did you cheat and read the error message =)?
>>
>> On Tuesday, 26 February 2013 21:12:31 UTC+1, Jeremy Burns wrote:
>>>
>>> It's just a wild guess, but I reckon you are missing a closing
>>> bracket on line 67 of /app/Config/database.php
>>>
>>> Jeremy Burns
>>> Class Outfit
>>>
>>> http://www.classoutfit.com
>>>
>>> On 26 Feb 2013, at 00:40:14, Osgaldor Storm 
>>> wrote:
>>>
>>> I have just set up a fresh install of Cake, When I set the db
>>> credentials, it threw the following fatal error when I browsed to the 
>>> cake
>>> directory.
>>>
>>> Fatal Error
>>>
>>> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING,
>>> expecting ')'
>>> *File: *C:\wamp\www\Cake\**cakephp-2.2.7\app\Config\**database.php
>>>
>>> *Line: *67
>>>
>>> --
>>> 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 "CakePHP" group.
>>> To unsubscribe from this group and stop receiving emails from it,
>>> send an email to cake-php+u...@googlegroups.com**.
>>> To post to this group, send email to cake...@googlegroups.com.
>>> Visit this group at http://groups.google.com/**group
>>> /cake-php?hl=en .
>>> For more options, visit https://groups.google.com/**grou
>>> ps/opt_out .
>>>
>>>
>>>
>>>
>>>  --
> Like Us on FaceBook 
> https://www.facebook.com/**CakeP**HP
> Find us on Twitter http://twitter.com/CakePHP
>
> ---
> 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+u...@**googlegroups.com**.
> To post to this group, send email to cake...@googlegroups.com.
> Visit this group at 
> http://groups.google.com/**group**/cake-php?hl=en
> .
> For more options, visit 
> https://groups.google.com/**grou**ps/opt_out
> .
>
>
>

  --
>>> Lik

Re: error on installation -db config file

2013-02-26 Thread Osgaldor Storm
password contains only letters and numbers, no '  php version is 5.2.8

On Tuesday, February 26, 2013 9:36:43 PM UTC-6, Thiago Belem wrote:
>
> There's the } from the class definition? That's why I asked for the whole 
> file.
>
> Maybe there's something wrong with your password? It contains ' ?
>
> And what about your PHP version?
>
> --
> ***Thiago Belem*
> Desenvolvedor
> Rio de Janeiro - RJ - Brasil
>
> *Assando Sites* - Curso online de *CakePHP*
> assando-sites.com.br 
>
> thiagobelem.net
> con...@thiagobelem.net 
>
> *Skype / gTalk **»* thiago.belem.web
> *LinkedIn* *»* br.linkedin.com/in/thiagobelem/pt
>  
>
> On Wed, Feb 27, 2013 at 12:21 AM, Osgaldor Storm 
> 
> > wrote:
>
>> https://gist.github.com/osgaldor/5044721
>>
>>
>> On Tuesday, February 26, 2013 8:47:24 PM UTC-6, Thiago Belem wrote:
>>
>>> Please, copy the content of the file to: https://gist.github.com/ and 
>>> post the link here.
>>>
>>> --
>>> ***Thiago Belem*
>>> Desenvolvedor
>>> Rio de Janeiro - RJ - Brasil
>>>
>>> *Assando Sites* - Curso online de *CakePHP*
>>> assando-sites.com.br 
>>>
>>> thiagobelem.net
>>> con...@thiagobelem.net
>>>
>>>
>>> *Skype / gTalk **»* thiago.belem.web
>>> *LinkedIn* *»* 
>>> br.linkedin.com/in/**thiagobelem/pt
>>>  
>>>
>>> On Tue, Feb 26, 2013 at 11:44 PM, Osgaldor Storm wrote:
>>>
 Yes, I read the message but this is in code written by the Cake team, 
 it doesn't make sense that it wants a closing parenthesis because it's 
 right in the middle of a long, multi-line array definition.  Look in your 
 own copy of the code at that point.  That's not user code, that's just the 
 place where we plug in our own database variables.  i'm used to dealing 
 with code Igniter, but I'm new to Cake.

 On Tuesday, February 26, 2013 4:40:15 PM UTC-6, AD7six wrote:
>
> Did you cheat and read the error message =)?
>
> On Tuesday, 26 February 2013 21:12:31 UTC+1, Jeremy Burns wrote:
>>
>> It's just a wild guess, but I reckon you are missing a closing 
>> bracket on line 67 of /app/Config/database.php
>>  
>> Jeremy Burns
>> Class Outfit
>>
>> http://www.classoutfit.com 
>>
>> On 26 Feb 2013, at 00:40:14, Osgaldor Storm  
>> wrote:
>>
>> I have just set up a fresh install of Cake, When I set the db 
>> credentials, it threw the following fatal error when I browsed to the 
>> cake 
>> directory.
>>
>> Fatal Error
>>
>> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, 
>> expecting ')' 
>> *File: *C:\wamp\www\Cake\**cakephp**-2.2.7\app\Config\**database.php 
>> *Line: *67
>>
>> -- 
>> Like Us on FaceBook 
>> https://www.facebook.com/**CakeP**HP
>> Find us on Twitter http://twitter.com/CakePHP
>>  
>> --- 
>> 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+u...@googlegroups.com.
>> To post to this group, send email to cake...@googlegroups.com.
>> Visit this group at 
>> http://groups.google.com/**group**/cake-php?hl=en
>> .
>> For more options, visit 
>> https://groups.google.com/**grou**ps/opt_out
>> .
>>  
>>  
>>
>>
>>  -- 
 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 "CakePHP" group.
 To unsubscribe from this group and stop receiving emails from it, send 
 an email to cake-php+u...@**googlegroups.com.
 To post to this group, send email to cake...@googlegroups.com.
 Visit this group at 
 http://groups.google.com/**group/cake-php?hl=en
 .
 For more options, visit 
 https://groups.google.com/**groups/opt_out
 .
  
  

>>>
>>>  -- 
>> 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 
>> "CakePHP" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to cake-php+u...@googlegroups.com .
>> To post to this group, send email to cake...@googlegroups.com
>> .
>> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>  
>>  
>>
>
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 

Re: error on installation -db config file

2013-02-26 Thread Osgaldor Storm
ok, I updated it with the whole file Thiago.

On Tuesday, February 26, 2013 9:36:43 PM UTC-6, Thiago Belem wrote:
>
> There's the } from the class definition? That's why I asked for the whole 
> file.
>
> Maybe there's something wrong with your password? It contains ' ?
>
> And what about your PHP version?
>
> --
> ***Thiago Belem*
> Desenvolvedor
> Rio de Janeiro - RJ - Brasil
>
> *Assando Sites* - Curso online de *CakePHP*
> assando-sites.com.br 
>
> thiagobelem.net
> con...@thiagobelem.net 
>
> *Skype / gTalk **»* thiago.belem.web
> *LinkedIn* *»* br.linkedin.com/in/thiagobelem/pt
>  
>
> On Wed, Feb 27, 2013 at 12:21 AM, Osgaldor Storm 
> 
> > wrote:
>
>> https://gist.github.com/osgaldor/5044721
>>
>>
>> On Tuesday, February 26, 2013 8:47:24 PM UTC-6, Thiago Belem wrote:
>>
>>> Please, copy the content of the file to: https://gist.github.com/ and 
>>> post the link here.
>>>
>>> --
>>> ***Thiago Belem*
>>> Desenvolvedor
>>> Rio de Janeiro - RJ - Brasil
>>>
>>> *Assando Sites* - Curso online de *CakePHP*
>>> assando-sites.com.br 
>>>
>>> thiagobelem.net
>>> con...@thiagobelem.net
>>>
>>>
>>> *Skype / gTalk **»* thiago.belem.web
>>> *LinkedIn* *»* 
>>> br.linkedin.com/in/**thiagobelem/pt
>>>  
>>>
>>> On Tue, Feb 26, 2013 at 11:44 PM, Osgaldor Storm wrote:
>>>
 Yes, I read the message but this is in code written by the Cake team, 
 it doesn't make sense that it wants a closing parenthesis because it's 
 right in the middle of a long, multi-line array definition.  Look in your 
 own copy of the code at that point.  That's not user code, that's just the 
 place where we plug in our own database variables.  i'm used to dealing 
 with code Igniter, but I'm new to Cake.

 On Tuesday, February 26, 2013 4:40:15 PM UTC-6, AD7six wrote:
>
> Did you cheat and read the error message =)?
>
> On Tuesday, 26 February 2013 21:12:31 UTC+1, Jeremy Burns wrote:
>>
>> It's just a wild guess, but I reckon you are missing a closing 
>> bracket on line 67 of /app/Config/database.php
>>  
>> Jeremy Burns
>> Class Outfit
>>
>> http://www.classoutfit.com 
>>
>> On 26 Feb 2013, at 00:40:14, Osgaldor Storm  
>> wrote:
>>
>> I have just set up a fresh install of Cake, When I set the db 
>> credentials, it threw the following fatal error when I browsed to the 
>> cake 
>> directory.
>>
>> Fatal Error
>>
>> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, 
>> expecting ')' 
>> *File: *C:\wamp\www\Cake\**cakephp**-2.2.7\app\Config\**database.php 
>> *Line: *67
>>
>> -- 
>> Like Us on FaceBook 
>> https://www.facebook.com/**CakeP**HP
>> Find us on Twitter http://twitter.com/CakePHP
>>  
>> --- 
>> 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+u...@googlegroups.com.
>> To post to this group, send email to cake...@googlegroups.com.
>> Visit this group at 
>> http://groups.google.com/**group**/cake-php?hl=en
>> .
>> For more options, visit 
>> https://groups.google.com/**grou**ps/opt_out
>> .
>>  
>>  
>>
>>
>>  -- 
 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 "CakePHP" group.
 To unsubscribe from this group and stop receiving emails from it, send 
 an email to cake-php+u...@**googlegroups.com.
 To post to this group, send email to cake...@googlegroups.com.
 Visit this group at 
 http://groups.google.com/**group/cake-php?hl=en
 .
 For more options, visit 
 https://groups.google.com/**groups/opt_out
 .
  
  

>>>
>>>  -- 
>> 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 
>> "CakePHP" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to cake-php+u...@googlegroups.com .
>> To post to this group, send email to cake...@googlegroups.com
>> .
>> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>  
>>  
>>
>
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message

Re: error on installation -db config file

2013-02-26 Thread Thiago Belem
There's the } from the class definition? That's why I asked for the whole
file.

Maybe there's something wrong with your password? It contains ' ?

And what about your PHP version?

--
***Thiago Belem*
Desenvolvedor
Rio de Janeiro - RJ - Brasil

*Assando Sites* - Curso online de *CakePHP*
assando-sites.com.br 

thiagobelem.net
cont...@thiagobelem.net

*Skype / gTalk **»* thiago.belem.web
*LinkedIn* *»* br.linkedin.com/in/thiagobelem/pt


On Wed, Feb 27, 2013 at 12:21 AM, Osgaldor Storm  wrote:

> https://gist.github.com/osgaldor/5044721
>
>
> On Tuesday, February 26, 2013 8:47:24 PM UTC-6, Thiago Belem wrote:
>
>> Please, copy the content of the file to: https://gist.github.com/ and
>> post the link here.
>>
>> --
>> ***Thiago Belem*
>> Desenvolvedor
>> Rio de Janeiro - RJ - Brasil
>>
>> *Assando Sites* - Curso online de *CakePHP*
>> assando-sites.com.br 
>>
>> thiagobelem.net
>> con...@thiagobelem.net
>>
>>
>> *Skype / gTalk **»* thiago.belem.web
>> *LinkedIn* *»* 
>> br.linkedin.com/in/**thiagobelem/pt
>>
>>
>> On Tue, Feb 26, 2013 at 11:44 PM, Osgaldor Storm wrote:
>>
>>> Yes, I read the message but this is in code written by the Cake team, it
>>> doesn't make sense that it wants a closing parenthesis because it's right
>>> in the middle of a long, multi-line array definition.  Look in your own
>>> copy of the code at that point.  That's not user code, that's just the
>>> place where we plug in our own database variables.  i'm used to dealing
>>> with code Igniter, but I'm new to Cake.
>>>
>>> On Tuesday, February 26, 2013 4:40:15 PM UTC-6, AD7six wrote:

 Did you cheat and read the error message =)?

 On Tuesday, 26 February 2013 21:12:31 UTC+1, Jeremy Burns wrote:
>
> It's just a wild guess, but I reckon you are missing a closing bracket
> on line 67 of /app/Config/database.php
>
> Jeremy Burns
> Class Outfit
>
> http://www.classoutfit.com
>
> On 26 Feb 2013, at 00:40:14, Osgaldor Storm  wrote:
>
> I have just set up a fresh install of Cake, When I set the db
> credentials, it threw the following fatal error when I browsed to the cake
> directory.
>
> Fatal Error
>
> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING,
> expecting ')'
> *File: *C:\wamp\www\Cake\**cakephp**-2.2.7\app\Config\**database.php
> *Line: *67
>
> --
> Like Us on FaceBook 
> https://www.facebook.com/**CakeP**HP
> Find us on Twitter http://twitter.com/CakePHP
>
> ---
> 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+u...@googlegroups.com.
> To post to this group, send email to cake...@googlegroups.com.
> Visit this group at 
> http://groups.google.com/**group**/cake-php?hl=en
> .
> For more options, visit 
> https://groups.google.com/**grou**ps/opt_out
> .
>
>
>
>
>  --
>>> 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 "CakePHP" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to cake-php+u...@**googlegroups.com.
>>> To post to this group, send email to cake...@googlegroups.com.
>>> Visit this group at 
>>> http://groups.google.com/**group/cake-php?hl=en
>>> .
>>> For more options, visit 
>>> https://groups.google.com/**groups/opt_out
>>> .
>>>
>>>
>>>
>>
>>  --
> 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
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

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

Re: error on installation -db config file

2013-02-26 Thread Osgaldor Storm
https://gist.github.com/osgaldor/5044721

On Tuesday, February 26, 2013 8:47:24 PM UTC-6, Thiago Belem wrote:
>
> Please, copy the content of the file to: https://gist.github.com/ and 
> post the link here.
>
> --
> ***Thiago Belem*
> Desenvolvedor
> Rio de Janeiro - RJ - Brasil
>
> *Assando Sites* - Curso online de *CakePHP*
> assando-sites.com.br 
>
> thiagobelem.net
> con...@thiagobelem.net 
>
> *Skype / gTalk **»* thiago.belem.web
> *LinkedIn* *»* br.linkedin.com/in/thiagobelem/pt
>  
>
> On Tue, Feb 26, 2013 at 11:44 PM, Osgaldor Storm 
> 
> > wrote:
>
>> Yes, I read the message but this is in code written by the Cake team, it 
>> doesn't make sense that it wants a closing parenthesis because it's right 
>> in the middle of a long, multi-line array definition.  Look in your own 
>> copy of the code at that point.  That's not user code, that's just the 
>> place where we plug in our own database variables.  i'm used to dealing 
>> with code Igniter, but I'm new to Cake.
>>
>> On Tuesday, February 26, 2013 4:40:15 PM UTC-6, AD7six wrote:
>>>
>>> Did you cheat and read the error message =)?
>>>
>>> On Tuesday, 26 February 2013 21:12:31 UTC+1, Jeremy Burns wrote:

 It's just a wild guess, but I reckon you are missing a closing bracket 
 on line 67 of /app/Config/database.php
  
 Jeremy Burns
 Class Outfit

 http://www.classoutfit.com 

 On 26 Feb 2013, at 00:40:14, Osgaldor Storm  wrote:

 I have just set up a fresh install of Cake, When I set the db 
 credentials, it threw the following fatal error when I browsed to the cake 
 directory.

 Fatal Error

 *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, 
 expecting ')' 
 *File: *C:\wamp\www\Cake\**cakephp-2.2.7\app\Config\**database.php 
 *Line: *67

 -- 
 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 "CakePHP" group.
 To unsubscribe from this group and stop receiving emails from it, send 
 an email to cake-php+u...@googlegroups.com**.
 To post to this group, send email to cake...@googlegroups.com.
 Visit this group at 
 http://groups.google.com/**group/cake-php?hl=en
 .
 For more options, visit 
 https://groups.google.com/**groups/opt_out
 .
  
  


  -- 
>> 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 
>> "CakePHP" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to cake-php+u...@googlegroups.com .
>> To post to this group, send email to cake...@googlegroups.com
>> .
>> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>  
>>  
>>
>
>

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




Re: error on installation -db config file

2013-02-26 Thread Thiago Belem
Please, copy the content of the file to: https://gist.github.com/ and post
the link here.

--
***Thiago Belem*
Desenvolvedor
Rio de Janeiro - RJ - Brasil

*Assando Sites* - Curso online de *CakePHP*
assando-sites.com.br 

thiagobelem.net
cont...@thiagobelem.net

*Skype / gTalk **»* thiago.belem.web
*LinkedIn* *»* br.linkedin.com/in/thiagobelem/pt


On Tue, Feb 26, 2013 at 11:44 PM, Osgaldor Storm  wrote:

> Yes, I read the message but this is in code written by the Cake team, it
> doesn't make sense that it wants a closing parenthesis because it's right
> in the middle of a long, multi-line array definition.  Look in your own
> copy of the code at that point.  That's not user code, that's just the
> place where we plug in our own database variables.  i'm used to dealing
> with code Igniter, but I'm new to Cake.
>
> On Tuesday, February 26, 2013 4:40:15 PM UTC-6, AD7six wrote:
>>
>> Did you cheat and read the error message =)?
>>
>> On Tuesday, 26 February 2013 21:12:31 UTC+1, Jeremy Burns wrote:
>>>
>>> It's just a wild guess, but I reckon you are missing a closing bracket
>>> on line 67 of /app/Config/database.php
>>>
>>> Jeremy Burns
>>> Class Outfit
>>>
>>> http://www.classoutfit.com
>>>
>>> On 26 Feb 2013, at 00:40:14, Osgaldor Storm  wrote:
>>>
>>> I have just set up a fresh install of Cake, When I set the db
>>> credentials, it threw the following fatal error when I browsed to the cake
>>> directory.
>>>
>>> Fatal Error
>>>
>>> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting
>>> ')'
>>> *File: *C:\wamp\www\Cake\**cakephp-2.2.7\app\Config\**database.php
>>> *Line: *67
>>>
>>> --
>>> 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 "CakePHP" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to cake-php+u...@googlegroups.com**.
>>> To post to this group, send email to cake...@googlegroups.com.
>>> Visit this group at 
>>> http://groups.google.com/**group/cake-php?hl=en
>>> .
>>> For more options, visit 
>>> https://groups.google.com/**groups/opt_out
>>> .
>>>
>>>
>>>
>>>
>>>  --
> 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
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

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




Re: error on installation -db config file

2013-02-26 Thread Osgaldor Storm
Yes, I read the message but this is in code written by the Cake team, it 
doesn't make sense that it wants a closing parenthesis because it's right 
in the middle of a long, multi-line array definition.  Look in your own 
copy of the code at that point.  That's not user code, that's just the 
place where we plug in our own database variables.  i'm used to dealing 
with code Igniter, but I'm new to Cake.

On Tuesday, February 26, 2013 4:40:15 PM UTC-6, AD7six wrote:
>
> Did you cheat and read the error message =)?
>
> On Tuesday, 26 February 2013 21:12:31 UTC+1, Jeremy Burns wrote:
>>
>> It's just a wild guess, but I reckon you are missing a closing bracket on 
>> line 67 of /app/Config/database.php
>>
>> Jeremy Burns
>> Class Outfit
>>
>> http://www.classoutfit.com 
>>
>> On 26 Feb 2013, at 00:40:14, Osgaldor Storm  wrote:
>>
>> I have just set up a fresh install of Cake, When I set the db 
>> credentials, it threw the following fatal error when I browsed to the cake 
>> directory.
>>
>> Fatal Error
>>
>> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting 
>> ')' 
>> *File: *C:\wamp\www\Cake\cakephp-2.2.7\app\Config\database.php 
>> *Line: *67
>>
>> -- 
>> 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 
>> "CakePHP" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to cake-php+u...@googlegroups.com.
>> To post to this group, send email to cake...@googlegroups.com.
>> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>  
>>  
>>
>>
>>

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




Re: error on installation -db config file

2013-02-26 Thread Osgaldor Storm
That line is in the middle of an array definition.  If i put in the closing 
parenthesis, it will leave out some values from the array being defined. 
 This is out-of-the-box code  from Cake, not my code.

On Tuesday, February 26, 2013 2:12:31 PM UTC-6, Jeremy Burns wrote:
>
> It's just a wild guess, but I reckon you are missing a closing bracket on 
> line 67 of /app/Config/database.php
>
> Jeremy Burns
> Class Outfit
>
> http://www.classoutfit.com 
>
> On 26 Feb 2013, at 00:40:14, Osgaldor Storm > 
> wrote:
>
> I have just set up a fresh install of Cake, When I set the db credentials, 
> it threw the following fatal error when I browsed to the cake directory.
>
> Fatal Error
>
> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting 
> ')' 
> *File: *C:\wamp\www\Cake\cakephp-2.2.7\app\Config\database.php 
> *Line: *67
>
> -- 
> 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 
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to cake-php+u...@googlegroups.com .
> To post to this group, send email to cake...@googlegroups.com
> .
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  
>
>
>

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




Re: error on installation -db config file

2013-02-26 Thread AD7six
Did you cheat and read the error message =)?

On Tuesday, 26 February 2013 21:12:31 UTC+1, Jeremy Burns wrote:
>
> It's just a wild guess, but I reckon you are missing a closing bracket on 
> line 67 of /app/Config/database.php
>
> Jeremy Burns
> Class Outfit
>
> http://www.classoutfit.com 
>
> On 26 Feb 2013, at 00:40:14, Osgaldor Storm > 
> wrote:
>
> I have just set up a fresh install of Cake, When I set the db credentials, 
> it threw the following fatal error when I browsed to the cake directory.
>
> Fatal Error
>
> *Error: *syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting 
> ')' 
> *File: *C:\wamp\www\Cake\cakephp-2.2.7\app\Config\database.php 
> *Line: *67
>
> -- 
> 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 
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to cake-php+u...@googlegroups.com .
> To post to this group, send email to cake...@googlegroups.com
> .
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  
>
>
>

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




Re: error on installation -db config file

2013-02-26 Thread Jeremy Burns | Class Outfit
It's just a wild guess, but I reckon you are missing a closing bracket on line 
67 of /app/Config/database.php

Jeremy Burns
Class Outfit

http://www.classoutfit.com

On 26 Feb 2013, at 00:40:14, Osgaldor Storm  wrote:

> I have just set up a fresh install of Cake, When I set the db credentials, it 
> threw the following fatal error when I browsed to the cake directory.
> 
> Fatal Error
> Error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ')' 
> File: C:\wamp\www\Cake\cakephp-2.2.7\app\Config\database.php  
> Line: 67
> 
> 
> -- 
> 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 
> "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 cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  

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




Re: Error: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; But execute is trying to use function name as the $sql

2012-12-05 Thread lowpass
Cake can't find your ShooterOption class. Are you sure the file is
named ShooterOption.php?

Delete everything in app/tmp/cache/models/ directory.

On Tue, Dec 4, 2012 at 1:11 PM, glk  wrote:
> Hello all,  thank you in advance for any help you may be able to provide.
>
> I'm using cakePHP 2.2.1
>
> The following code works perfectly:
>
>   class OptionsController extends AppController {
> var $uses = array('Option', 'ShooterEvent', 'ShooterOption');
>
> public function calc($id) {
>   $paid_entries = $this->ShooterEvent->getPaidEntries($event_id);
>   $paid_options = $this->ShooterOption->find('all');
>
>   $something =  'Default answer';
>
>   $this->set(compact('paid_entries', 'something', 'paid_options'));
> }
>
>
>  The following change will die horribly:
>
>   // Made to class above
>   $something =  'Default answer';
>  $something = $this->ShooterOption->getSomething(1);
>
> // Made to the ShooterOption class
> class ShooterOption extends AppModel {
>   function getSomething($option_id) {
> return 1;
>   }
> }
>
>
> The error is: Error: SQLSTATE[42000]: Syntax error or access violation: 1064
> You have an error in your SQL syntax; check the manual that corresponds to
> your MySQL server version for the right syntax to use near 'getSomething' at
> line 1
>
> The debug trace shows:
>
> Stack Trace
>
> CORE\Cake\Model\Datasource\DboSource.php line 461 →
> PDOStatement->execute(array)
>
> try {
> $query = $this->_connection->prepare($sql, $prepareOptions);
> $query->setFetchMode(PDO::FETCH_LAZY);
> if (!$query->execute($params)) {
> $this->_results = $query;
>
> array(
>   (int) 0 => (int) 1
> )
>
> CORE\Cake\Model\Datasource\DboSource.php line 427 →
> DboSource->_execute(string, array)
>
> $options += array('log' => $this->fullDebug);
>
> $t = microtime(true);
> $this->_result = $this->_execute($sql, $params);
>
> 'getSomething'
> array(
>   (int) 0 => (int) 1
> )
>
> CORE\Cake\Model\Datasource\DboSource.php line 671 →
> DboSource->execute(string, array, array)
>
> if ($cache && ($cached = $this->getQueryCache($sql, $params)) !==
> false) {
> return $cached;
> }
> if ($result = $this->execute($sql, array(), $params)) {
> $out = array();
>
> 'getSomething'
> array()
> array(
>   (int) 0 => (int) 1
> )
>
> CORE\Cake\Model\Datasource\DboSource.php line 613 →
> DboSource->fetchAll(string, array, array)
>
> } else {
> $cache = true;
> }
> return $this->fetchAll($args[0], $args[1], array('cache' =>
> $cache));
> }
>
> 'getSomething'
> array(
>   (int) 0 => (int) 1
> )
> array(
>   'cache' => object(AppModel) {}
> )
>
> CORE\Cake\Model\Model.php line 784 → DboSource->query(string, array,
> AppModel)
>
> if ($result !== array('unhandled')) {
> return $result;
> }
> $return = $this->getDataSource()->query($method, $params, $this);
> return $return;
>
> 'getSomething'
> array(
>   (int) 0 => (int) 1
> )
> object(AppModel) {
>   useDbConfig => 'default'
>   useTable => 'shooter_options'
>   id => false
>   data => array([maximum depth reached])
>   schemaName => 'shoots'
>   table => 'shooter_options'
>   primaryKey => 'id'
>   validate => array([maximum depth reached])
>   validationErrors => array([maximum depth reached])
>   validationDomain => null
>   name => 'ShooterOption'
>   alias => 'ShooterOption'
>   tableToModel => array(
>   [maximum depth reached]
>   )
>   cacheQueries => false
>   belongsTo => array([maximum depth reached])
>   hasOne => array([maximum depth reached])
>   hasMany => array([maximum depth reached])
>   hasAndBelongsToMany => array([maximum depth reached])
>   actsAs => null
>   Behaviors => object(BehaviorCollection) {}
>   whitelist => array([maximum depth reached])
>   cacheSources => true
>   findQueryType => null
>   recursive => (int) 1
>   order => null
>   virtualFields => array([maximum depth reached])
>   __backAssociation => array([maximum depth reached])
>   __backInnerAssociation => array([maximum depth reached])
>   __backOriginalAssociation => array([maximum depth reached])
>   __backContainableAssociation => array([maximum depth reached])
>   findMethods => array(
>   [maximum depth reached]
>   )
>   tablePrefix => ''
> }
>
> APP\Controller\OptionsController.php line 199 → Model->__call(string, array)
>
> $paid_options = $this->ShooterOption->find('all');
>
>
>
> $something =  'Default answer';
>
> $something = $this->ShooterOption->getSomething(1);
>
>
>
> 'getSomething'
> array(
>   (int) 0 => (int) 1
> )
>
> APP\Controller\OptionsController.php line 199 →
> AppModel->getSomething(integer)
>
> $paid_options = 

Re: Error: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; But execute is trying to use function name as the $sql

2012-12-04 Thread Andras Kende
If inside the class ShooterOption class change :
$this->ShooterOption->getSomething(1);
to:
$this->getSomething(1);

also on your 
public function calc($id) {
$paid_entries = $this->ShooterEvent->getPaidEntries($event_id);

Where is $event_id coming from ? should it be just $id ?

Andras Kende
http://www.kende.com


On Dec 4, 2012, at 10:11 AM, glk  wrote:

> Hello all,  thank you in advance for any help you may be able to provide.
> 
> I'm using cakePHP 2.2.1
> 
> The following code works perfectly:
> 
>   class OptionsController extends AppController {
> var $uses = array('Option', 'ShooterEvent', 'ShooterOption');
> 
> public function calc($id) {
>   $paid_entries = $this->ShooterEvent->getPaidEntries($event_id);
>   $paid_options = $this->ShooterOption->find('all');
> 
>   $something =  'Default answer';
> 
>   $this->set(compact('paid_entries', 'something', 'paid_options'));
> }
> 
> 
>  The following change will die horribly:
> 
>   // Made to class above
>   $something =  'Default answer';
>  $something = $this->ShooterOption->getSomething(1);
> 
> // Made to the ShooterOption class
> class ShooterOption extends AppModel {
>   function getSomething($option_id) {
> return 1;
>   }
> }
> 
> 
> The error is: Error: SQLSTATE[42000]: Syntax error or access violation: 1064 
> You have an error in your SQL syntax; check the manual that corresponds to 
> your MySQL server version for the right syntax to use near 'getSomething' at 
> line 1
> 
> The debug trace shows:
> Stack Trace
> 
>   • CORE\Cake\Model\Datasource\DboSource.php line 461 → 
> PDOStatement->execute(array)
> try {
> $query = $this->_connection->prepare($sql, $prepareOptions);
> $query->setFetchMode(PDO::FETCH_LAZY);
> if (!$query->execute($params)) {
> $this->_results = $query;
> array(
>   (int) 0 => (int) 1
> )
> 
>   • CORE\Cake\Model\Datasource\DboSource.php line 427 → 
> DboSource->_execute(string, array)
> $options += array('log' => $this->fullDebug);
> 
> $t = microtime(true);
> $this->_result = $this->_execute($sql, $params);
> 'getSomething'
> array(
>   (int) 0 => (int) 1
> )
> 
>   • CORE\Cake\Model\Datasource\DboSource.php line 671 → 
> DboSource->execute(string, array, array)
> if ($cache && ($cached = $this->getQueryCache($sql, $params)) !== 
> false) {
> return $cached;
> }
> if ($result = $this->execute($sql, array(), $params)) {
> $out = array();
> 'getSomething'
> array()
> array(
>   (int) 0 => (int) 1
> )
> 
>   • CORE\Cake\Model\Datasource\DboSource.php line 613 → 
> DboSource->fetchAll(string, array, array)
> } else {
> $cache = true;
> }
> return $this->fetchAll($args[0], $args[1], array('cache' => 
> $cache));
> }
> 'getSomething'
> array(
>   (int) 0 => (int) 1
> )
> array(
>   'cache' => object(AppModel) {}
> )
> 
>   • CORE\Cake\Model\Model.php line 784 → DboSource->query(string, array, 
> AppModel)
> if ($result !== array('unhandled')) {
> return $result;
> }
> $return = $this->getDataSource()->query($method, $params, $this);
> return $return;
> 'getSomething'
> array(
>   (int) 0 => (int) 1
> )
> object(AppModel) {
>   useDbConfig => 'default'
>   useTable => 'shooter_options'
>   id => false
>   data => array([maximum depth reached])
>   schemaName => 'shoots'
>   table => 'shooter_options'
>   primaryKey => 'id'
>   validate => array([maximum depth reached])
>   validationErrors => array([maximum depth reached])
>   validationDomain => null
>   name => 'ShooterOption'
>   alias => 'ShooterOption'
>   tableToModel => array(
>   [maximum depth reached]
>   )
>   cacheQueries => false
>   belongsTo => array([maximum depth reached])
>   hasOne => array([maximum depth reached])
>   hasMany => array([maximum depth reached])
>   hasAndBelongsToMany => array([maximum depth reached])
>   actsAs => null
>   Behaviors => object(BehaviorCollection) {}
>   whitelist => array([maximum depth reached])
>   cacheSources => true
>   findQueryType => null
>   recursive => (int) 1
>   order => null
>   virtualFields => array([maximum depth reached])
>   __backAssociation => array([maximum depth reached])
>   __backInnerAssociation => array([maximum depth reached])
>   __backOriginalAssociation => array([maximum depth reached])
>   __backContainableAssociation => array([maximum depth reached])
>   findMethods => array(
>   [maximum depth reached]
>   )
>   tablePrefix => ''
> }
> 
>   • APP\Controller\OptionsController.php line 199 → Model->__call(string, 
> array)
> $paid_options = $this->ShooterOption->find('all');
> 
> 
> 
> 
> 
>

Re: Error Debugging Help

2012-10-30 Thread Nikunj Kansara
hi, 

I am new to setup files on server, I am using ubuntu server, it's showing 
ImgController error, can you please give me detail idea, how can i solve 
this error

can you give me all steps, how to check web server configuration, what 
changes I have made there?

Thank you. 

On Friday, 4 November 2011 09:51:57 UTC+5:30, zuha wrote:
>
> It sure doesn't seem right to throw a missing controller error for a a 
> missing image call.  Does anyone else have an idea about how to find where 
> this exception is being thrown?   Or what CakeRequest is asking for which 
> causes this exception? 

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Index.phpController could not be found

2012-10-30 Thread Jeremy Burns | Class Outfit
What URL are you typing to get that error?

Jeremy Burns
Class Outfit

http://www.classoutfit.com

On 30 Oct 2012, at 11:22:40, Babulal Saini  wrote:

> Hi,  
> 
>  
> class IndexController extends AppController {
> 
> }
> 
> you are use this code...
> 
> 
> 
> 
> 
> On Wednesday, February 22, 2012 6:46:08 PM UTC-5, amg55nj wrote:
> Completely new to CakePHP. Tried doing a search with no results.
> 
> I installed CakePHP to my localhost Apache directory. Other programs such as 
> PHPMyAdmin work just fine. I am getting this error:
> 
> Missing Controller
> 
> Error: Index.phpController could not be found.
> 
> Error: Create the class Index.phpController below in file: 
> app\Controller\Index.phpController.php
> 
>  
> class Index.phpController extends AppController {
> 
> }
> 
> Notice: If you want to customize this error message, create 
> app\View\Errors\missing_controller.ctp
> 
> 
> 
> What do I do? I tried creating that PHP file and putting it in the 
> app\Controller directory but that did not work.
> 
> 
> -- 
> 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 
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to 
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>  
>  

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Index.phpController could not be found

2012-10-30 Thread Babulal Saini
Hi,  


> Completely new to CakePHP. Tried doing a search with no results.
>
> I installed CakePHP to my localhost Apache directory. Other programs such 
> as PHPMyAdmin work just fine. I am getting this error:
>
> Missing Controller
>
> Error: Index.phpController could not be found.
>
> Error: Create the class Index.phpController below in file: 
> app\Controller\Index.phpController.php
>
> 
> class Index.phpController extends AppController {
>
> }
>
> Notice: If you want to customize this error message, create 
> app\View\Errors\missing_controller.ctp
>
>
> What do I do? I tried creating that PHP file and putting it in the 
> app\Controller directory but that did not work.
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-30 Thread Babulal Saini
Hello Russell Brown,

  You are use this code so this error not show again. Please add 
this code "

set('address_list', $this->Address->find('all'));
  }

}
?>

"  

On Monday, October 15, 2012 7:58:52 PM UTC-4, Russell Brown wrote:
>
> Error:  Call to a member function find() on a non-object
> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
>
> I get the error on the $this->set('address_list', 
> $this->Address->find('all')) line below:
>
> Partial listing of my AddressesController file:
>
>  class AddressesController extends AppController {
>   var $name = 'addresses';
>   
>  function index($id = null) {
> $this->set('address_list', $this->Address->find('all'));
>   }
>
> I have a controller called AddressesController.php.  I have a Model called 
> Address.php.  The table is called addresses.
>
> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-19 Thread francis declaro
change your Controller 

class AddressesController extends AppController {
  public $uses = 'Address'; // or your model name for it
  var_dump($this->Address->find('all', array('limit' => 10)));
 }

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Vanja Dizdarević
This error implies that the $this->Address object is not available.

If there is no database connection, the Address model should still be 
available on $this->Address and you would get a database connection error. 


Just in case, try defining the $uses variable in your controller. 

class AddressesController extends AppController {

public $uses = array('Address');

...

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Ma'moon
Just check your database permissions and make sure that the user mentioned
in your database.php file is actually able to use the database mentioned by
its name in the same file, my hunch is telling me that this is your problem
:)

On Thu, Oct 18, 2012 at 8:22 PM, Russell Brown wrote:

> I should also point out that I was able to do the Blog Tutorial without
> any problems.  No problems with database connection
>
> I think I am just going to put this one aside for a while and focus on
> developing a new application.
>
>
> On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote:
>
>> Error:  Call to a member function find() on a non-object
>> File:  c:\wamp\www\cake222\app\**Controller\**AddressesController.php
>>
>> I get the error on the $this->set('address_list',
>> $this->Address->find('all')) line below:
>>
>> Partial listing of my AddressesController file:
>>
>> > class AddressesController extends AppController {
>>   var $name = 'addresses';
>>
>>  function index($id = null) {
>> $this->set('address_list', $this->Address->find('all'));
>>   }
>>
>> I have a controller called AddressesController.php.  I have a Model
>> called Address.php.  The table is called addresses.
>>
>> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>>
>>  --
> 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
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Russell Brown
I should also point out that I was able to do the Blog Tutorial without any 
problems.  No problems with database connection

I think I am just going to put this one aside for a while and focus on 
developing a new application.  


On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote:
>
> Error:  Call to a member function find() on a non-object
> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
>
> I get the error on the $this->set('address_list', 
> $this->Address->find('all')) line below:
>
> Partial listing of my AddressesController file:
>
>  class AddressesController extends AppController {
>   var $name = 'addresses';
>   
>  function index($id = null) {
> $this->set('address_list', $this->Address->find('all'));
>   }
>
> I have a controller called AddressesController.php.  I have a Model called 
> Address.php.  The table is called addresses.
>
> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Jonathan Sundquist
Yes going through phpMyAdmin would be a good test.  if that works, awesome.
 Is php my admin and your cake application on the same server?  Could be a
permission issue going between servers.

Yes there should be only one database.php file within your config file.
 Are the file permissions set up correctly?

And now that I read your next comment my question is semi invalid. We need
to go back to the table / user permissions.

What do you mean by you can see the app in your browser no problem?  Does
this mean you can see it with the other database?

On Thu, Oct 18, 2012 at 6:28 PM, Russell Brown wrote:

> I can connect to it via phpMyAdmin and see the databases and tables.  Is
> that what you mean by connecting to it directly?
>
> I suspect my database config must be the problem yes.
>
> In the config folder under the app I have my database.php file setup.  I
> wonder if there is another database config I should be looking at?
>
> I have another database.php file setup exactly the same way except for the
> database name and it works fine.  I can see the app in the browser no
> problem.
>
>
>
>
>
> On Thursday, October 18, 2012 6:13:47 PM UTC-5, jsundquist wrote:
>
>> Did you set up your database config correctly?  Try connecting to it
>> directly to see if your database is up and your connection information is
>> correct.
>>
>> On Thu, Oct 18, 2012 at 6:06 PM, Russell Brown wrote:
>>
>>> It does give me the line number.  However, I just noticed that SQL Logs
>>> says "Warning - No active database connection"
>>>
>>> When I look at variables I see:  *$request->data*(empty)
>>>
>>> Somehow I am not connected to the database and/or table.
>>>
>>> On Thursday, October 18, 2012 5:47:21 PM UTC-5, phpirate wrote:
>>>
 Does it say at what line the error occurs? What does your web server's
 error log say?

 On Thu, Oct 18, 2012 at 6:14 PM, Russell Brown 
 wrote:

> Yes.  I did a clean install and still get the error.
>
> I get the DebugKit toolbar -it works fine.
>
> For some reason I can't just type debug($this); before and after the
> variable I want to check.  Still gives me a syntax error.
>
> On Thursday, October 18, 2012 3:50:23 PM UTC-5, cricket wrote:
>
>> Any other info on what the syntax error is? I'm beginning to think
>> something is really borked with your install.
>>
>> On Thu, Oct 18, 2012 at 4:28 PM, Russell Brown <
>> ru...@russsoftware.com> wrote:
>> > When I put debug($this); in the file, however I get a syntax error
>> on that
>> > line.
>> >
>> > I am using Cake 2.2.2 and I have installed the DebugKit too.
>> >
>> >
>> >
>> > On Monday, October 15, 2012 8:27:58 PM UTC-5, Wallace Cardoso
>> Colaço Ricardo
>> > wrote:
>> >>
>> >> Try to debug what objects(Models) are being loaded...
>> >>
>> >> Doing so you will know for sure the name of the instance Address.
>> >>
>> >> Put this before your find:
>> >>
>> >> debug($this);
>> >>
>> >> On Oct 15, 2012, at 9:23 PM, Russell Brown wrote:
>> >>
>> >> Here is my index.ctp view file in the View\Addresses folder:
>> >>
>> >> > >> echo $this->Html->link('Add New Address', array('action'=>'add'));
>> >> ?>
>> >> 
>> >>   
>> >>  Id
>> >>  First Name
>> >>  Last Name
>> >>  Email
>> >>  Phone
>> >>  Address
>> >>  Options
>> >>   
>> >>
>> >> > >>   foreach ( $address_list as $line ) {
>> >>   $address = $line['Address'];
>> >> echo
>> >> ''.
>> >> ''.$address['id'].''.
>> >> ''.$this->Html->link($**address['first_name'],
>> array('action'=>'view',
>> >> 'id'=>$address['id'])).''**.
>> >> ''.$address['last_name'].'**'.
>> >> ''.$address['email'].''.
>> >> ''.$address['phone'].''.
>> >> ''.$address['address'].''.
>> >> ''.$this->Html->link('**edit', array('action'=>'edit',
>> >> 'id'=>$address['id'])).' '.
>> >>
>> >> $this->Html->link('delete', array('action'=>'delete',
>> >> 'id'=>$address['id'])).''**.
>> >> '';
>> >>
>> >>   };
>> >> ?>
>> >> 
>> >>
>> >>
>> >> On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote:
>> >>>
>> >>> Error:  Call to a member function find() on a non-object
>> >>> File:  
>> >>> c:\wamp\www\cake222\app\**Controller\**AddressesController.php
>>
>> >>>
>> >>> I get the error on the $this->set('address_list',
>> >>> $this->Address->find('all')) line below:
>> >>>
>> >>> Partial listing of my AddressesController file:
>> >>>
>> >>> > >>> class AddressesController extends AppController {
>> >>>   var $name = 'addresses';
>> >>>
>> >>>  function index($id = null) {
>> >>> $this->set('address_list', $this->Address->find('all'));
>> >>>   }
>> >>>
>> >>> I have a controller called Addresse

Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Russell Brown
I can connect to it via phpMyAdmin and see the databases and tables.  Is 
that what you mean by connecting to it directly?

I suspect my database config must be the problem yes.

In the config folder under the app I have my database.php file setup.  I 
wonder if there is another database config I should be looking at?

I have another database.php file setup exactly the same way except for the 
database name and it works fine.  I can see the app in the browser no 
problem.





On Thursday, October 18, 2012 6:13:47 PM UTC-5, jsundquist wrote:
>
> Did you set up your database config correctly?  Try connecting to it 
> directly to see if your database is up and your connection information is 
> correct.
>
> On Thu, Oct 18, 2012 at 6:06 PM, Russell Brown 
> 
> > wrote:
>
>> It does give me the line number.  However, I just noticed that SQL Logs 
>> says "Warning - No active database connection" 
>>
>> When I look at variables I see:  *$request->data*(empty)
>>
>> Somehow I am not connected to the database and/or table.
>>
>> On Thursday, October 18, 2012 5:47:21 PM UTC-5, phpirate wrote:
>>
>>> Does it say at what line the error occurs? What does your web server's 
>>> error log say? 
>>>
>>> On Thu, Oct 18, 2012 at 6:14 PM, Russell Brown 
>>> wrote:
>>>
 Yes.  I did a clean install and still get the error.

 I get the DebugKit toolbar -it works fine.

 For some reason I can't just type debug($this); before and after the 
 variable I want to check.  Still gives me a syntax error.

 On Thursday, October 18, 2012 3:50:23 PM UTC-5, cricket wrote:

> Any other info on what the syntax error is? I'm beginning to think 
> something is really borked with your install. 
>
> On Thu, Oct 18, 2012 at 4:28 PM, Russell Brown  
> wrote: 
> > When I put debug($this); in the file, however I get a syntax error 
> on that 
> > line. 
> > 
> > I am using Cake 2.2.2 and I have installed the DebugKit too. 
> > 
> > 
> > 
> > On Monday, October 15, 2012 8:27:58 PM UTC-5, Wallace Cardoso Colaço 
> Ricardo 
> > wrote: 
> >> 
> >> Try to debug what objects(Models) are being loaded... 
> >> 
> >> Doing so you will know for sure the name of the instance Address. 
> >> 
> >> Put this before your find: 
> >> 
> >> debug($this); 
> >> 
> >> On Oct 15, 2012, at 9:23 PM, Russell Brown wrote: 
> >> 
> >> Here is my index.ctp view file in the View\Addresses folder: 
> >> 
> >>  >> echo $this->Html->link('Add New Address', array('action'=>'add')); 
> >> ?> 
> >>  
> >>
> >>  Id 
> >>  First Name 
> >>  Last Name 
> >>  Email 
> >>  Phone 
> >>  Address 
> >>  Options 
> >>
> >> 
> >>  >>   foreach ( $address_list as $line ) { 
> >>   $address = $line['Address']; 
> >> echo 
> >> ''. 
> >> ''.$address['id'].''. 
> >> ''.$this->Html->link($**addr**ess['first_name'], 
> array('action'=>'view', 
> >> 'id'=>$address['id'])).''. 
> >> ''.$address['last_name'].''. 
> >> ''.$address['email'].''. 
> >> ''.$address['phone'].''. 
> >> ''.$address['address'].''. 
> >> ''.$this->Html->link('**edit**', array('action'=>'edit', 
> >> 'id'=>$address['id'])).' '. 
> >> 
> >> $this->Html->link('delete', array('action'=>'delete', 
> >> 'id'=>$address['id'])).''. 
> >> ''; 
> >> 
> >>   }; 
> >> ?> 
> >>  
> >> 
> >> 
> >> On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote: 
> >>> 
> >>> Error:  Call to a member function find() on a non-object 
> >>> File:  
> >>> c:\wamp\www\cake222\app\**Contr**oller\**AddressesController.php 
>
> >>> 
> >>> I get the error on the $this->set('address_list', 
> >>> $this->Address->find('all')) line below: 
> >>> 
> >>> Partial listing of my AddressesController file: 
> >>> 
> >>>  >>> class AddressesController extends AppController { 
> >>>   var $name = 'addresses'; 
> >>> 
> >>>  function index($id = null) { 
> >>> $this->set('address_list', $this->Address->find('all')); 
> >>>   } 
> >>> 
> >>> I have a controller called AddressesController.php.  I have a 
> Model 
> >>> called Address.php.  The table is called addresses. 
> >>> 
> >>> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 
> 5.5.16 
> >>> 
> >> 
> >> -- 
> >> Like Us on FaceBook 
> >> https://www.facebook.com/**CakeP**HP 
> >> Find us on Twitter http://twitter.com/CakePHP 
> >> 
> >> --- 
> >> You received this message because you are subscribed to the Google 
> Groups 
> >> "CakePHP" group. 
> >> To post to this group, send email to cake...@googlegroups.com. 
> >> To unsubscribe from this group, send email to 
> >> cake-

Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Jonathan Sundquist
Did you set up your database config correctly?  Try connecting to it
directly to see if your database is up and your connection information is
correct.

On Thu, Oct 18, 2012 at 6:06 PM, Russell Brown wrote:

> It does give me the line number.  However, I just noticed that SQL Logs
> says "Warning - No active database connection"
>
> When I look at variables I see:  *$request->data*(empty)
>
> Somehow I am not connected to the database and/or table.
>
> On Thursday, October 18, 2012 5:47:21 PM UTC-5, phpirate wrote:
>
>> Does it say at what line the error occurs? What does your web server's
>> error log say?
>>
>> On Thu, Oct 18, 2012 at 6:14 PM, Russell Brown wrote:
>>
>>> Yes.  I did a clean install and still get the error.
>>>
>>> I get the DebugKit toolbar -it works fine.
>>>
>>> For some reason I can't just type debug($this); before and after the
>>> variable I want to check.  Still gives me a syntax error.
>>>
>>> On Thursday, October 18, 2012 3:50:23 PM UTC-5, cricket wrote:
>>>
 Any other info on what the syntax error is? I'm beginning to think
 something is really borked with your install.

 On Thu, Oct 18, 2012 at 4:28 PM, Russell Brown 
 wrote:
 > When I put debug($this); in the file, however I get a syntax error on
 that
 > line.
 >
 > I am using Cake 2.2.2 and I have installed the DebugKit too.
 >
 >
 >
 > On Monday, October 15, 2012 8:27:58 PM UTC-5, Wallace Cardoso Colaço
 Ricardo
 > wrote:
 >>
 >> Try to debug what objects(Models) are being loaded...
 >>
 >> Doing so you will know for sure the name of the instance Address.
 >>
 >> Put this before your find:
 >>
 >> debug($this);
 >>
 >> On Oct 15, 2012, at 9:23 PM, Russell Brown wrote:
 >>
 >> Here is my index.ctp view file in the View\Addresses folder:
 >>
 >> >>> >> echo $this->Html->link('Add New Address', array('action'=>'add'));
 >> ?>
 >> 
 >>   
 >>  Id
 >>  First Name
 >>  Last Name
 >>  Email
 >>  Phone
 >>  Address
 >>  Options
 >>   
 >>
 >> >>> >>   foreach ( $address_list as $line ) {
 >>   $address = $line['Address'];
 >> echo
 >> ''.
 >> ''.$address['id'].''.
 >> ''.$this->Html->link($**addr**ess['first_name'],
 array('action'=>'view',
 >> 'id'=>$address['id'])).''.
 >> ''.$address['last_name'].''.
 >> ''.$address['email'].''.
 >> ''.$address['phone'].''.
 >> ''.$address['address'].''.
 >> ''.$this->Html->link('**edit**', array('action'=>'edit',
 >> 'id'=>$address['id'])).' '.
 >>
 >> $this->Html->link('delete', array('action'=>'delete',
 >> 'id'=>$address['id'])).''.
 >> '';
 >>
 >>   };
 >> ?>
 >> 
 >>
 >>
 >> On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote:
 >>>
 >>> Error:  Call to a member function find() on a non-object
 >>> File:  c:\wamp\www\cake222\app\**Contr**oller\**AddressesController.php

 >>>
 >>> I get the error on the $this->set('address_list',
 >>> $this->Address->find('all')) line below:
 >>>
 >>> Partial listing of my AddressesController file:
 >>>
 >>> >>> >>> class AddressesController extends AppController {
 >>>   var $name = 'addresses';
 >>>
 >>>  function index($id = null) {
 >>> $this->set('address_list', $this->Address->find('all'));
 >>>   }
 >>>
 >>> I have a controller called AddressesController.php.  I have a Model
 >>> called Address.php.  The table is called addresses.
 >>>
 >>> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL
 5.5.16
 >>>
 >>
 >> --
 >> Like Us on FaceBook 
 >> https://www.facebook.com/**CakeP**HP
 >> Find us on Twitter http://twitter.com/CakePHP
 >>
 >> ---
 >> You received this message because you are subscribed to the Google
 Groups
 >> "CakePHP" group.
 >> To post to this group, send email to cake...@googlegroups.com.
 >> To unsubscribe from this group, send email to
 >> cake-php+u...@googlegroups.com.
 >>
 >> Visit this group at http://groups.google.com/**group**
 /cake-php?hl=en .
 >>
 >>
 >>
 >>
 > --
 > Like Us on FaceBook 
 > https://www.facebook.com/**CakeP**HP
 > Find us on Twitter http://twitter.com/CakePHP
 >
 > ---
 > You received this message because you are subscribed to the Google
 Groups
 > "CakePHP" group.
 > To post to this group, send email to cake...@googlegroups.com.
 > To unsubscribe from this group, send email to
 > cake-php+u...@**googlegroups.com**.
 > Visit this group at 
 > http://groups.google.com/**group**/cake-php?hl=en.

 >
 >

>>

Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Russell Brown
I am able to get to other databases though, just not this one but that must 
be a clue!



On Thursday, October 18, 2012 6:06:28 PM UTC-5, Russell Brown wrote:
>
> It does give me the line number.  However, I just noticed that SQL Logs 
> says "Warning - No active database connection" 
>
> When I look at variables I see:  *$request->data*(empty)
>
> Somehow I am not connected to the database and/or table.
>
> On Thursday, October 18, 2012 5:47:21 PM UTC-5, phpirate wrote:
>>
>> Does it say at what line the error occurs? What does your web server's 
>> error log say? 
>>
>> On Thu, Oct 18, 2012 at 6:14 PM, Russell Brown wrote:
>>
>>> Yes.  I did a clean install and still get the error.
>>>
>>> I get the DebugKit toolbar -it works fine.
>>>
>>> For some reason I can't just type debug($this); before and after the 
>>> variable I want to check.  Still gives me a syntax error.
>>>
>>> On Thursday, October 18, 2012 3:50:23 PM UTC-5, cricket wrote:
>>>
 Any other info on what the syntax error is? I'm beginning to think 
 something is really borked with your install. 

 On Thu, Oct 18, 2012 at 4:28 PM, Russell Brown  
 wrote: 
 > When I put debug($this); in the file, however I get a syntax error on 
 that 
 > line. 
 > 
 > I am using Cake 2.2.2 and I have installed the DebugKit too. 
 > 
 > 
 > 
 > On Monday, October 15, 2012 8:27:58 PM UTC-5, Wallace Cardoso Colaço 
 Ricardo 
 > wrote: 
 >> 
 >> Try to debug what objects(Models) are being loaded... 
 >> 
 >> Doing so you will know for sure the name of the instance Address. 
 >> 
 >> Put this before your find: 
 >> 
 >> debug($this); 
 >> 
 >> On Oct 15, 2012, at 9:23 PM, Russell Brown wrote: 
 >> 
 >> Here is my index.ctp view file in the View\Addresses folder: 
 >> 
 >> >>> >> echo $this->Html->link('Add New Address', array('action'=>'add')); 
 >> ?> 
 >>  
 >>
 >>  Id 
 >>  First Name 
 >>  Last Name 
 >>  Email 
 >>  Phone 
 >>  Address 
 >>  Options 
 >>
 >> 
 >> >>> >>   foreach ( $address_list as $line ) { 
 >>   $address = $line['Address']; 
 >> echo 
 >> ''. 
 >> ''.$address['id'].''. 
 >> ''.$this->Html->link($**address['first_name'], 
 array('action'=>'view', 
 >> 'id'=>$address['id'])).''**. 
 >> ''.$address['last_name'].'**'. 
 >> ''.$address['email'].''. 
 >> ''.$address['phone'].''. 
 >> ''.$address['address'].''. 
 >> ''.$this->Html->link('**edit', array('action'=>'edit', 
 >> 'id'=>$address['id'])).' '. 
 >> 
 >> $this->Html->link('delete', array('action'=>'delete', 
 >> 'id'=>$address['id'])).''**. 
 >> ''; 
 >> 
 >>   }; 
 >> ?> 
 >>  
 >> 
 >> 
 >> On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote: 
 >>> 
 >>> Error:  Call to a member function find() on a non-object 
 >>> File:  c:\wamp\www\cake222\app\**Controller\**AddressesController.php 

 >>> 
 >>> I get the error on the $this->set('address_list', 
 >>> $this->Address->find('all')) line below: 
 >>> 
 >>> Partial listing of my AddressesController file: 
 >>> 
 >>> >>> >>> class AddressesController extends AppController { 
 >>>   var $name = 'addresses'; 
 >>> 
 >>>  function index($id = null) { 
 >>> $this->set('address_list', $this->Address->find('all')); 
 >>>   } 
 >>> 
 >>> I have a controller called AddressesController.php.  I have a Model 
 >>> called Address.php.  The table is called addresses. 
 >>> 
 >>> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 
 5.5.16 
 >>> 
 >> 
 >> -- 
 >> 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 
 >> "CakePHP" group. 
 >> To post to this group, send email to cake...@googlegroups.com. 
 >> To unsubscribe from this group, send email to 
 >> cake-php+u...@googlegroups.com**. 
 >> 
 >> Visit this group at 
 >> http://groups.google.com/**group/cake-php?hl=en.
 >>  

 >> 
 >> 
 >> 
 >> 
 > -- 
 > 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 
 > "CakePHP" group. 
 > To post to this group, send email to cake...@googlegroups.com. 
 > To unsubscribe from this group, send email to 
 > cake-php+u...@**googlegroups.com. 
 > Visit this group at 
 > http://groups.google.com/**group/cake-php?hl=en

Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Russell Brown
It does give me the line number.  However, I just noticed that SQL Logs 
says "Warning - No active database connection" 

When I look at variables I see:  *$request->data*(empty)

Somehow I am not connected to the database and/or table.

On Thursday, October 18, 2012 5:47:21 PM UTC-5, phpirate wrote:
>
> Does it say at what line the error occurs? What does your web server's 
> error log say? 
>
> On Thu, Oct 18, 2012 at 6:14 PM, Russell Brown 
> 
> > wrote:
>
>> Yes.  I did a clean install and still get the error.
>>
>> I get the DebugKit toolbar -it works fine.
>>
>> For some reason I can't just type debug($this); before and after the 
>> variable I want to check.  Still gives me a syntax error.
>>
>> On Thursday, October 18, 2012 3:50:23 PM UTC-5, cricket wrote:
>>
>>> Any other info on what the syntax error is? I'm beginning to think 
>>> something is really borked with your install. 
>>>
>>> On Thu, Oct 18, 2012 at 4:28 PM, Russell Brown  
>>> wrote: 
>>> > When I put debug($this); in the file, however I get a syntax error on 
>>> that 
>>> > line. 
>>> > 
>>> > I am using Cake 2.2.2 and I have installed the DebugKit too. 
>>> > 
>>> > 
>>> > 
>>> > On Monday, October 15, 2012 8:27:58 PM UTC-5, Wallace Cardoso Colaço 
>>> Ricardo 
>>> > wrote: 
>>> >> 
>>> >> Try to debug what objects(Models) are being loaded... 
>>> >> 
>>> >> Doing so you will know for sure the name of the instance Address. 
>>> >> 
>>> >> Put this before your find: 
>>> >> 
>>> >> debug($this); 
>>> >> 
>>> >> On Oct 15, 2012, at 9:23 PM, Russell Brown wrote: 
>>> >> 
>>> >> Here is my index.ctp view file in the View\Addresses folder: 
>>> >> 
>>> >> >> >> echo $this->Html->link('Add New Address', array('action'=>'add')); 
>>> >> ?> 
>>> >>  
>>> >>
>>> >>  Id 
>>> >>  First Name 
>>> >>  Last Name 
>>> >>  Email 
>>> >>  Phone 
>>> >>  Address 
>>> >>  Options 
>>> >>
>>> >> 
>>> >> >> >>   foreach ( $address_list as $line ) { 
>>> >>   $address = $line['Address']; 
>>> >> echo 
>>> >> ''. 
>>> >> ''.$address['id'].''. 
>>> >> ''.$this->Html->link($**address['first_name'], 
>>> array('action'=>'view', 
>>> >> 'id'=>$address['id'])).''**. 
>>> >> ''.$address['last_name'].'**'. 
>>> >> ''.$address['email'].''. 
>>> >> ''.$address['phone'].''. 
>>> >> ''.$address['address'].''. 
>>> >> ''.$this->Html->link('**edit', array('action'=>'edit', 
>>> >> 'id'=>$address['id'])).' '. 
>>> >> 
>>> >> $this->Html->link('delete', array('action'=>'delete', 
>>> >> 'id'=>$address['id'])).''**. 
>>> >> ''; 
>>> >> 
>>> >>   }; 
>>> >> ?> 
>>> >>  
>>> >> 
>>> >> 
>>> >> On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote: 
>>> >>> 
>>> >>> Error:  Call to a member function find() on a non-object 
>>> >>> File:  c:\wamp\www\cake222\app\**Controller\**AddressesController.php 
>>>
>>> >>> 
>>> >>> I get the error on the $this->set('address_list', 
>>> >>> $this->Address->find('all')) line below: 
>>> >>> 
>>> >>> Partial listing of my AddressesController file: 
>>> >>> 
>>> >>> >> >>> class AddressesController extends AppController { 
>>> >>>   var $name = 'addresses'; 
>>> >>> 
>>> >>>  function index($id = null) { 
>>> >>> $this->set('address_list', $this->Address->find('all')); 
>>> >>>   } 
>>> >>> 
>>> >>> I have a controller called AddressesController.php.  I have a Model 
>>> >>> called Address.php.  The table is called addresses. 
>>> >>> 
>>> >>> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 
>>> 5.5.16 
>>> >>> 
>>> >> 
>>> >> -- 
>>> >> 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 
>>> >> "CakePHP" group. 
>>> >> To post to this group, send email to cake...@googlegroups.com. 
>>> >> To unsubscribe from this group, send email to 
>>> >> cake-php+u...@googlegroups.com**. 
>>> >> 
>>> >> Visit this group at 
>>> >> http://groups.google.com/**group/cake-php?hl=en.
>>> >>  
>>>
>>> >> 
>>> >> 
>>> >> 
>>> >> 
>>> > -- 
>>> > 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 
>>> > "CakePHP" group. 
>>> > To post to this group, send email to cake...@googlegroups.com. 
>>> > To unsubscribe from this group, send email to 
>>> > cake-php+u...@**googlegroups.com. 
>>> > Visit this group at 
>>> > http://groups.google.com/**group/cake-php?hl=en.
>>> >  
>>>
>>> > 
>>> > 
>>>
>>  -- 
>> 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 
>> "CakePHP" group.
>> To post to 

Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Ma'moon
Does it say at what line the error occurs? What does your web server's
error log say?

On Thu, Oct 18, 2012 at 6:14 PM, Russell Brown wrote:

> Yes.  I did a clean install and still get the error.
>
> I get the DebugKit toolbar -it works fine.
>
> For some reason I can't just type debug($this); before and after the
> variable I want to check.  Still gives me a syntax error.
>
> On Thursday, October 18, 2012 3:50:23 PM UTC-5, cricket wrote:
>
>> Any other info on what the syntax error is? I'm beginning to think
>> something is really borked with your install.
>>
>> On Thu, Oct 18, 2012 at 4:28 PM, Russell Brown 
>> wrote:
>> > When I put debug($this); in the file, however I get a syntax error on
>> that
>> > line.
>> >
>> > I am using Cake 2.2.2 and I have installed the DebugKit too.
>> >
>> >
>> >
>> > On Monday, October 15, 2012 8:27:58 PM UTC-5, Wallace Cardoso Colaço
>> Ricardo
>> > wrote:
>> >>
>> >> Try to debug what objects(Models) are being loaded...
>> >>
>> >> Doing so you will know for sure the name of the instance Address.
>> >>
>> >> Put this before your find:
>> >>
>> >> debug($this);
>> >>
>> >> On Oct 15, 2012, at 9:23 PM, Russell Brown wrote:
>> >>
>> >> Here is my index.ctp view file in the View\Addresses folder:
>> >>
>> >> > >> echo $this->Html->link('Add New Address', array('action'=>'add'));
>> >> ?>
>> >> 
>> >>   
>> >>  Id
>> >>  First Name
>> >>  Last Name
>> >>  Email
>> >>  Phone
>> >>  Address
>> >>  Options
>> >>   
>> >>
>> >> > >>   foreach ( $address_list as $line ) {
>> >>   $address = $line['Address'];
>> >> echo
>> >> ''.
>> >> ''.$address['id'].''.
>> >> ''.$this->Html->link($**address['first_name'],
>> array('action'=>'view',
>> >> 'id'=>$address['id'])).''**.
>> >> ''.$address['last_name'].'**'.
>> >> ''.$address['email'].''.
>> >> ''.$address['phone'].''.
>> >> ''.$address['address'].''.
>> >> ''.$this->Html->link('**edit', array('action'=>'edit',
>> >> 'id'=>$address['id'])).' '.
>> >>
>> >> $this->Html->link('delete', array('action'=>'delete',
>> >> 'id'=>$address['id'])).''**.
>> >> '';
>> >>
>> >>   };
>> >> ?>
>> >> 
>> >>
>> >>
>> >> On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote:
>> >>>
>> >>> Error:  Call to a member function find() on a non-object
>> >>> File:  c:\wamp\www\cake222\app\**Controller\**AddressesController.php
>>
>> >>>
>> >>> I get the error on the $this->set('address_list',
>> >>> $this->Address->find('all')) line below:
>> >>>
>> >>> Partial listing of my AddressesController file:
>> >>>
>> >>> > >>> class AddressesController extends AppController {
>> >>>   var $name = 'addresses';
>> >>>
>> >>>  function index($id = null) {
>> >>> $this->set('address_list', $this->Address->find('all'));
>> >>>   }
>> >>>
>> >>> I have a controller called AddressesController.php.  I have a Model
>> >>> called Address.php.  The table is called addresses.
>> >>>
>> >>> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL
>> 5.5.16
>> >>>
>> >>
>> >> --
>> >> 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
>> >> "CakePHP" group.
>> >> To post to this group, send email to cake...@googlegroups.com.
>> >> To unsubscribe from this group, send email to
>> >> cake-php+u...@googlegroups.com**.
>> >>
>> >> Visit this group at 
>> >> http://groups.google.com/**group/cake-php?hl=en.
>>
>> >>
>> >>
>> >>
>> >>
>> > --
>> > 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
>> > "CakePHP" group.
>> > To post to this group, send email to cake...@googlegroups.com.
>> > To unsubscribe from this group, send email to
>> > cake-php+u...@**googlegroups.com.
>> > Visit this group at 
>> > http://groups.google.com/**group/cake-php?hl=en.
>>
>> >
>> >
>>
>  --
> 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
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.co

Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Russell Brown
Yes.  I did a clean install and still get the error.

I get the DebugKit toolbar -it works fine.

For some reason I can't just type debug($this); before and after the 
variable I want to check.  Still gives me a syntax error.

On Thursday, October 18, 2012 3:50:23 PM UTC-5, cricket wrote:
>
> Any other info on what the syntax error is? I'm beginning to think 
> something is really borked with your install. 
>
> On Thu, Oct 18, 2012 at 4:28 PM, Russell Brown 
> > 
> wrote: 
> > When I put debug($this); in the file, however I get a syntax error on 
> that 
> > line. 
> > 
> > I am using Cake 2.2.2 and I have installed the DebugKit too. 
> > 
> > 
> > 
> > On Monday, October 15, 2012 8:27:58 PM UTC-5, Wallace Cardoso Colaço 
> Ricardo 
> > wrote: 
> >> 
> >> Try to debug what objects(Models) are being loaded... 
> >> 
> >> Doing so you will know for sure the name of the instance Address. 
> >> 
> >> Put this before your find: 
> >> 
> >> debug($this); 
> >> 
> >> On Oct 15, 2012, at 9:23 PM, Russell Brown wrote: 
> >> 
> >> Here is my index.ctp view file in the View\Addresses folder: 
> >> 
> >>  >> echo $this->Html->link('Add New Address', array('action'=>'add')); 
> >> ?> 
> >>  
> >>
> >>  Id 
> >>  First Name 
> >>  Last Name 
> >>  Email 
> >>  Phone 
> >>  Address 
> >>  Options 
> >>
> >> 
> >>  >>   foreach ( $address_list as $line ) { 
> >>   $address = $line['Address']; 
> >> echo 
> >> ''. 
> >> ''.$address['id'].''. 
> >> ''.$this->Html->link($address['first_name'], 
> array('action'=>'view', 
> >> 'id'=>$address['id'])).''. 
> >> ''.$address['last_name'].''. 
> >> ''.$address['email'].''. 
> >> ''.$address['phone'].''. 
> >> ''.$address['address'].''. 
> >> ''.$this->Html->link('edit', array('action'=>'edit', 
> >> 'id'=>$address['id'])).' '. 
> >> 
> >> $this->Html->link('delete', array('action'=>'delete', 
> >> 'id'=>$address['id'])).''. 
> >> ''; 
> >> 
> >>   }; 
> >> ?> 
> >>  
> >> 
> >> 
> >> On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote: 
> >>> 
> >>> Error:  Call to a member function find() on a non-object 
> >>> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php 
> >>> 
> >>> I get the error on the $this->set('address_list', 
> >>> $this->Address->find('all')) line below: 
> >>> 
> >>> Partial listing of my AddressesController file: 
> >>> 
> >>>  >>> class AddressesController extends AppController { 
> >>>   var $name = 'addresses'; 
> >>> 
> >>>  function index($id = null) { 
> >>> $this->set('address_list', $this->Address->find('all')); 
> >>>   } 
> >>> 
> >>> I have a controller called AddressesController.php.  I have a Model 
> >>> called Address.php.  The table is called addresses. 
> >>> 
> >>> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16 
> >>> 
> >> 
> >> -- 
> >> 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 
> >> "CakePHP" group. 
> >> To post to this group, send email to cake...@googlegroups.com. 
> >> To unsubscribe from this group, send email to 
> >> cake-php+u...@googlegroups.com. 
> >> 
> >> Visit this group at http://groups.google.com/group/cake-php?hl=en. 
> >> 
> >> 
> >> 
> >> 
> > -- 
> > 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 
> > "CakePHP" group. 
> > To post to this group, send email to cake...@googlegroups.com. 
>
> > To unsubscribe from this group, send email to 
> > cake-php+u...@googlegroups.com . 
> > Visit this group at http://groups.google.com/group/cake-php?hl=en. 
> > 
> > 
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread lowpass
Any other info on what the syntax error is? I'm beginning to think
something is really borked with your install.

On Thu, Oct 18, 2012 at 4:28 PM, Russell Brown  wrote:
> When I put debug($this); in the file, however I get a syntax error on that
> line.
>
> I am using Cake 2.2.2 and I have installed the DebugKit too.
>
>
>
> On Monday, October 15, 2012 8:27:58 PM UTC-5, Wallace Cardoso Colaço Ricardo
> wrote:
>>
>> Try to debug what objects(Models) are being loaded...
>>
>> Doing so you will know for sure the name of the instance Address.
>>
>> Put this before your find:
>>
>> debug($this);
>>
>> On Oct 15, 2012, at 9:23 PM, Russell Brown wrote:
>>
>> Here is my index.ctp view file in the View\Addresses folder:
>>
>> > echo $this->Html->link('Add New Address', array('action'=>'add'));
>> ?>
>> 
>>   
>>  Id
>>  First Name
>>  Last Name
>>  Email
>>  Phone
>>  Address
>>  Options
>>   
>>
>> >   foreach ( $address_list as $line ) {
>>   $address = $line['Address'];
>> echo
>> ''.
>> ''.$address['id'].''.
>> ''.$this->Html->link($address['first_name'], array('action'=>'view',
>> 'id'=>$address['id'])).''.
>> ''.$address['last_name'].''.
>> ''.$address['email'].''.
>> ''.$address['phone'].''.
>> ''.$address['address'].''.
>> ''.$this->Html->link('edit', array('action'=>'edit',
>> 'id'=>$address['id'])).' '.
>>
>> $this->Html->link('delete', array('action'=>'delete',
>> 'id'=>$address['id'])).''.
>> '';
>>
>>   };
>> ?>
>> 
>>
>>
>> On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote:
>>>
>>> Error:  Call to a member function find() on a non-object
>>> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
>>>
>>> I get the error on the $this->set('address_list',
>>> $this->Address->find('all')) line below:
>>>
>>> Partial listing of my AddressesController file:
>>>
>>> >> class AddressesController extends AppController {
>>>   var $name = 'addresses';
>>>
>>>  function index($id = null) {
>>> $this->set('address_list', $this->Address->find('all'));
>>>   }
>>>
>>> I have a controller called AddressesController.php.  I have a Model
>>> called Address.php.  The table is called addresses.
>>>
>>> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>>>
>>
>> --
>> 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
>> "CakePHP" group.
>> To post to this group, send email to cake...@googlegroups.com.
>> To unsubscribe from this group, send email to
>> cake-php+u...@googlegroups.com.
>>
>> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>>
>>
>>
>>
> --
> 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
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Jonathan Sundquist
Sorry. Do a var_dump($this)

- "The cold winds are rising"
On Oct 18, 2012 3:29 PM, "Russell Brown"  wrote:

> When I put debug($this); in the file, however I get a syntax error on that
> line.
>
> I am using Cake 2.2.2 and I have installed the DebugKit too.
>
>
>
> On Monday, October 15, 2012 8:27:58 PM UTC-5, Wallace Cardoso Colaço
> Ricardo wrote:
>>
>> Try to debug what objects(Models) are being loaded...
>>
>> Doing so you will know for sure the name of the instance Address.
>>
>> Put this before your find:
>>
>> debug($this);
>>
>> On Oct 15, 2012, at 9:23 PM, Russell Brown wrote:
>>
>> Here is my index.ctp view file in the View\Addresses folder:
>>
>> > echo $this->Html->link('Add New Address', array('action'=>'add'));
>> ?>
>> 
>>   
>>   Id
>>   First Name
>>   Last Name
>>   Email
>>   Phone
>>   Address
>>   Options
>>   
>>
>> >   foreach ( $address_list as $line ) {
>>   $address = $line['Address'];
>> echo
>> ''.
>> ''.$address['id'].''.
>> ''.$this->Html->link($**address['first_name'],
>> array('action'=>'view', 'id'=>$address['id'])).''**.
>> ''.$address['last_name'].'**'.
>> ''.$address['email'].''.
>> ''.$address['phone'].''.
>> ''.$address['address'].''.
>> ''.$this->Html->link('**edit', array('action'=>'edit',
>> 'id'=>$address['id'])).' '.
>>
>> $this->Html->link('delete', array('action'=>'delete',
>> 'id'=>$address['id'])).''**.
>>  '';
>>
>>   };
>> ?>
>> 
>>
>>
>> On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote:
>>>
>>> Error:  Call to a member function find() on a non-object
>>> File:  c:\wamp\www\cake222\app\**Controller\**AddressesController.php
>>>
>>> I get the error on the $this->set('address_list',
>>> $this->Address->find('all')) line below:
>>>
>>> Partial listing of my AddressesController file:
>>>
>>> >> class AddressesController extends AppController {
>>>   var $name = 'addresses';
>>>
>>>  function index($id = null) {
>>> $this->set('address_list', $this->Address->find('all'));
>>>   }
>>>
>>> I have a controller called AddressesController.php.  I have a Model
>>> called Address.php.  The table is called addresses.
>>>
>>> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>>>
>>>
>> --
>> 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
>> "CakePHP" group.
>> To post to this group, send email to cake...@googlegroups.com.
>> To unsubscribe from this group, send email to cake-php+u...@**
>> googlegroups.com.
>> Visit this group at 
>> http://groups.google.com/**group/cake-php?hl=en
>> .
>>
>>
>>
>>
>>  --
> 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
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Russell Brown
When I put debug($this); in the file, however I get a syntax error on that 
line.

I am using Cake 2.2.2 and I have installed the DebugKit too.



On Monday, October 15, 2012 8:27:58 PM UTC-5, Wallace Cardoso Colaço 
Ricardo wrote:
>
> Try to debug what objects(Models) are being loaded...
>
> Doing so you will know for sure the name of the instance Address.
>
> Put this before your find:
>
> debug($this);
>
> On Oct 15, 2012, at 9:23 PM, Russell Brown wrote:
>
> Here is my index.ctp view file in the View\Addresses folder:
>
>  echo $this->Html->link('Add New Address', array('action'=>'add'));
> ?>
> 
>   
>   Id
>   First Name
>   Last Name
>   Email
>   Phone
>   Address
>   Options
>   
>   
>foreach ( $address_list as $line ) {
>   $address = $line['Address'];
> echo
> ''.
> ''.$address['id'].''.
> ''.$this->Html->link($address['first_name'], array('action'=>'view', 
> 'id'=>$address['id'])).''.
> ''.$address['last_name'].''.
> ''.$address['email'].''.
> ''.$address['phone'].''.
> ''.$address['address'].''.
> ''.$this->Html->link('edit', array('action'=>'edit', 
> 'id'=>$address['id'])).' '.
>
> $this->Html->link('delete', array('action'=>'delete', 
> 'id'=>$address['id'])).''.
>  '';
>
>   };
> ?>
> 
>
>
> On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote:
>>
>> Error:  Call to a member function find() on a non-object
>> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
>>
>> I get the error on the $this->set('address_list', 
>> $this->Address->find('all')) line below:
>>
>> Partial listing of my AddressesController file:
>>
>> > class AddressesController extends AppController {
>>   var $name = 'addresses';
>>   
>>  function index($id = null) {
>> $this->set('address_list', $this->Address->find('all'));
>>   }
>>
>> I have a controller called AddressesController.php.  I have a Model 
>> called Address.php.  The table is called addresses.
>>
>> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>>
>>
> -- 
> 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 
> "CakePHP" group.
> To post to this group, send email to cake...@googlegroups.com
> .
> To unsubscribe from this group, send email to 
> cake-php+u...@googlegroups.com .
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>  
>  
>
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Russell Brown
I can't get debug($this) to work in Cake 2.2.2.

It may be different in Cake 2.2.2 but I haven't been able to figure it out. 
 I have installed the DebugKit plugin.

On Thursday, October 18, 2012 12:36:00 PM UTC-5, jsundquist wrote:
>
> The error has nothing to do with your view.  It will have to do with 
> either your model or your controller.  As people have previously stated can 
> you do a debug($this) before and after your find? It will show if the 
> Address model is actually loaded or not.  If its not loaded then your find 
> method will for sure not work.
>
> On Thu, Oct 18, 2012 at 12:09 PM, Russell Brown 
> 
> > wrote:
>
>> Ok.  I changed the index.ctp as shown in the pertinent section of code as 
>> follows (but I still get the same error):
>>
>>  foreach ( $address_list as $line ) {
>>   $address = $line['Address'];
>>  echo
>> ''.
>> ''.$address[0]['id'].''.
>>  /* ''.$this->Html->link($address['first_name'], 
>> array('action'=>'view', 'id'=>$address['id'])).''.
>>  */
>>
>> ''.$this->Html->link($address['first_name'], array('action'=>'view', 
>> 'id'=>$address[0]['id'])).''.
>>  ''.$address['last_name'].''.
>> ''.$address['email'].''.
>>  ''.$address['phone'].''.
>> ''.$address['address'].''.
>>  ''.$this->Html->link('edit', array('action'=>'edit', 
>> 'id'=>$address[0]['id'])).' '.
>>
>> $this->Html->link('delete', array('action'=>'delete', 
>> 'id'=>$address[0]['id'])).''.
>>
>>
>>
>> On Wednesday, October 17, 2012 9:27:07 AM UTC-5, PlanoCoder wrote:
>>>
>>> Pull your Array
>>>
>>> you may need to change
>>>
>>> ''.$address['id'].''.
>>>
>>> to
>>>
>>> ''.$address[0]['id'].''.
>>>
>>> or something like that
>>>
>>>  -- 
>> 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 
>> "CakePHP" group.
>> To post to this group, send email to cake...@googlegroups.com
>> .
>> To unsubscribe from this group, send email to 
>> cake-php+u...@googlegroups.com .
>> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>>  
>>  
>>
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Jonathan Sundquist
The error has nothing to do with your view.  It will have to do with either
your model or your controller.  As people have previously stated can you do
a debug($this) before and after your find? It will show if the Address
model is actually loaded or not.  If its not loaded then your find method
will for sure not work.

On Thu, Oct 18, 2012 at 12:09 PM, Russell Brown wrote:

> Ok.  I changed the index.ctp as shown in the pertinent section of code as
> follows (but I still get the same error):
>
>  foreach ( $address_list as $line ) {
>   $address = $line['Address'];
>  echo
> ''.
> ''.$address[0]['id'].''.
>  /* ''.$this->Html->link($address['first_name'],
> array('action'=>'view', 'id'=>$address['id'])).''.
>  */
>
> ''.$this->Html->link($address['first_name'], array('action'=>'view',
> 'id'=>$address[0]['id'])).''.
>  ''.$address['last_name'].''.
> ''.$address['email'].''.
>  ''.$address['phone'].''.
> ''.$address['address'].''.
>  ''.$this->Html->link('edit', array('action'=>'edit',
> 'id'=>$address[0]['id'])).' '.
>
> $this->Html->link('delete', array('action'=>'delete',
> 'id'=>$address[0]['id'])).''.
>
>
>
> On Wednesday, October 17, 2012 9:27:07 AM UTC-5, PlanoCoder wrote:
>>
>> Pull your Array
>>
>> you may need to change
>>
>> ''.$address['id'].''.
>>
>> to
>>
>> ''.$address[0]['id'].''.
>>
>> or something like that
>>
>>  --
> 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
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-18 Thread Russell Brown
Ok.  I changed the index.ctp as shown in the pertinent section of code as 
follows (but I still get the same error):

 foreach ( $address_list as $line ) {
  $address = $line['Address'];
echo
''.
''.$address[0]['id'].''.
 /* ''.$this->Html->link($address['first_name'], 
array('action'=>'view', 'id'=>$address['id'])).''.
 */

''.$this->Html->link($address['first_name'], array('action'=>'view', 
'id'=>$address[0]['id'])).''.
''.$address['last_name'].''.
''.$address['email'].''.
''.$address['phone'].''.
''.$address['address'].''.
''.$this->Html->link('edit', array('action'=>'edit', 
'id'=>$address[0]['id'])).' '.

$this->Html->link('delete', array('action'=>'delete', 
'id'=>$address[0]['id'])).''.



On Wednesday, October 17, 2012 9:27:07 AM UTC-5, PlanoCoder wrote:
>
> Pull your Array
>
> you may need to change
>
> ''.$address['id'].''.
>
> to
>
> ''.$address[0]['id'].''.
>
> or something like that
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-17 Thread PlanoCoder
Pull your Array

you may need to change

''.$address['id'].''.

to

''.$address[0]['id'].''.

or something like that

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error to load a third Libs

2012-10-16 Thread Lucas Simon Rodrigues Magalhaes
I am using cake2.2

Em terça-feira, 16 de outubro de 2012 11h50min46s UTC-3, MaJerle.Eu 
escreveu:
>
> your file is .class ??..and tell us which cake u use
> --
> Lep pozdrav, Tilen Majerle
> http://majerle.eu
>
>
>
> 2012/10/16 Lucas Simon Rodrigues Magalhaes 
> >
>
>> Hiii, good morning!
>>
>> I have a erro when I try load a third Lib in my controller.
>>
>> The code:
>>
>> App::uses('html2pdf/html2pdf.class', 'Lib'); 
>>
>> App::import('Lib', 'html2pdf/html2pdf.class');
>> pr(App::paths());
>> try{
>> $pdf = new HTML2PDF('P','A4','fr');
>>  $pdf->pdf->SetDisplayMode('fullpage');
>> $pdf->writeHTML($content);
>> $pdf->Output('test.pdf');
>> }
>> catch(HTML2PDF_exception $e){
>> die($e);
>> }
>>
>> The error:
>> Fatal Error *Error: * Class 'HTML2PDF' not found 
>> *Line: * 196
>> *Notice: * If you want to customize this error message, create 
>> app\View\Errors\fatal_error.ctp
>>
>>
>> My folder:
>>
>> Lucas Simon@LUCAS-PC app/Lib/html2pdf (master)
>> $ ls
>> _LGPL.txt   _lisez_moi.txt  exampleslocale
>> _changelog.txt  _read_me.txthtml2pdf.class.php
>> _class  _tcpdf_5.0.002  html2pdf_v4.03
>>
>> -- 
>> 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 
>> "CakePHP" group.
>> To post to this group, send email to cake...@googlegroups.com
>> .
>> To unsubscribe from this group, send email to 
>> cake-php+u...@googlegroups.com .
>> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>>  
>>  
>>
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error to load a third Libs

2012-10-16 Thread Tilen Majerle
your file is .class ??..and tell us which cake u use
--
Lep pozdrav, Tilen Majerle
http://majerle.eu



2012/10/16 Lucas Simon Rodrigues Magalhaes 

> Hiii, good morning!
>
> I have a erro when I try load a third Lib in my controller.
>
> The code:
>
> App::uses('html2pdf/html2pdf.class', 'Lib');
>
> App::import('Lib', 'html2pdf/html2pdf.class');
> pr(App::paths());
> try{
> $pdf = new HTML2PDF('P','A4','fr');
>  $pdf->pdf->SetDisplayMode('fullpage');
> $pdf->writeHTML($content);
> $pdf->Output('test.pdf');
> }
> catch(HTML2PDF_exception $e){
> die($e);
> }
>
> The error:
> Fatal Error *Error: * Class 'HTML2PDF' not found
> *Line: * 196
> *Notice: * If you want to customize this error message, create
> app\View\Errors\fatal_error.ctp
>
>
> My folder:
>
> Lucas Simon@LUCAS-PC app/Lib/html2pdf (master)
> $ ls
> _LGPL.txt   _lisez_moi.txt  exampleslocale
> _changelog.txt  _read_me.txthtml2pdf.class.php
> _class  _tcpdf_5.0.002  html2pdf_v4.03
>
> --
> 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
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-15 Thread Wallace Cardoso Colaco Ricardo
Try to debug what objects(Models) are being loaded...

Doing so you will know for sure the name of the instance Address.

Put this before your find:

debug($this);

On Oct 15, 2012, at 9:23 PM, Russell Brown wrote:

> Here is my index.ctp view file in the View\Addresses folder:
> 
>  echo $this->Html->link('Add New Address', array('action'=>'add'));
> ?>
> 
>   
> Id
> First Name
> Last Name
> Email
> Phone
> Address
> Options
>   
>   
>foreach ( $address_list as $line ) {
>   $address = $line['Address'];
>   echo
>   ''.
>   ''.$address['id'].''.
>   ''.$this->Html->link($address['first_name'], 
> array('action'=>'view', 'id'=>$address['id'])).''.
>   ''.$address['last_name'].''.
>   ''.$address['email'].''.
>   ''.$address['phone'].''.
>   ''.$address['address'].''.
>   ''.$this->Html->link('edit', 
> array('action'=>'edit', 'id'=>$address['id'])).' '.
> 
>   $this->Html->link('delete', array('action'=>'delete', 
> 'id'=>$address['id'])).''.
>   
>   '';
> 
>   };
> ?>
> 
> 
> 
> On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote:
> Error:  Call to a member function find() on a non-object
> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
> 
> I get the error on the $this->set('address_list', 
> $this->Address->find('all')) line below:
> 
> Partial listing of my AddressesController file:
> 
>  class AddressesController extends AppController {
>   var $name = 'addresses';
>   
>  function index($id = null) {
> $this->set('address_list', $this->Address->find('all'));
>   }
> 
> I have a controller called AddressesController.php.  I have a Model called 
> Address.php.  The table is called addresses.
> 
> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
> 
> 
> -- 
> 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 
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to 
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>  
>  

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-15 Thread Russell Brown
Here is what the routes.php file looks like:

 'addresses', 'action' 
=> 'index'));
?>


On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote:
>
> Error:  Call to a member function find() on a non-object
> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
>
> I get the error on the $this->set('address_list', 
> $this->Address->find('all')) line below:
>
> Partial listing of my AddressesController file:
>
>  class AddressesController extends AppController {
>   var $name = 'addresses';
>   
>  function index($id = null) {
> $this->set('address_list', $this->Address->find('all'));
>   }
>
> I have a controller called AddressesController.php.  I have a Model called 
> Address.php.  The table is called addresses.
>
> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-15 Thread Russell Brown
Here is my index.ctp view file in the View\Addresses folder:

Html->link('Add New Address', array('action'=>'add'));
?>

  
  Id
  First Name
  Last Name
  Email
  Phone
  Address
  Options
  
  
'.
''.$address['id'].''.
''.$this->Html->link($address['first_name'], array('action'=>'view', 
'id'=>$address['id'])).''.
''.$address['last_name'].''.
''.$address['email'].''.
''.$address['phone'].''.
''.$address['address'].''.
''.$this->Html->link('edit', array('action'=>'edit', 
'id'=>$address['id'])).' '.

$this->Html->link('delete', array('action'=>'delete', 
'id'=>$address['id'])).''.
 '';

  };
?>



On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote:
>
> Error:  Call to a member function find() on a non-object
> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
>
> I get the error on the $this->set('address_list', 
> $this->Address->find('all')) line below:
>
> Partial listing of my AddressesController file:
>
>  class AddressesController extends AppController {
>   var $name = 'addresses';
>   
>  function index($id = null) {
> $this->set('address_list', $this->Address->find('all'));
>   }
>
> I have a controller called AddressesController.php.  I have a Model called 
> Address.php.  The table is called addresses.
>
> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-15 Thread Russell Brown
Here is the error in the error.log:

2012-10-16 01:16:44 Error: Fatal Error (1): Call to a member function 
find() on a non-object in 
[C:\wamp\www\cake222\app\Controller\AddressesController.php, line 9]
2012-10-16 01:16:44 Error: [FatalErrorException] Call to a member function 
find() on a non-object
#0 C:\wamp\www\cake222\lib\Cake\Error\ErrorHandler.php(162): 
ErrorHandler::handleFatalError(1, 'Call to a membe...', 
'C:\wamp\www\cak...', 9)
#1 [internal function]: ErrorHandler::handleError(1, 'Call to a membe...', 
'C:\wamp\www\cak...', 9, Array)
#2 C:\wamp\www\cake222\lib\Cake\Core\App.php(926): 
call_user_func('ErrorHandler::h...', 1, 'Call to a membe...', 
'C:\wamp\www\cak...', 9, Array)
#3 C:\wamp\www\cake222\lib\Cake\Core\App.php(899): App::_checkFatalError()
#4 [internal function]: App::shutdown()
#5 {main}





On Monday, October 15, 2012 6:58:52 PM UTC-5, Russell Brown wrote:
>
> Error:  Call to a member function find() on a non-object
> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
>
> I get the error on the $this->set('address_list', 
> $this->Address->find('all')) line below:
>
> Partial listing of my AddressesController file:
>
>  class AddressesController extends AppController {
>   var $name = 'addresses';
>   
>  function index($id = null) {
> $this->set('address_list', $this->Address->find('all'));
>   }
>
> I have a controller called AddressesController.php.  I have a Model called 
> Address.php.  The table is called addresses.
>
> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-15 Thread Russell Brown
Ok.  Yes, I did try both commenting it out, deleting it and changing var to 
public.  It didn't get rid of the error though.

On Monday, October 15, 2012 8:03:38 PM UTC-5, Andras Kende wrote:
>
>
> try to comment out 
>
>  var $name = 'addresses';
>
> or change it to:  var $name = 'Address';
>
> Andras Kende
> http://www.kende.com
>
> On Oct 15, 2012, at 4:58 PM, Russell Brown 
> > 
> wrote:
>
> Error:  Call to a member function find() on a non-object
> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
>
> I get the error on the $this->set('address_list', 
> $this->Address->find('all')) line below:
>
> Partial listing of my AddressesController file:
>
>  class AddressesController extends AppController {
>   var $name = 'addresses';
>   
>  function index($id = null) {
> $this->set('address_list', $this->Address->find('all'));
>   }
>
> I have a controller called AddressesController.php.  I have a Model called 
> Address.php.  The table is called addresses.
>
> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>
>
> -- 
> 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 
> "CakePHP" group.
> To post to this group, send email to cake...@googlegroups.com
> .
> To unsubscribe from this group, send email to 
> cake-php+u...@googlegroups.com .
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>  
>  
>
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-15 Thread Russell Brown
Yes I read about the var $name = 'addresses'; line but I also saw that it 
doesn't hurt to have it in there and should actually read:

public $name = 'addresses';

I have tried it with and without the line though and I still get the same 
error.


On Monday, October 15, 2012 7:38:32 PM UTC-5, cricket wrote:
>
> That all looks good to me. Try deleting the files in app/tmp/cache/models 
>
> With PHP5.x you don't need the line var $name = 'addresses'; 
>
> On Mon, Oct 15, 2012 at 7:58 PM, Russell Brown 
> > 
> wrote: 
> > Error:  Call to a member function find() on a non-object 
> > File:  c:\wamp\www\cake222\app\Controller\AddressesController.php 
> > 
> > I get the error on the $this->set('address_list', 
> > $this->Address->find('all')) line below: 
> > 
> > Partial listing of my AddressesController file: 
> > 
> >  > class AddressesController extends AppController { 
> >   var $name = 'addresses'; 
> > 
> >  function index($id = null) { 
> > $this->set('address_list', $this->Address->find('all')); 
> >   } 
> > 
> > I have a controller called AddressesController.php.  I have a Model 
> called 
> > Address.php.  The table is called addresses. 
> > 
> > I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16 
> > 
> > -- 
> > 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 
> > "CakePHP" group. 
> > To post to this group, send email to cake...@googlegroups.com. 
>
> > To unsubscribe from this group, send email to 
> > cake-php+u...@googlegroups.com . 
> > Visit this group at http://groups.google.com/group/cake-php?hl=en. 
> > 
> > 
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-15 Thread Russell Brown
I didn't have any other files in app/tmp/cache/models.  I have an "empty" 
file though.



On Monday, October 15, 2012 7:38:32 PM UTC-5, cricket wrote:
>
> That all looks good to me. Try deleting the files in app/tmp/cache/models 
>
> With PHP5.x you don't need the line var $name = 'addresses'; 
>
> On Mon, Oct 15, 2012 at 7:58 PM, Russell Brown 
> > 
> wrote: 
> > Error:  Call to a member function find() on a non-object 
> > File:  c:\wamp\www\cake222\app\Controller\AddressesController.php 
> > 
> > I get the error on the $this->set('address_list', 
> > $this->Address->find('all')) line below: 
> > 
> > Partial listing of my AddressesController file: 
> > 
> >  > class AddressesController extends AppController { 
> >   var $name = 'addresses'; 
> > 
> >  function index($id = null) { 
> > $this->set('address_list', $this->Address->find('all')); 
> >   } 
> > 
> > I have a controller called AddressesController.php.  I have a Model 
> called 
> > Address.php.  The table is called addresses. 
> > 
> > I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16 
> > 
> > -- 
> > 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 
> > "CakePHP" group. 
> > To post to this group, send email to cake...@googlegroups.com. 
>
> > To unsubscribe from this group, send email to 
> > cake-php+u...@googlegroups.com . 
> > Visit this group at http://groups.google.com/group/cake-php?hl=en. 
> > 
> > 
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-15 Thread Andras Kende

try to comment out 
>  var $name = 'addresses';
or change it to:  var $name = 'Address';

Andras Kende
http://www.kende.com

On Oct 15, 2012, at 4:58 PM, Russell Brown  wrote:

> Error:  Call to a member function find() on a non-object
> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
> 
> I get the error on the $this->set('address_list', 
> $this->Address->find('all')) line below:
> 
> Partial listing of my AddressesController file:
> 
>  class AddressesController extends AppController {
>   var $name = 'addresses';
>   
>  function index($id = null) {
> $this->set('address_list', $this->Address->find('all'));
>   }
> 
> I have a controller called AddressesController.php.  I have a Model called 
> Address.php.  The table is called addresses.
> 
> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
> 
> 
> -- 
> 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 
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to 
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>  
>  

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-15 Thread Russell Brown
Yes, the contents of my Address model is:


> Will you also dump your model file contents
>
> On Mon, Oct 15, 2012 at 7:58 PM, Russell Brown 
> 
> > wrote:
>
>> Error:  Call to a member function find() on a non-object
>> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
>>
>> I get the error on the $this->set('address_list', 
>> $this->Address->find('all')) line below:
>>
>> Partial listing of my AddressesController file:
>>
>> > class AddressesController extends AppController {
>>   var $name = 'addresses';
>>   
>>  function index($id = null) {
>> $this->set('address_list', $this->Address->find('all'));
>>   }
>>
>> I have a controller called AddressesController.php.  I have a Model 
>> called Address.php.  The table is called addresses.
>>
>> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>>
>>  -- 
>> 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 
>> "CakePHP" group.
>> To post to this group, send email to cake...@googlegroups.com
>> .
>> To unsubscribe from this group, send email to 
>> cake-php+u...@googlegroups.com .
>> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>>  
>>  
>>
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-15 Thread lowpass
That all looks good to me. Try deleting the files in app/tmp/cache/models

With PHP5.x you don't need the line var $name = 'addresses';

On Mon, Oct 15, 2012 at 7:58 PM, Russell Brown  wrote:
> Error:  Call to a member function find() on a non-object
> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
>
> I get the error on the $this->set('address_list',
> $this->Address->find('all')) line below:
>
> Partial listing of my AddressesController file:
>
>  class AddressesController extends AppController {
>   var $name = 'addresses';
>
>  function index($id = null) {
> $this->set('address_list', $this->Address->find('all'));
>   }
>
> I have a controller called AddressesController.php.  I have a Model called
> Address.php.  The table is called addresses.
>
> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>
> --
> 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
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Call to a member function find() on a non-object

2012-10-15 Thread Ma'moon
Will you also dump your model file contents

On Mon, Oct 15, 2012 at 7:58 PM, Russell Brown wrote:

> Error:  Call to a member function find() on a non-object
> File:  c:\wamp\www\cake222\app\Controller\AddressesController.php
>
> I get the error on the $this->set('address_list',
> $this->Address->find('all')) line below:
>
> Partial listing of my AddressesController file:
>
>  class AddressesController extends AppController {
>   var $name = 'addresses';
>
>  function index($id = null) {
> $this->set('address_list', $this->Address->find('all'));
>   }
>
> I have a controller called AddressesController.php.  I have a Model called
> Address.php.  The table is called addresses.
>
> I am using Cake 2.2.2 and PHP 5.3.8 and Apache 2.2.21 and MySQL 5.5.16
>
>  --
> 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
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Index.phpController could not be found

2012-10-09 Thread lowpass
It's actually a web server config, not PHP. But I agree it should
probably be in the docs.

On Tue, Oct 9, 2012 at 2:47 PM, Thomas Smith  wrote:
> I'm not new to Cake (so I knew what it should look like), but just did a
> brand-new install of Apache 2.4, PHP 5.3.17, and Cake 2.2.3 on a Windows
> machine.  In addition to the documented steps, I also had to do the
> following to get the Cake main page to display:
>
> Uncomment the LoadModule rewrite_module line in httpd.conf
> Add index.php to the DirectoryIndex line as described above
>
> The rewrite_module stuff is mentioned prominently in the existing
> documentation, but the DirectoryIndex part isn't.  Yes, that's technically a
> PHP configuration but should probably be in the Cake docs anyway.
>
> --
> 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
> "CakePHP" group.
> To post to this group, send email to cake-php@googlegroups.com.
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php?hl=en.
>
>

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error: Index.phpController could not be found

2012-10-09 Thread Thomas Smith
I'm not new to Cake (so I knew what it should look like), but just did a 
brand-new install of Apache 2.4, PHP 5.3.17, and Cake 2.2.3 on a Windows 
machine.  In addition to the documented steps, I also had to do the 
following to get the Cake main page to display:

   - Uncomment the *LoadModule rewrite_module *line in httpd.conf
   - Add *index.php* to the *DirectoryIndex* line as described above

The rewrite_module stuff is mentioned prominently in the existing 
documentation, but the DirectoryIndex part isn't.  Yes, that's technically 
a PHP configuration but should probably be in the Cake docs anyway.

-- 
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 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: Error rendering, is it the intended functionality?

2012-09-18 Thread lowpass
Just to clarify for anyone reading this, adding $useTable = false to
the model is not the solution. Mohammad mentioned that he was testing
"the situation in which DB is shut down" and how Cake would handle it.

I've just confirmed with 2.1.3 that the error page comes up ("Internal
error has occurred") but that the header in my view -- just before the
Form->create() line -- is displayed at the top of the page, just as in
Mohammad's example. So it seems like a buffering problem.


On Tue, Sep 18, 2012 at 12:35 PM, Mohammad Naghavi  wrote:
> lowpass, thats it. the problem is that FormHelper fetches the model data
> inside the view. I don't know why this is the case, but as said, I managed
> to solve the problem but I don't think it should be like that. it will be
> interesting for the Cake developers to know however.
>
> regards,
> Mohammad
>
>
> On Mon, Sep 17, 2012 at 7:41 PM, lowpass  wrote:
>>
>> I think I see the problem. It's not that Mohammad is explicitly
>> querying the DB from the View, but that FormHelper is doing so behind
>> the scenes. It fetches the model's schema. In this case the DB is
>> unavailable and it's not being handled well.
>>
>> It's odd that the error message (inside the H4$ tags) is spit out
>> before even the doctype. Perhaps that's a clue as to what's going on.
>>
>>
>> On Sun, Sep 16, 2012 at 12:43 PM, Léo Willian Kölln 
>> wrote:
>> > Why there is some DB interaction during the View rendering? You dont
>> > need to do any query "explicitly" on the View file, if you are calling
>> > a method that does some DB interaction you are doing a Query during
>> > the View Context.
>> > If you need some data that comes from model (doesn't matter if it is
>> > from DB or not), do it on the controller, setting variables to output
>> > them on the View.
>> >
>> > Can someone confirm my conclusion?
>> >
>> >
>> > Léo Willian Kölln
>> >
>> >
>> > On Sun, Sep 16, 2012 at 7:19 AM, Mohammad Naghavi 
>> > wrote:
>> >> Hi,
>> >> I do no query from inside the View, I just call this:
>> >> $this->Form->create();
>> >> inside my view. the problem is that every thing inside view before this
>> >> line
>> >> comes as a part of the exception handling output.
>> >> what I think is that because I don't call any db or model related
>> >> actions
>> >> inside the controller, the exception is thrown and caught at the point
>> >> that
>> >> form creation is triggered, where the cake tries to connect to db.
>> >>
>> >> anyway I managed to solve my problem using a custom error controller.
>> >> but I
>> >> think it is good for core developers to know the situation.
>> >>
>> >> regards,
>> >> MN
>> >>
>> >>
>> >>
>> >> On Fri, Sep 14, 2012 at 7:57 PM, lowpass 
>> >> wrote:
>> >>>
>> >>> Are you making DB queries from within the View? You should be doing so
>> >>> from the model or controller. Then, once the controller has all the
>> >>> data it requires, it passes it to View to be rendered.
>> >>>
>> >>> On Fri, Sep 14, 2012 at 4:43 AM, Mohammad Naghavi 
>> >>> wrote:
>> >>> > Hi,
>> >>> > I'm dealing with an action of a controller, in which no db
>> >>> > interaction
>> >>> > is
>> >>> > required until it comes to rendering the view. inside the view,
>> >>> > again
>> >>> > first
>> >>> > half of the view doesn't need any db interactions until a form
>> >>> > creation
>> >>> > is
>> >>> > started somewhere in the middle. I'm preparing my app for production
>> >>> > environment so I came to the point to make it clean. there I tested
>> >>> > the
>> >>> > situation in which DB is shut down and pointed the browser to that
>> >>> > action,
>> >>> > what I expected was a single internal error page, but what I got was
>> >>> > a
>> >>> > half
>> >>> > rendered view, which was accompanied with the rendered error layout.
>> >>> > something like following:
>> >>> >
>> >>> > 
>> >>> > some message here
>> >>> > 
>> >>> >
>> >>> >
>> >>> > > >>> > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";>
>> >>> > http://www.w3.org/1999/xhtml";>
>> >>> > 
>> >>> >   > >>> > />
>> >>> >   CakePHP: the rapid development php framework:
>> >>> >   Errors  
>> >>> >   > >>> > />> >>> > href="/itbs/favicon.ico" type="image/x-icon" rel="shortcut icon"
>> >>> > />> >>> > rel="stylesheet" type="text/css" href="/itbs/css/cake.generic.css"
>> >>> > />
>> >>> > 
>> >>> >   
>> >>> >
>> >>> > ...
>> >>> >
>> >>> >
>> >>> > now my question is that how to remove this first part of half
>> >>> > rendered
>> >>> > view?
>> >>> > I tried to set $this->response->body(' '); on beforeRender of the
>> >>> > appController for the case that controller->name is CakeError but it
>> >>> > didn't
>> >>> > work, any other suggestions?
>> >>> >
>> >>> > regards,
>> >>> > MN
>> >>> >
>> >>> > --
>> >>> > You received this message because you are subscribed to the Google
>> >>> > Groups
>> >>> > "CakePHP" group.
>> >>> > To post to this group, send email to cake-php@googlegroups.com.
>> >>> > To u

  1   2   3   4   5   6   7   >