It's All About Me

make them benefit

How to use callback functions in php frameworks

leave a comment »

Cakephp, Codeigniter, Symphony, Kohana etc all these OOP framework. I feel comfort with cakephp for its wonderful features. BTW – you should be careful when you use callback function like array_filter, array_walk etc inside your code with OOP script, error/wrong may happen for new php programmer. Mistakenly you may call them in wrong way, lets consider the following codes -
Read the rest of this entry »

Written by kodegeek

November 4, 2009 at 3:30 am

Posted in Php

Low disk space issue in windows

with one comment

I use windows xp for my home pc. For the last few days – my life became hell for the low disk space issue. I was trying to find out the culprit. As first step, i’ve deleted temp files (Got temp files From Start Menu>Run, then %temp%). After two/three days, the notification( low disk space) again came. Then i’ve deleted windows updates files which may be useful for rollback, these files are c:/windows/$hf_mig$/ folder and folders like
c:/windows/$NtUninstallKB915865$/
……………………..
…………………….

I’ve deleted them as i didn’t use rollback for any windows update before and no chance for future too ;) . It released a huge space.
Read the rest of this entry »

Written by kodegeek

October 27, 2009 at 10:23 pm

Posted in OS

Drupal error in Mac – shows blank page?

with 2 comments

I played with Mac somtimes before and i love my Mac(mini) but as a windows user it was little tough for me to get into in. Yesterday my OS chrashed(windows sucks), so i think(not sure?) – i will be fulltime Mac user(at office). BTW – i was working on a realty project with drupal with two of my mates using assembla(http://www.assembla.com/) svn. So i got a working copy on my Mac and tried to run it using MAMP. After run it – i saw just a white page!!!
Read the rest of this entry »

Written by kodegeek

October 22, 2009 at 4:33 pm

Posted in CMS, Drupal, Error

Tagged with

10 tips to speed up your ExpressionEngine sites

with 3 comments

1. Cache
Cache, cache and cache. It’s the first step to make your site faster. It’s great news that expressionengine comes with excellent cache features – query cache, tag cache, template cache etc – turn them on.

Query Cache – Query Caching caches the output of your database, saving each query as a text file. When your visitors access your web pages, the cache files are examined to see if the particular queries being requested exist in cached form. If they do, ExpressionEngine uses the cached data instead of querying your database. This provides a significant reduction in your overall database load. The query caching system is completely dynamic.
This feature is found under Admin>Weblog Administration > Global Weblog Preferences.
NOTE: Dynamic weblog query caching will cause weblog queries to not behave as expected when set to: orderby=”random”
Read the rest of this entry »

Written by kodegeek

October 21, 2009 at 2:35 am

Posted in CMS, ExpressionEngine, SEO

New array functions introduced in php5

leave a comment »

Here is the list of new array functions introduced in php5 so far –

array_combine — Creates an array by using one array for keys and another for its values

<?php
$a = array('green', 'red', 'yellow');
$b = array('avocado', 'apple', 'banana');
$c = array_combine($a, $b);

print_r($c);
?>
Array
(
    [green]  => avocado
    [red]    => apple
    [yellow] => banana
)

Read the rest of this entry »

Written by kodegeek

October 20, 2009 at 10:42 pm

Posted in Php

Tagged with