Skip to main content


Showing posts from December, 2013

Interesting features of GMAIL Address

Here are some interesting features of your GMAIL Address

Gmail allows you to put dots (.) in your gmail account but this dots are ignored by the mail server.
For example, If your email address is "", the emails addressed to or will reach the inbox of

MySQL query to retrive only one record for a repeating column or rows of data

MySQL query to retrive only one record for a repeating column or duplicate rows of data

Suppose there is a table tbl_BOOKS which stores records of various books. some books comes under different categories. so there may be multiple records with same BookReferenceNumber. But when user searches for a particular reference number, the search result should display only one record eventhough there are multiple entries for same BookReferenceNumber.

Let us illustrate this with a sample table given below:

How to loop through the items in a select box using Javascript?

Looping through the items in a select box using JS

Use the code given below to parse through the options in a select box and alert the Text and Value of each options. you can alter the function as per your need.

sample code is given below:

<select id="test" name="test">
<option value="First Value" >First Text</option>
<option value="Second Value" >Second Text</option>
<option value="Third Value" >Third Text</option>
<option value="Fourth Value" >Fourth Text</option>
<option value="Fifth Value" >Fifth Text</option>

<input type="button" value="Check" onclick="loopSelectBox('test')" >

function loopSelectBox(selectBoxId){

var obj=document.getElementById(selectBoxId);
for(i=0; i < obj.options.length ;i++){

alert("Value : " + obj.options[i].value + " -…

How to fix the problem in displaying french accented characters from Mysql table on a PHP page?

In a php page I am displaying some hard coded french  texts which has some accented characters like "é è ..." and also some french characters are fetched from Mysql table and displayed on the page.

Here the problem was the hard coded french characters were displaying fine, but the characters fetch from db was not showing properly. It was displaying like "?" with in a black background.

How to check character set of a mysql table?

You can check the character set of Db, tables, columns by using following


check the Collation column value corresponding to field name


will list all the tables, and the collation column contains details about the character set that each table uses



and enter,

show variables like "character_set_database";
show variables like "collation_database";

Tips for staying safe while using Internet

Here are few tips for staying safe while using Internet.

Keep your browser and its plugins updated as most the malwares affects through outdated browser plugins

Use super strong keywords that are not guessable. Use a combination of Alphanumerals (both lower and upper case) and special characters

Use a different password for each account. Do not use your personal information in passwords and never share it with others.

Make sure that the site you are using is the correct one. Incase of using banking sites confirm whether you are using the correct urls epically when submitting your login credentials.

Urgent Openings for PHP trainees, Andriod / IOS developers and PHP developers in Kochi Trivandrum Calicut and Bangalore. Please Send Your updated resumes to   Read more »
Search This Blog