Category Covered

How to Create HTML Links in CakePHP  

How to Create HTML Text Links in CakePHP
<?php echo $html->link(My Text', 'URL'); ?> 
How to create an external link in Cakephp
  <?php echo $html->link('CakeBook', 'http://cakephp.org'); ?>
Now if you want to include a css on that link you can edit the code like- <div><?php echo $html->link('CakeBook', 'http:// cakephp.org', array('class'=>myclass)); ?><
 
By: mimosa  |   Total Read: 2099  |   Read more..

Cakephp cache on query  

To implement cache on find query or on other query just follow the step. At first edit core.php and add the following code Cache::config('longterm', array(    'engine' => 'File',    'duration' => '+1 week',    'probability' => 100,    'path' => CACHE . 'longterm' . DS, )); You can add duration on several things like +1 week, +1 hours, +30 days etc.   Now its time to implement c
 
By: Tech writer  |   Total Read: 658  |   Read more..

How to start stop apache tomcat  

if you are using extracted tomcat then go to your bin directory inside Tomcat directory  /Tomcat_Dir/bin

and once you are in the folder I enter: ./startup.sh
And to stop the server, I navigate to the same directory and enter: ./shutdown.sh   Thats it. if tomcat is installed then /etc/init.d/tomcat5.5 start
/etc/init.d/tomcat5.5 stop
/etc/init.d/tomcat5.5 restart
 
By: Tech writer  |   Total Read: 1002  |   Read more..

How to check tomcat versions  

The following command will help you to find the current apache tomcat versions   sh version.sh mkyong@mkyong-desktop:/usr/share/tomcat5.5/bin$ sh version.sh This will return the current apache tomcat version Server version: Apache Tomcat/5.5
 
By: Tech writer  |   Total Read: 963  |   Read more..

PHP Shorthand If Else condition  

Here is the simple example of php if else conditions   $var = '1'; if ($var == "1") { echo "Yes"; } else { echo "No"; } Here is the ternary example of php if else conditions   echo $output = ($var) ? 'Yes' : 'No';
 
By: Tech writer  |   Total Read: 780  |   Read more..

Cakephp not equal condition  

Here is the example of cakephp not equal conditions   array('User.group_id !='=>'18')
 
By: Tech writer  |   Total Read: 2853  |   Read more..

Cakephp find conditions  

Name   Default Description type   'first' can be 'all', 'first', or 'list'. determines what type of find operation to perform. conditions   array containing the find (select) conditions as key/value pairs fields
 
By: Tech writer  |   Total Read: 2061  |   Read more..

CakePHP Controller properties methods callbacks  

CakePHP controller properties:
$name = null
$action = null
$autoLayout = true
$autoRender = true
$base = null
$beforeFilter = null
$cacheAction = false
$components = array()
$data = array()
$helpers = array('Html')
$here = null
$layout = 'default'
$output = null
$pageTitle = false
$params = array()
$persistModel = false
$plugin
 
By: Tech writer  |   Total Read: 741  |   Read more..

CakePHP recursive tutorial  

Cakephp recursion tutorial -1 Cake fetches Group data only, no joins. 0 Cake fetches Group data and its domain 1 Cake fetches a Group, its domain and its associated Users 2 Cake fetches a Group, its domain, its associated Users, and the Users’ associated Articles Example $this->Model->recursive = -1;   Next Step: Cakep
 
By: Tech writer  |   Total Read: 982  |   Read more..

CakePHP association models  

CakePHP association or relationship between models   Relationship    Association Type       Example one to one      hasOne                 A user has one profile. one to many     hasMany              &
 
By: Tech writer  |   Total Read: 1026  |   Read more..
Top 15 Posts
Google+