Last month @ SANIsoft blog September 1, 2010

  • [CakePHP] How to re-size images at run-time
    This is a helper + controller combo for CakePHP which I often use. It helps to re-size images at run-time and also aid display them. Oh yes! once the image is resized it also caches them. First let’s look at helper method. PLAIN TEXT PHP: class MyHelper extends AppHelper {     function getImageUrl($path, $size, […]
  • SQL data source in Sphinx
    These days I am getting more and more into Sphinx and falling in love with it . In this post we will see how to make use of SQL data source to create indexes. Sphinx has inbuilt support for MySQL and PostgreSQL databases. The drivers for these databases can connect to the database using its […]
  • Namespaces in PHP 5.3 – Part 2
    Welcome back! In Part 1 of this post we discussed how to create namespaces and use them for classes, functions and constants. If you have not read Part 1 I strongly recommend you read it before we move on to some of the advanced parts related to namespaces. Lets start from where we had left. […]
  • Adding security to your CakePHP application – Part 2
    In the Part 1 of this post, we’ve discussed how to secure your CakePHP application by following some thumb rules and using Sanitize class. Now, in the second part, we’ll discuss how to add some more security to your application by using the nice Security component of CakePHP. Before coming down to the nitty-gritty of […]
  • [iPhone] Parsing RSS with NSXMLParser
    One of the test apps I created while learning iPhone development was a FeedReader app using UITabbarController. Using TabbarController in combination with NavigationController, TableViewController and WebViewController was challenging enough for someone who just began with iPhone development. But more on that later … One of the problems I faced in this app was parsing the […]

Last month @ SANIsoft blog August 1, 2010

  • [Zend Framework] Slug filter
    While studying for my Zend Framework certification, I tried to build a small application to test my knowledge. One of the tasks in that project was to try and build a slug filter which converts a particular string to slug, for example, ‘My Test String’ to ‘my-test-string’. It also checks for slug duplication if you […]
  • Namespaces in PHP 5.3 – Part 1
    One of the most significant and welcome features added in PHP 5.3 was that of namespaces. While this has been around in other programming languages, namespaces have finally found their place starting with PHP 5.3. If you are not new to namespaces and have worked on them in other languages don’t go away, you might […]
  • [HowTo] Google Calendar API : PHP – Manage events (Part 3)
    Earlier we saw how to install Zend’s GData library and retrieve list of calendars and events. Now its time to manage events i.e. create, update and delete events. First we need the Calendar service instance, so lets instantiate the Zend_GData_Calendar class. PLAIN TEXT PHP: $path = ‘/home/abbas/ZendGdata/library’; $oldPath = set_include_path(get_include_path() . PATH_SEPARATOR . $path); require_once […]
  • Adding security to your CakePHP application – Part 1
    Ben Parker once advised his young nephew Peter, whose super-hero alter ego is Spider-man, that “With great power comes great responsibility.” CakePHP framework provides us a rich tool-set to build high performance web applications. The applications built using CakePHP are secure at much extent as long as it comes with some nice features such as […]