Re: E_STRICT error popping up in production.

2013-06-20 Thread Dakota
Why not just fix the cause of the E_STRICT notice?

On Thursday, 20 June 2013 03:42:11 UTC+2, Chris Cinelli wrote:

 Just to make it clear.  It pops up in the browser. 

 On Wed, Jun 19, 2013 at 6:41 PM, Chris Cinelli 
 chris@formativelearning.com javascript: wrote:

 We are on cakePHP 2.2.1

 I have an E_STRICT error popping in up in production even if CORE_DEBUG = 
 0

 Our error handler in core.php is:

 Configure::write('Error', array(
  'handler' = 'ErrorHandler::handleError',
 'level' = E_ALL  ~E_DEPRECATED,
  'trace' = true
 ));

 Do I need to have 'level' = E_ALL  ~E_DEPRECATED  ~E_STRICT ?
 Why is it not like this by default?

 Best,
Chris

 --Everything should be made as simple as possible, but not simpler 
 (Albert Einstein)
 Read it as: As simple as possible, as complex as necessary
  



 -- 
 Best,
Chris

 --Everything should be made as simple as possible, but not simpler (Albert 
 Einstein)
 Read it as: As simple as possible, as complex as necessary


-- 
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: Can anyone help me with editing post_tags ???

2013-06-20 Thread Lilit
i forgot the view

Edit Topic

?php
echo $this-Form-create('Topic', array('type' = 'file'));

echo $this-Form-input('id', array(
'type'='hidden',
'value' = $topic['Topic']['id']
));

echo $this-Form-input('title', array(
'type' = 'text',
'error' = array('class' = 'error-message'),
'label' = 'Title',
'value' = $topic['Topic']['title']
));

echo $this-Form-input('description', array(
'type' = 'textarea',
'error' = array('class' = 'error-message'),
'label' = 'Description',
'value' = $topic['Topic']['description']
));

$topicTag='';
foreach($editTags as $editTag){
$topicTag.=$editTag['Tag']['title'].' ';
}
echo $this-Form-input('tags', array(
'type'='text',
'error' = array('class' = 'error-message'),
'label' = 'Tags',
'value' = $topicTag
));

so can you help? :(



--
View this message in context: 
http://cakephp.1045679.n5.nabble.com/Can-anyone-help-me-with-editing-post-tags-tp5715315p5715332.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.
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 
 101http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  

 DboSource-__construct(array)http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- ROOT\lib\Cake\Model\Model.php line 
 3417http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  

 ConnectionManager::getDataSource(string)http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- ROOT\lib\Cake\Model\Model.php line 
 1083http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  

 Model-setDataSource(string)http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- ROOT\lib\Cake\Model\Model.php line 
 3443http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  

 Model-setSource(string)http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- ROOT\lib\Cake\Model\Model.php line 
 2698http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  

 Model-getDataSource()http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- APP\Model\Setting.php line 
 16http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  

 Model-find(string)http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- APP\Controller\FunfordayController.php line 
 268http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  

 Setting-updateCache()http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- APP\Controller\FunfordayController.php line 
 47http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  

 FunfordayController-_loadSettings()http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- [internal 
 function]http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  

 FunfordayController-beforeFilter(CakeEvent)http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- ROOT\lib\Cake\Event\CakeEventManager.php line 
 246http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  call_user_func(array, 

 CakeEvent)http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- ROOT\lib\Cake\Controller\Controller.php line 
 670http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  

 CakeEventManager-dispatch(CakeEvent)http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- ROOT\lib\Cake\Routing\Dispatcher.php line 
 100http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  

 Controller-startupProcess()http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- ROOT\lib\Cake\Routing\Dispatcher.php line 
 85http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  Dispatcher-_invoke(FunfordayController, 
CakeRequest, 
 CakeResponse)http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#
  
- APP\webroot\index.php line 
 94http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#→
  Dispatcher-dispatch(CakeRequest, 

 CakeResponse)http://www.locustgrovefamilymedicine.com/funforday/app/webroot/index.php/#



-- 
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: E_STRICT error popping up in production.

2013-06-20 Thread euromark
Yes, for PHP5.3 and higher you need to explicitly eclude estrict now


Am Donnerstag, 20. Juni 2013 03:41:15 UTC+2 schrieb Chris Cinelli:

 We are on cakePHP 2.2.1

 I have an E_STRICT error popping in up in production even if CORE_DEBUG = 0

 Our error handler in core.php is:

 Configure::write('Error', array(
  'handler' = 'ErrorHandler::handleError',
 'level' = E_ALL  ~E_DEPRECATED,
  'trace' = true
 ));

 Do I need to have 'level' = E_ALL  ~E_DEPRECATED  ~E_STRICT ?
 Why is it not like this by default?

 Best,
Chris

 --Everything should be made as simple as possible, but not simpler (Albert 
 Einstein)
 Read it as: As simple as possible, as complex as necessary
  

-- 
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.




Anyone tried installing CakePHP on Google App Engine (since PHP now support)

2013-06-20 Thread Chris G
Just curious as to whether anyone had come across a tutorial on getting 
CakePHP up and running on Google App Engine since php support has come 
online?

-- 
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.




One page with Search/Edit/Add and Delete Buttons

2013-06-20 Thread Mahdi Miad
Hi all,
I am new in CakePHP, I developed some applications before and now I need to 
create my application same as before but with cakePHP, so what I need is 
one page with add,edit,search and delete button, if I click on search 
button I need to call search method and edit button with edit method and so 
on. here is some of my code.
Thanks for your time.

?php


if (isset($this-request-data['Search'])) { 
// call Search method with EmployeeID as a primery key

} else if (isset($this-request-data['Add'])) { 
 // call Add method

}else if (isset($this-request-data['Edit'])) { 
// call Edit method

}else if (isset($this-request-data['Delete'])) { 
// call Delete method
}



echo $this-Form-create('myModel' );

echo $this-Form-input('EmployeeID');
echo $this-Form-input('First Name' );
echo $this-Form-input('Last Name');
echo $this-Form-input('Departement');
echo $this-Form-input('Address'); 
  

echo $this-Form-submit('Search' , array('name' ='Search'  ));
echo $this-Form-submit('Add' , array('name' ='Add'));
echo $this-Form-submit('Edit' , array('name' ='Edit'));
echo $this-Form-submit('Delete', array('name' ='Delete'   ));
 

echo $this-form-end();
?
 

-- 
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: Anyone tried installing CakePHP on Google App Engine (since PHP now support)

2013-06-20 Thread Rachman Chavik
On Wed, 19 Jun 2013 16:57:27 -0700, Chris G wrote:

 Just curious as to whether anyone had come across a tutorial on getting 
 CakePHP up and running on Google App Engine since php support has come 
 online?

Yes,

I have ran Croogo on GAE.  I have turned it off since they offer no free plan 
for CloudSQL.

Two points of interests:
- Your app can't write to file systems: use memcached and SyslogLog engine from 
2.4 branch
- Patch your webroot/index.php:

diff --git a/webroot/index.php b/webroot/index.php
index c1f5520..fef064f 100644
--- a/webroot/index.php
+++ b/webroot/index.php
@@ -92,5 +92,8 @@ if (isset($_SERVER['PATH_INFO'])  $_SERVER['PATH_INFO'] == 
'/favicon.ico') {
 
 App::uses('Dispatcher', 'Routing');
 
+$_SERVER['SCRIPT_FILENAME'] = __FILE__;
+$_SERVER['PHP_SELF'] = 'webroot/index.php';
+
 $Dispatcher = new Dispatcher();
 $Dispatcher-dispatch(new CakeRequest(), new CakeResponse(array('charset' = 
Configure::read('App.encoding';


-- 
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: One page with Search/Edit/Add and Delete Buttons

2013-06-20 Thread Eric Haskins
Im assuming the if() is in your controller not a view file??   


Here is a snip of a view for one of my older apps I am working on updating. 
 I use postLinks like this

?php
if(count($divisions)0){
foreach ($divisions AS $row){
?
tr
td?=$row['Divisions']['name'];?/td
td?=$row['Divisions']['last_updated'];?/td
td
?php echo $this-Form-postLink('Edit', 
array('action' = 'edit', 
$row['Divisions']['division_id']),
array('class'='button blue'));?
?php echo $this-Form-postLink('Delete', 
array('action' = 'delete', 
$row['Divisions']['division_id']),
array('class'='button red', 'confirm' = 'Are you 
sure?'));?
/td
/tr
?php
}
} else {
?
tr
td colspan=5 style=text-align: center;No 
Divisions Configured/td
/tr
?php
}
?

The delete button would then post to the delete() function in the 
controller etc

Eric

On Thursday, June 20, 2013 8:04:03 AM UTC-4, Mahdi Miad wrote:

 Hi all,
 I am new in CakePHP, I developed some applications before and now I need 
 to create my application same as before but with cakePHP, so what I need is 
 one page with add,edit,search and delete button, if I click on search 
 button I need to call search method and edit button with edit method and so 
 on. here is some of my code.
 Thanks for your time.

 ?php


 if (isset($this-request-data['Search'])) { 
 // call Search method with EmployeeID as a primery key

 } else if (isset($this-request-data['Add'])) { 
  // call Add method

 }else if (isset($this-request-data['Edit'])) { 
 // call Edit method

 }else if (isset($this-request-data['Delete'])) { 
 // call Delete method
 }



 echo $this-Form-create('myModel' );

 echo $this-Form-input('EmployeeID');
 echo $this-Form-input('First Name' );
 echo $this-Form-input('Last Name');
 echo $this-Form-input('Departement');
 echo $this-Form-input('Address'); 
   

 echo $this-Form-submit('Search' , array('name' ='Search'  ));
 echo $this-Form-submit('Add' , array('name' ='Add'));
 echo $this-Form-submit('Edit' , array('name' ='Edit'));
 echo $this-Form-submit('Delete', array('name' ='Delete'   ));
  

 echo $this-form-end();
 ?
  


-- 
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.




Problems with Bake tool CakePhk

2013-06-20 Thread CAKEPHP MIRIM
hi guys, I have problems in using the tool bake CakePHP at the time of use 
in the generation of CRUD the command prompt that informs not found a 
database 'default', and he does not find the database that was created 
within the standards set by CakePHP, so he concludes the command and does 
not generate CRUD.
pouder who help me thank you very much.
earned.

-- 
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.




Call function in form before save

2013-06-20 Thread Renato Bigliazzi
I have a form with some field. However there is a field that needs to be 
used as argument to a function to return a result before being saved in the 
database. Following issues:

1) Where to declare the function that returned the result to be saved in 
the database?
2) How to call this function?

Thanks

-- 
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.




Problems with tool Bake CakePhp

2013-06-20 Thread CAKEPHP MIRIM
hi guys, I have problems in using the tool bake CakePHP at the time of use 
in the generation of CRUD the command prompt that informs not found a 
database 'default', and he does not find the database that was created 
within the standards set by CakePHP, so he concludes the command and does 
not generate CRUD.
Who can help me thank you very much.
earned.

-- 
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: E_STRICT error popping up in production.

2013-06-20 Thread Chris Cinelli
Sure Dakota, I can (and I did) fix the error but it was actually happening
only in some edge cases. I would prefer that the user do not see these
problem.

I though that one of the point of CORE_DEBUG=0 was not to output the errors
to the users and send them only to the log and with CORE_DEBUG  0 I should
see the error on the browser so I can quickly catch them and fix them.

So, just to confirm: to prevent the users to see the strict error
*and*having the errors logged in the  log, I *JUST* have to modify the
error
configuration with:
 'level' = E_ALL  ~E_DEPRECATED  ~E_STRICT  ?
I am asking because that changes seems that I am going to see the error
neither on the screen nor in the logs.

Best,
Chris

On Thu, Jun 20, 2013 at 3:57 AM, euromark dereurom...@gmail.com wrote:

 Yes, for PHP5.3 and higher you need to explicitly eclude estrict now


 Am Donnerstag, 20. Juni 2013 03:41:15 UTC+2 schrieb Chris Cinelli:

 We are on cakePHP 2.2.1

 I have an E_STRICT error popping in up in production even if CORE_DEBUG =
 0

 Our error handler in core.php is:

 Configure::write('Error', array(
  'handler' = 'ErrorHandler::handleError',
 'level' = E_ALL  ~E_DEPRECATED,
  'trace' = true
 ));

 Do I need to have 'level' = E_ALL  ~E_DEPRECATED  ~E_STRICT ?
 Why is it not like this by default?

 Best,
Chris

 --Everything should be made as simple as possible, but not simpler
 (Albert Einstein)
 Read it as: As simple as possible, as complex as necessary

  --
 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.






-- 
Best,
   Chris

--Everything should be made as simple as possible, but not simpler (Albert
Einstein)
Read it as: As simple as possible, as complex as necessary

-- 
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.