Magento direct download link



Where you need to replace:

  • <pre class="brush: php; title: ; notranslate" title=""><version></pre>
    : with the full version number string, that is e.g.




  • <pre class="brush: php; title: ; notranslate" title=""><ext></pre>
    : with the format you want, so either






Create Virtual Printer for Windows and Mac

Recently , i came across a requirement to Create Virtual Printer for Windows and Mac.

So i am sharing my findings with you.

Best solution is to

  1. Create Virtual Printer in JAVA , so that it will work on both Windows and Mac.
  2. Use C++ to create Virtual printer , which non-hardware based printer.This will convert your word , test file in to PDF or any other file extensions. For windows i found good solution is ,
  3. For Mac, are useful links.
  4. Virtual Printer SDK for Windows 7, Windows 8, C++, C#, Delphi, VB.NET, VB. Royalty free

I hope this will helpful , enjoy.



OCR Tools

Recently , in some of the task , we need to do R&D on following

  1. Multiple scanned images to multipage PDF
  2. Multipage PDF to multiple images
  3. PDF to searchable PDF
  4. PDF to text
  5. Images to text
  6. File meta-tagging (add properties)

I have done much R&D on the same ,

we found that Linux has the capability to do all of the above.


  1. GOCR

GOCR is a command line tool for text recognition, which since 2000 by Joerg Schulenburg {En} / {En}is developed. The program is to configure “trainable” and varied, good results are obtained especially for sans-serif fonts. This is purely a character recognition program that works talked-independent. With GOCR tcl also a graphical user interface, which is not quite up to date exists. By default, xsane GOCR as text recognition program, with OcrGui some of the options can be used in a graphical user interface. Many OCR frontends can GOCR use (eg: ocrodjvu , OCRFeeder , gscan2pdf ).


:/var/www/ocr_images$ <b>exiftool -v</b>

Syntax:  exiftool [OPTIONS] FILE

Consult the exiftool documentation for a full list of options.

exiftool -Title=prags -Author=prags -Subject=testsubject -Keywords=Suraj,navin,jigar,prags INPUTFILENAME.jpg
/var/www/ocr_images$ exiftool 1.gif

Out put

ExifTool Version Number         : 8.60

File Name                       : 1.gif

Directory                       : .

File Size                       : 12 kB

File Modification Date/Time     : 2014:02:26 18:40:37+05:30

File Permissions                : rwxrwxrwx

File Type                       : GIF

MIME Type                       : image/gif

GIF Version                     : 89a

Image Width                     : 640

Image Height                    : 480

Has Color Map                   : Yes

Color Resolution Depth          : 1

Bits Per Pixel                  : 1

Background Color                : 0

XMP Toolkit                     : Image::ExifTool 8.60

Subject                         : testsubject

Title                           : prags

Author                          : prags

Keywords                        : Suraj,navin,jigar,prags

Image Size                      : 640x480



sudo apt-get install libimage-exiftool-perl


convert command


V 0.1.4

pdfocr   is a program that allows, from scanned PDF to make templates searchable documents. The in Ruby wrote script engages the text recognitionby default on the OCR program tesseract-ocr , optional Cuneiform Linux , or OCRopus   , back and used for merging the original with the text recognitionhocr2pdffrom Exact Image . Also, come pdftk and pdfimages used.

-i, –input [FILE]               Specify input PDF file

-o, –output [FILE]              Specify output PDF file

-t, –tesseract                  Use tesseract as the OCR engine (default)

-c, –cuneiform                  Use cuneiform as the OCR engine

-p, –ocropus                    Use ocropus as the OCR engine

-l, –lang [LANG]                Specify language for the OCR software

-w, –workingdir [DIR]           Specify directory to store temp files in

-k, –keep                       Keep temporary files around

-h, –help                       Show this message

-v, –version                    Show version

$pdfocr -i 3_nonserach.pdf -o 3_searchable.pdf


tesseract 3.02

tesseract-ocr {En} is a command line program for text recognition . Originally from Hewlett Packard developed as a commercial program 1984-1995, the code was released in 2005. The development is supported by Google as an open source solution for creation of e-books was needed. The program supports a number of Western European and Asian languages ??such as Vietnamese. tesseract-ocr is a pure character recognition program, it does not provide layout analysis, and are plain text, version 3.00 also HOCR from. The text recognition can be “trained”.


//LINUX  ==> MUTIPLE IMAGES TO MULTI PAGE PDF (Page of PDF will be depend on number of input images)

convert -adjoin p1.jpg p2.jpg -quality 100 1_merged.pdf


convert -density 500 1_merged.pdf 1_split.jpg

linux covert

WordPress – redirecting the user for restricting the author archive pages

Below is the function for redirecting the user for restricting the author archive pages, please add to current_theme/functions.php, this will redirect to the home url.

function author_archive_redirect() {

if( is_author() ) {

wp_redirect( home_url(), 301 );




add_action( 'template_redirect', 'author_archive_redirect' );

Special Thanks : Supriya Surve

Dumping MySQL Stored Procedures, Functions and Triggers

MySQL 5 has introduced some new interesting features, like stored procedures and triggers. I will show in this small post how we can backup and restore these components using mysqldump.

mysqldump will backup by default all the triggers but NOT the stored procedures/functions. There are 2 mysqldump parameters that control this behavior:

  • –routines – FALSE by default
  • –triggers – TRUE by default

This means that if you want to include in an existing backup script also the triggers and stored procedures you only need to add the –routines command line parameter:

mysqldump <other mysqldump options> --routines outputfile.sql

Let’s assume we want to backup ONLY the stored procedures and triggers and not the mysql tables and data (this can be useful to import these in another db/server that has already the data but not the stored procedures and/or triggers), then we should run something like:

mysqldump --routines --no-create-info --no-data --no-create-db --skip-opt <database> > outputfile.sql


MySQL Split String Function

Split delimited strings

The following example function takes 3 parameters, performs an operation using an SQL function, and returns the result.


  x VARCHAR(255),
  delim VARCHAR(12),
  pos INT
       LENGTH(SUBSTRING_INDEX(x, delim, pos -1)) + 1),
       delim, '');


SELECT SPLIT_STR(string, delimiter, position)


SELECT SPLIT_STR('a|bb|ccc|dd', '|', 3) as third;

| third |
| ccc   |

Thanks to :

Javascript / Jquery Session Logout Timer Clock for Ideal user, which will reset again on mousemove or keyboard action

It took me a little long to get this , which i wanted.

This is made up of simple Jquery and CSS.

I have mixed up few things which i got from internet and after modifications and merging , i got what i want.

Hope This might help you.


working example :


and code is below



<script type="text/javascript" src="jquery.min.js"></script>
<style type="text/css">
br { clear: both; }
.cntSeparator {
font-size: 54px;
margin: 10px 7px;
color: #000;
.desc { margin: 7px 3px; }
.desc div {
float: left;
font-family: Arial;
width: 70px;
margin-right: 65px;
font-size: 13px;
font-weight: bold;
color: #000;
#expireDiv {
width: 90%;
text-align: center;
background-color: #63AFD0;
padding: 10px;
margin: 0;
border: 1px solid #024A68;
color: #024A68;
font-weight: bold;
font-size: 125%;
box-shadow: -1px -1px 5px 1px #5E8C9E inset;
-moz-box-shadow: -1px -1px 5px 1px #5E8C9E inset;
-webkit-box-shadow: -1px -1px 5px 1px #5E8C9E inset;
cursor: pointer;
color: green;
color: red;
color: #024A68;
<script type="text/javascript">
var total_session_time = 5; // after this interval of time if user is ideal then clock timer will start in seconds
var clock_timer = 5; //seconds
var clock_time_start = total_session_time+clock_timer+1;
document.write("<h3>Demo of Session Logout Timer Clock for Ideal user, which will reset again on mousemove or keyboard action</h3><p class='pk'>After <span class='pk1'>"+total_session_time+" Seconds </span>, Session Clock will appear , which will remain for <span class='pk1'>"+clock_timer+" Seconds</span> and if user unable to perform any mousemove , keyboard action it will redirected to logout</p>");
var idleTime = 0;

$(document).ready(function () {
//Increment the idle time counter every minute.
var idleInterval = setInterval("timerIncrement()", 1000); // 1 minute
//Zero the idle timer on mouse movement.
$(this).mousemove(function (e) {
idleTime = 0;
$(this).keypress(function (e) {
idleTime = 0;

});//document ready

function timerIncrement() {
idleTime = idleTime + 1;
if (idleTime > total_session_time) {
count= clock_time_start - idleTime;
if (count <= 0)
window.location = 'logout.php'


<div id="expireDiv">
Your session is about to expire. You will be logged out in <span id="currentSeconds"></span> seconds.
If you want to continue, please move mouse or type something.



1 2 3 25