Get browser properties without browscap in php

There are several methods to get browser properties. php get_browser function is very useful as it return many browser properties.but In for get_browser to work, your browscap configuration setting in php.ini must point to the correct location of the browscap.ini file on your system. Continue reading “Get browser properties without browscap in php”

How to find and fix spam script in wp themes and plugins

“No Lunch Is Ever Free, Someone Somewhere Has To Pay For It” absolutely correct!!!!
Be careful while selecting any free Premium WordPress Themes because the theme can be no doubt free but you don’t know if its spam script free too. Else you too will have to invest your time in researching the reasons like me or recovering your losses due to these scam scripts.
Continue reading “How to find and fix spam script in wp themes and plugins”

Survey monkey width issue

SurveyMonkey is popular online survey tool. It’s easier than ever to send free surveys, polls, questionnaires, customer feedback and market research. Plus get access to survey questions and professional templates

Survey monkey width issue

Survey monkey provides full control for its embedding code. But I found some interesting thing in it. My client gave me the issue that survey monkey embed code just breaking his prestashop template. I found survey monkey embed code in CMS

Survey monkey uses Badge script with iframe as I mentioned in the article Php profile badge script for your site

It was its height and width problem .The client doesn’t have the credential of its survey monkey .So i had to find another alternative. The trick is below.

Embed code provided by the survey monkey

If the result does not fit with our layout we can modify the survey monkey iframe code as blow


in above code we replace url
to an another url
where mykey is your server key.

So with the new code you can control the embed code without going into your survey monkey account.


preview form before submit jquery plugin

preview form before submit is a common idea. idea of making such a plugin comes in my mind when i was working on a cake project and client ask me to do it.developer needs such a plugin most of the time and don’t like to write the same code in php js or jquery again and again.

preview before submit

What is it ?

previewForm is a tool for displaying form content before it goes to the server for processing.This plugin provides users to confirm the data before they are going to sumit it.
It was built using the jQuery library. Licensed under both MIT and GPL licenses



  • Preview the value of textbox.
  • Preview the value of selectbox.
  • Preview the value of radiobox and checkbox.
  • Preview password field if option selected.


Example 1 With password preview.

Example 2 with password disable.

How to Use


1. First, make sure you are using valid DOCTYPE and correct form structure.

Your form must contain for tag of label with corresponding id of the field.
sample is

2. Include jQuery and previewForm JS files.

<script type="text/javascript" src=""></script>

<script type="text/javascript" src=”previewForm / previewForm.js"></script>


3. Add previewForm CSS file

4. Fire plugin using jQuery selector

<script type="text/javascript">
$(document).ready(function() {
	$('#myform').previewForm({ show_password : false });


API & Options

Key Default value Description
show_password true Whether you want to show the password field in preview
extratext ‘Do You Want To submit’ Extra text before confirmation buttons
yes yes Button Label for yes button
no no Button Label for no button
title Please preview Title of preview dialog



Notepad ++ crash !! Recover your lost file

What if your notepad++ crash while you are uploading  your file with ftp, and after restart notepad++ you see the file is empty!!!!!!!! I am sure it will make you crazy.This thing happens with me many time. Luckily we have solution if this thing happens to you gain. You can recover your file and its content.

Step 1. When Notepad++ crash

You are uploading file crashes.php, suddenly following screen appears on your window
source code editor has stopped working. i.e notepad ++ crash !!!
notepad++ crashes then recover file

Then do not close the notepad++.

Step 2. Locate the file in Notepad++ Cache

Here is simple shortcut to locate the local copy of the file.
Press WinKey+R . Now in run textbox enter the path below.


source code editor has stopped working

Notepad++ stores the cache data in roaming directory of system.

Step 3.Create backup of the cache file

Now in Cache directory all your edited ftp files present as in live server .
Locate and copy the file crashes.php for backup copy the file on desktop . Rename it to backup_crashes.php .
After creating backup ,you can restart your Notepad++ (GNU) .


Step 4. Recover the file.

Restart Notepad++
connect with your remote server
open the remote file crashes.php again .
if it is blank then copy the content from local backup file(backup_crashes.php) stored on desktop.

So  next time if notepad crashes while uploading then keep these steps in mind.