My standard debugging tool when using PHP is xdebug. Pairing xdebug with Komodo gives me a very productive environment for building PHP applications. However, testing an application code on a hosted server can be many times frustrating as one has only the print_r and var_dump functions at our disposal. What I need is a library that I can easily install on the server and start using.
Read More

Being primarily a developer, designing a web page is not my forte. I usually design web pages using notepad++ and a browser. Although I use grid support, many times I just wish for a simple overlay guide which I can use to layout the different web components. Recently I found one with RulersGuides.js.
Read More

Processing file uploads in node.js

Posted in: nodejs |  

23 Aug 2013
node_file_uploads

One of the important elements of a web application is form processing and file uploads. PHP has excellent support for these kind of things which makes it so popular with developers.
Programmers moving to node.js find that it does not have an easy way to process uploaded files. However some excellent node modules can make it extremely easy to handle file uploads in node.js.
Read More

verbalexp

Most newbie (and some seasoned) programmers have difficultly constructing Regular Expressions. Many a times one needs to create a Regexp quickly to test a a particular piece of code. However, not being comfortable withe Regexps can be a problem. VerbalExpressions is a PHP library that enables you to construct regular expressions using natural language like constructs. Think of it like a DSL for building Regexps.
Read More

Pretty error display for PHP

Posted in: php |  

14 Jul 2013

One of my pet peeves regarding PHP is the terseness of the error messages it throws. Not that they are unhelpful; the major headache it that one has to open the source file at the given error location to check for problems. Also the complete system context (the PHP system variables, cookies, session etc.) is not easily available.
Read More

In a non-strict MySQL server mode, columns with NOT NULL and without any DEFAULT values are given implicit default values based on their data types. This can be useful when no values are explicitly set for them during a SQL INSERT. However this can be recipe for disaster if the MySQL server is later configured for strict mode. The following are the general rules governing implicit default column values:
Read More

StrikeIron sales tax addon for cs-cart

Posted in: web |  

28 Jun 2013

CS-Cart is one of the premium shopping platform for building ecommerce sites. As with any ecommerce solutions CS-Cart includes various tax features. However, one important feature it lacks is sales tax. For a recent client work I needed to integrate the sales tax api from StrikeIron, which provides a cloud-based Data Quality Suite including email verification, address verification, phone validation, phone append, and sales tax calculation solutions. For those who may be interested in implementing sales tax for their CS-Cart installation I’ve provided the addon for download below. A sample screnshot of the tax screen is given below.
Read More

With the recent release of Laravel 4, PHP developers have at their disposal one of the finest frameworks for application development. As with all new frameworks, it is always good to write some quick code to get a feel for the underlying architecture. The following post shows a simple authentication application using Laravel.
Read More

Recently, Google introduced Schemas in Gmail messages to allow developers to deliver a more interactive email experience integrated with their web app. Schemas in emails can be used to represent various types of entities and actions. Email clients that understand schemas, such as Gmail, can render entities and actions defined in the messages with a consistent user interface. In the case of Gmail, this means that the emails can display quick action buttons that let users take actions directly from their inboxes, essentialy allowing them to tie their web app with Gmail for a more integrative experience.
Read More

By default, Laravel is configured to create daily log files for your application, and are stored in app/storage/logs. All Laravel logging features are handled by the wonderful MonoLog library. Monolog includes various log handlers you can use – FirePHP, ChromePHP, CouchDB, Stream and many more. One of my favorites is FirePHP while debugging PHP apps.
Read More