Technology

Git Stash : A very useful command

We have been using GitHub for version control in one of our projects and I am absolutely loving it! There are quite many advantages over a concurrent version control system like subversion. One of the commands I found useful was the stash command. It is of use when we are working on a piece of […]

Node.js

Add Page number using Page Property of CSS

In my recent Nodejs project, we were required to generate the pdf document from HTML page. We are using iText renderer for doing this. The client had the requirement that each page bottom right needed to have a number on it. All these things need to be replicated on every page. So for doing this we […]

Grails

Handling Password Protected Pdf with PdfReader

In one of our grails project , we had to attach cover to Pdf file . But since some of pdf’s uploaded were password protected. To handle this scenario we added bouncyCastle.jar , so our version of iText was able to handle password protected pdf . And Then to check whether pdf is password protected […]

Technology

MySql : Publish results of a query to a text file

A while back I was trying to debug an error in our application logic. For that I had to analyze the results of a query This analysis was getting pretty tough to do on the command line. So, I tried to find a way to transfer the results of a query to a text file […]

Technology

JavaScript Profiling through Firebug’s Console API.

Sometimes we want to know which line of codes or methods in the JavaScript is taking time which slows up the page load. Many times our browser gets hanged due to the execution of JavaScript. Firebug allows us to profile the JavaScript. Following are the two methods that are used for profiling JavaScript: console.profile() console.profileEnd() […]

Grails

Image comparison

In one of our projects, we need to compare images which comes from various sources and remove the duplicate one. The below algo helps us to remove the duplicate images. boolean compareImage(String firstPhotoUrl, String secondPhotoUrl) { boolean result = true; BufferedImage bi1 = ImageIO.read(new URL(firstPhotoUrl)) BufferedImage bi2 = ImageIO.read(new URL(secondPhotoUrl)) int size1 = bi1.getData().getDataBuffer().size; int […]

Grails

Images rotation and div rotation by CSS Transforms

The CSS transform property allows developers to rotate, scale, and skew blocks of HTML via CSS. Although you can do the same thing with images in Photoshop or The GIMP, using CSS transforms allows developers to do the same thing with any HTML markup and allows users to select the text within the transformed object. […]

Umar
Umar
Read

Grails

QR Code on PDF Documents for Identification and Detection on Server Side

In one of our projects, we needed to include QR Code on the PDF documents, which were to be sent out to the user and the printed version was to be received back from them. Once the documents were received, we were going to scan each sheet into an image file and then, these files […]

GrailsTechnology

What is Google Web Optimization, How to use or apply it in your project?

Recently as part of POC, I need to apply the Google web optimizer on various parts of the page to determine which content user clicked to best and will be most effective in getting conversions. For this you need to keep track of the various conversions, but how? That’s where Google web optimizer come handy, providing […]