Sunday, June 28, 2009

Google Voice gives One number for all your phones


These days most of the people are having many phone numbers such as Mobile number, Home number and Work number.

It is bit difficult to manage calls from all these numbers.

For example if you are at your Office and someone is calling to your Home number you will be missing to attend that call.

Google is releasing a Phone Management System to resolve these types of problems easily. This Phone Management System is named as Google Voice. It was developed by improving GrandCentral.

It uses voice over internet protocol (VoIP) to link many phones together.

So, now using Google Voice you can just use One Single number for all of your phones.

Whenever a person calls your single number, your mobile or home phone or work phone will ring based on your setting in the Google Voice.

Google Voice works with mobile phones, desk phones, work phones, and VoIP lines. There's nothing to download, upload, or install.

Google Voice uses information from your address book to tell you who's calling. If the caller isn't in your contacts list, Google Voice can ask for their name and play it back for you when you pick up.

Apart from this single number service Google Voice is having many features such as converting voice mail into text and conference call.

Find below the complete list of Google Voice features.

  • A single Google number for all user's phones.

  • Free calls and SMS in the contiguous US.

  • Call screening. Announce callers based on their number or by an automated identification request for blocked numbers.

  • Listen in on someone recording a voicemail before taking a call.

  • Block calls.

  • Send, receive, and store SMS online.

  • Answer an incoming call on any of your phones.

  • Phone routing. Particular phones can ring based on who calls.

  • Forwarding phones.

  • Voicemail transcripts. Read voicemails online.

  • Listen to voicemail online or from a phone.

  • Receive notifications of voicemails via email or SMS.

  • Personalized greeting that vary greetings by caller.

  • The ability to forward or download voicemails.

  • Conference calling.

  • Record calls and store them online.

  • Switch phones during a call.

  • View the web inbox from a mobile device/phone.

  • Set preferences for contacts by group.



Google Voice is free and also currently it is ad-free. But at this time Google Voice is available in U.S only. I am just thinking whether Google will provide it to all Countries step by step, or any technical/political difficulties are there to prevent implementing it in all countries.

And also it is now provided to limited people only based on invitation. You can apply here for getting invitation.

Some people are questioning privacy and reliability of this phone management system.

Read below links to know about what other people/blogs are telling about Google Voice.




More Articles...

Read more ...

CellPhones will act as Credit Card by next Year.


HÃ¥kan Djuphammar Vice president of Ericsson, predicted at a forum in Stockholm that cell phones will be equipped with NFC(Near Field Communication) technology within a year for using CellPhone as Credit Card.

Already existing Contact-less Credit cards are working based on radio frequency identification (RFID) which is basically one-way communication system.

This RFID was initially devised during Second World War for distinguishing friendly air crafts from enemy aircrafts.

Now, RFID tags are used in many fields such as retail stores, shipment tracking, identifying people and animals.
NFC(Near Field Communication) is the improved version of RFID. It will be two way and bio-directional communication system.

So it will help to improve the security when using cellphone as Credit Card.

Mobile user location data and IP mapping can be used to make sure whether the cellphone (I-e credit card) is used genuinely.

These NFC mobiles can be used as Door Keys and Theater Tickets also.

It seems already some banks in New York are implementing this NFC system in trial basis.


More Articles...

Read more ...

Saturday, June 27, 2009

Get Tweet to know when ISS (International Space Station) will pass your location


Would you like to know what the next time is the Internationale Space Station (ISS) will fly over in your location?

All you need to do is follow the Twitter account @twisst

It will sent you personalized alerts as tweet to you based on your location specified in your Twitter profile either as text or as coordinates.

This online Service is built by Dutch science reporter Govert Schilling and journalist Jaap Meijers.

How Twisst works?



1. Twisst collects location details of Twitter users following @twisst.
2.It uses Google Map and Yahoo to get geographic coordinates for the location of Twitter users..
3.Twisst uses www.heavens-above.com to see when ISS will fly over at those coordinates.
4.geographic database Geonames will be referred to get the local time of Twitter followers.
5.So, every time the International Space Station is coming, Twisst will send alert to Twitter followers in their local time.



The International Space Station serves primarily as a research laboratory .
As of Today, ISS is the largest artificial satellite in Earth orbit.
This project was jointly done by many organizations including NASA (USA), RKA (Russia), JAXA(Japan).

The space station can be seen from Earth with the naked eye.



You can see the recent scenes from ISS here.


More Articles...
Read more ...

Friday, June 26, 2009

Google announces Dashboard for providing detailed metrics on traffic to local listings on Google Maps


Google has announced an Analytic Dashboard for providing detailed metrics on traffic to local listings on Google Maps.

Google says it is providing this kind of data to the Business Owners first time.

It will help you as the Business Owners to understand,

  • How many times your listing appears in Google.com or Google Maps local search results

  • what search queries lead users to your listing

  • what zip codes customers come from when they search for directions to your location.



You can refer this blog for more details.

For those who are not familiar with Google Local Business Center,

If you search "bank" in Google you will be getting below search results. Here, you can see the local business results for bank which will show the address/phone of all the banks available in your area. And also it will show the map for the bank address.



The business owners have to submit their address and any other details to Google Local Business center for including their business address in Google search result.

To avoid unauthorized listing, Google will activate the listing only after doing verification either thro' phone or thro' postal mail.

Google will be sending PIN number thro' postal mail to verify the address if we select Postal mail option.


I am curious to know how Google is verifying the address thro' phone. Because someone can apply for others address (may be competitor's address) with wrong data and he can specify his phone number to get the PIN. So ultimately he will be able to list others address with wrong data.

I don't know how Google is managing this issue. If anyone knows details you can share it here.


More Articles...
Read more ...

Thursday, June 25, 2009

Google focuses more on Mobile devices (iPhone and Android)


It seems Google is concentrating more on Mobile Applications for iPhones and Android-powered devices.

Recently, it has launched Gmail for mobile which improves Cache implementation in iPhone and Android-powered devices so as to make it tolerant of flaky wireless connections.

And also Google has released Beta version of AdSense for Mobile Applications for enabling the Developers to show the Targeted Ads in Mobile applications also.
For example, AdSense will show advertisements on Music app. based on user’s song list.


Mobile applications are becoming more popular and they help people to get music, make hotel reservations or check bank balances on their phone.

Google says “We want to contribute to the growth of these mobile applications, which is why we're happy to announce our beta launch of AdSense for Mobile Applications”


I am just thinking how Google is going to control/track/manage Genuine use of ads in applications.

If it is successful, I think they can implement it in Desktop based applications also in future. But I am not sure whether it is feasible or not.

Anyway, I hope adSense will encourage developers to create new applications and therefore people will get more free mobile applications.

More Articles...

Read more ...

Take care of letter case when specifying colSpan attribute in javascript




Normally we specify colspan attribute for <td> tag.

For example
<table>
<tr>
<td colspan=”2>QualityPointTechnologies </td>
</tr>
</table>


We can create the above design using javascript in a following way
<script language=”javascript>
table = document.createElement(“table”);

row = document.createElement(“tr”);

cell = document.createElement(“td”);
cell.colSpan=”2”; // colSpan specify ‘S’ as capital letter other wise it won’t work
cell.innerHTML=” QualityPointTechnologies”;

row.appendChild(“cell”);
table.appendChild(“row”);
</script>


We should specify the "S" in Upper case in the colspan, otherwise it won't work.

More Articles...

Read more ...

How to force FireFox to open new window instead of new Tab?


window.open() method in javascript will open the url in new window in non-tabbed browsers such IE6.
i-e Below javascript will open our website in new window in IE6.
Window.open(“http://www.qualitypointtech.com”)

But it will open our website either in new window or in new tab in the tabbed browsers such as FireFox.

If you want to keep it open in new window always, you need to follow below steps in FireFox.

Steps for change settings in fire fox

  • Go to tools menu

  • Select options

  • Select Tab

  • Choose a new window option box



You can refer the below screenshot.



I am not sure whether we can write a code to open the url in new window forcefully even when the user's browser option is set with "new tab" option. If anyone knows any more details about this you can share it here thro' comments.

More Articles...

Read more ...

Tuesday, June 23, 2009

Some useful php functions


Find below some useful functions in php. For complete reference of php functions you can refer php.net which is very useful for working with php projects.

If you are beginner for learning php you can refer w3schools.com

strstr() for finding string within a string in PHP

The strstr() function will search for the first occurrence of a string inside another string.

This function returns the rest of the string from the matching point if matching occurs. Otherwise( i-e if the string to search for is not found)it will return FALSE.

For example,
echo strstr("Welcome Hello world!","Hello");
The above statement will return "Hello world!".
Note that it is case sensitive.

So, strstr("Hello world!","hello"); will return false.

For case insensitive use stristr().


Use of eval() function

The eval() function evaluates a string as PHP code. So it can be used to store the php code in database.

$str=”qualitypoint technologies”
$str1=”welcomes”
echo $str2=”$str $str1 you!”;

Guess what will be the output of $str2 or will it cause error?
It will display sting like that.
$str $str1 you!
Here the use of eval() function is to evaluate the php code/variable as string. So to display php variable as string use eval() function.

eval("\$str2 = \"$str2\";");
then it will display output like this “qualitypoint technologies welcomes you!” . Note the eval() function requires semicolon at the end of string.

Use of reset() function .

The reset() function points the internal cursor position at first element of array.

For example,

$arrNumber = array("first", "second", "third", "fourth");
echo current($arrNumber) . "<br>";
echo next($arrNumber) . "<br>";
echo reset($arrNumber);

Output will be,
first

second

first


Use of list() function

The list() function is used to assign values to a list of variables in one operation.

Note it only works in numeric array.

The below example is used to easily understand this function.

$arr = array("test", "test1", "test2", "test3");

list($a,$b,$c,$d)=$arr;

echo “the array value is $a,$b,$c,$d”

output will be ‘the array value is test,test1,test2,test3’

It is mainly used to fetch data from table,.

Consider below example,

$sql="select * from persons";
$record=mysql_query($sql);
while(list($id,$fname,$lname,$age)=mysql_fetch_row($record))
{
echo "the id is $id and fname is $fname and lname is $lname and age is $age".”<br>”;
}


Use of each() function.

The each() function will return the current key and value pair from an array and will move the array cursor.

For example consider the below code,
$arr = array("test", "test1", "test2", "test3");
reset($arr) ; // point cursor to first element
while(list($key,$val)=each($arr))
{
echo “$key=$val”;
}
Output is, 0=test 1=test1 2=test2 3=test3
Instead of doing above, use foreach()
foreach($arr as $key=>$val)
{
echo “$key=$val”;
}
This code also will display the same output as above.

Use of implode() function

The implode function is used to join the array elements with string.
See the below code,
$arr = array("test", "test1", "test2", "test3");
echo $splitarray=implode(“,”,$arr);
then the output will be,
test,test1,test2,test3
if you use like this $splitarray=implode(“*”,$arr); then it will return values like this
test*test1*test2*test3
if you want to display array values in new line, use like this
$newline=”<br>”;
$splitarray=implode(“$newline”,$arr);
Then it displays array elements like this,
test
test1
test2
test3

Use of explode() function

The explode function is used to split a string a by string.

consider below example

$data = "foo:*:1023:1000::/home/foo:/bin/sh";
$arr=array();
$arr=explode(":",$data);
foreach($arr as $value)
{
echo "value=$value";
}
It will display output like this
value=foovalue=*value=1023value=1000value=value=/home/foovalue=/bin/sh


is_array() function

$arr=array(‘test’,’test1’,’test2’) echo is_array($arr) ? 'Array' : 'not an Array'; $no = 'this is a string'; echo is_array($no) ? 'Array' : 'not an Array';
Here the first is_array() function returns ‘Array’ as output, because the $arr is array, but the second function returns the ‘not an Array’. Because it is not an array , noticed that it is just a string.

Use of realpath() function

The realpath() function returns the absolute path name.It removes all symbols like (‘/’,’./’,’../../’) and returns the absolute path name.It is easy way to get file location from root folder. Consider below example,
$filename=”index.php” echo $string=realpath($filename);
the output will be like that,
o/p: c:\apache\htdocs\anbarasan\uselist.php , but normally we required like that, c:/apache/htdocs/anbarasan/uselist.php , so just replace ‘\’ character with ‘/’ using str_replace() function.
str_replace("\\","/",$string);


Remove backslashes character from string using stripslashes() function

$str=”quality\point technologies” --- here the backslashes character comes between quality and point. But you want the output come without backslash character use stripslashes() function.
echo stripslashes($str);
then it display string like that, qualitypoint technologies. This function also can be used to clean up data retrieved from a database or from an HTML form.


Use of addslashes() function

The addslashes() function returns a string with backslashes in front of predefined characters. The predefined functions are single quotes (‘), double quotes (“) , back slashes (\). Below workaround code is used to easy to understanding of this function.
$name="qualitypoint's logo";
In this case, we will get syntax error from browser because of this single quotes. So to avoid this error we used addslashes() function.
echo addslashes($name);
the output for this code is qualitypoint\'s logo
we faced this single quotes problem earliest, instead of using addslashes() function to avoid this error we used str_replace() function.
$name="qualitypoint's logo";
$name=str_replace("'", "\'",$name);



More Articles...
Read more ...

Saturday, June 20, 2009

Essential Steps for Software Development


We need to follow some essential steps for developing Software/Website effectively in appropriate timeline.
It will help to deliver Quality product cost effectively on time so as to improve Customer Satisfaction which brings success to any business.

In this post I will list some of the steps based on my understanding.
  • Read the Requirements completely and repeatedly till understanding it clearly without any ambiguity.
  • Highlight or make note of key requirements in the requirement document. And, highlight the points that are difficult to understand .
  • Don't hesitate to approach the customer/client if you need any clarification in the requirement and also don't hesitate to inform if any of the requirements is unrealistic.
  • Testing Team also should participate in the requirement analysis before starting any development activity.
  • Start working on coding part only after getting clear understanding of the overall Design of the system
  • Enforce Review and Walk Through Activities.
  • Try to setup Development Environment similar to production environment.
  • Do unit testing immediately after developing each small functionality.
  • Give updates of the progress to the client/customer frequently. If you are facing any difficulty/issue remember to specify in the updates.
  • Make list of things that will vary from Development Environment and Production environment
  • Prepare a user guide document and deliver it along with code.
  • Do regression testing even when changing very small part of the code




More Articles...

Read more ...

Wednesday, June 17, 2009

How to get last row from database table?


It is easy to find last row from table. The below query can be used to get last row from table.

$sql="select * from <table name> order by <field name> desc limit 1"

It displays one last row from table.


More Articles...

Read more ...

Tuesday, June 16, 2009

javascript code for preventing data loss in web form.


HTML forms are used in webpages for collecting data from users. The Form will be submitted on clicking "submit" button in the Form.

The form data will be inserted into database table only when the form got submitted, otherwise the entered data will not reach the database.

Assume that an User fills a user registration form in a website and forgot to click Submit button and then navigates to some other page in the website.

In this case all the details entered by the user will be lost. He needs to enter it again to submit the form for storing the details in the database.

So, to avoid this issue we need to write a code which will give warning to the user when he leaves from the form without submitting it.

We need to follow below steps to do it.
-on loading a page we need to initialize a Boolean flag to indicate that no data available for saving it.
-Change the Boolean flag when typing any data in the form to indicate that we need to save the data before leaving from the page.

-call a function when clicking any link in the page to give warning/alert message based on the Boolean flag value.


Find below the sample javascript code.



var ischanged;//This variable used as flag to check whether user clicked submit button or not
function initialize_ischanged()//this function triggered when body load event
{
ischanged=false;
//alert(ischanged);

}
function check_buttonpressed_ischanged()//this function invoked when submit button get clicked.
{
ischanged=true;
//alert("ischanged is true");
}
//following function called when clicked any links in page, to check whether user clicked submit button or not
function check_ischanged()
{
if(ischanged==false)
{
if(confirm("Do you want to save this game? [ Click Save button ]"))
return false;
else
return true;
}
}


Find below the Reddit users comments for this post.



msloyko
call a function when clicking any link in the page to give warning/alert message based on the Boolean flag value.

Or, we can just set up an unload event handler.

JasonMaloney101

* Wouldn't unload still be called when the page is unloaded while submitting the form?
* On an AJAX-based site, it is possible to click a link on the page that will replace the form (and the rest of the page) with other content, all without unload() ever being hit.

suddo
That's why you add an onSubmit event on the form to disregard the unload event.



More Articles...
Read more ...

How to count number of times the user clicks on a button using javascript?


Sometimes we may need to count the number of times the user clicks on a button or any other control/element in a webpage.

But it seems there no straight forward way such as static variable to do this.

Below sample javascript code can be used to achieve this.


function addCategory()
{
if ( typeof addCategory.no == 'undefined' )
addCategory.no =1;
else
addCategory.no =addCategory.no +1;

}
<input type=button onclick=”addCategory()”>


Explanation:
addCategory.no----->contains total number of times the addCategory() get invoked.
no----> is variable name. Here it acts as member variable for addCategroy() function.
addCategory---->is function name. Javascript treats every function as object. That’s why we are accessing variable as addCategory.no


More Articles...

Read more ...

Removing white spaces entered in TextArea tag of HTML page


White spaces entered in Textarea of HTML page will be considered as Characters even when no other characters are entered.

These white spaces will then be inserted into database table unnecessarily.

So, to avoid this issue the below Javascript code can be used.

It will clear the whitespaces in the Textarea.



var str=document.getElementById(“category_name”).value;
var pattern_white_space=/^\s{1,4}/g;
var pattern_any_characters=/\w+/g;

if(str.match(pattern_white_space)&&!str.match(pattern_any_characters))
{
document.getElementById(“category_name”).value="";
}


More Articles...

Read more ...

Workaround for inconsistent issue with mySql query handling integer id




We faced some inconsistent issue with MySql query.

When we tried to use below mysql query we got error.

$query1="delete from emp_table where emp_id=$emp_id";

So, we tried below query.
$query1="delete from emp_table where emp_id=”.$emp_id;

But this way also didn't work. So, we made change like in following statement, it works good without any issue.

$query1="delete from emp_table where emp_id=' ".(integer)$emp_id." ' ";


More Articles...

Read more ...

Need for having Eval function in javascript


Javascript has function called
eval() which evaluates a string and executes it as if it was script code.

Let us see the need for having this eval function.

Consider the below sample code in javascript.


document.myform.category_name1.value=””;
document.myform.category_name2.value=””;
document.myform.category_name3.value=””;
category_name1,category_name2,category_name3.....which are dynamic in a page.
suppose we want to achieve above three statements in a for loop

for(i=1;i<=3;i++)
{
var category_name=“category_name”+i;
document.myform.category_name.value=””;
}
Trying above way, does not work.

Trying following way, will work well.
for(i=1;i<=3;i++)
{
category_name=”category_name”+i;
temp="myform."+category_name;
clear=temp+'.value="";' ;
eval(clear);
}


We can refer this article to know more about eval.

More Articles...
Read more ...

PHP code for listing files in a Folder


Below PHP code will be used for listing files in a folder.



<?php
$folder=dir(".");

while($folderEntry=$folder->read()){
echo $folderEntry."<br>";
}

$folder->close();

?>


More Articles...

Read more ...

Sunday, June 14, 2009

Reverse Auction and finding best price among multiple Suppliers using C#.net


Auction is the process of buying and selling Goods or Service based on bids.

Generally in auction, the seller puts an item (e.g Digital Camera) up for sale. Multiple buyers bid for the item, and one or more of the highest bidders will be selected to buy the goods at a price determined at the conclusion of the bidding.

There are many online auction sites e.g eBay.com are available in internet.

In these Auctions Buyers compete to get a Good or Service. So it will give benefit to the Seller.

But, in another form of Auction which is called as Reverse Auction , sellers compete to obtain business (Goods or Service). It will give benefit to the Buyer.

i-e In Reverse Auction the role of Buyer and Seller are reversed. It drives to reduce the purchase price.

In physical world, it is bit difficult to conduct Reverse Auction. Assume that you are going to purchase Digital Camera. And assume that in you place there are 10 shops available to sell different Digital Cameras. You can not expect all the 10 shop keepers to meet you and give their price list for enabling you to get the least price. Instead, you need to go to all 10 shops and get quotation from all of them and then you need to select least price within the 10 prices.

So, Reverse Auction in physical world is normally not much used. But in online world it can be easily implemented. So, there are lot of Reverse Auction sites available in Internet.

For example all freelance websites are working based on Reverse Auction only. Here the Buyers will be giving the requirements as Bid Request. Many Sellers (i-e Coders) will be placing bid amount. Finally the Buyer can choose the Seller who placed least bid amount.

Here the freelance website will be called as market maker.

Now we can think about how this Reverse auction can be implemented in Goods purchasing sites (i-e shopping Carts).

The Market Maker website will show the Goods from many vendors/Suppliers in their websites. The customer will be allowed to choose the items from different suppliers so that he can get least price for all the items.

As far this point, this Reverse Auction on online is simple. Now think about delivery charge.

Each supplier will be collecting delivery charge from the customer(buyer) irrespective of how many items the buyer selects from their cart. So, the buyer can not select the least priced item from each supplier blindly to get the best price.

To explain it more clearly, consider below example.

The buyer wants to buy 2 items, and 2 Suppliers are supplying those items with below prices.
Supplier/ItemSupplier1Supplier2
Item110INR12INR
Item211INR10INR


Just by seeing the above price list you will be thinking that getting Item1 from Supplier1 and Item2 from supplier2 will give least price (20INR).

But we should consider Delivery price also.
Assume below delivery price for the Suppliers.
Supplier1-6INR
Supplier2-8INR.

If we include the Delivery charge then the total price will become 34 INR(20+6+8). So it is better the get both items from Supplier1 itself. In this case the item price will be 21 INR, and delivery price will be 6 INR. The total price 27INR (21+6) will be less than 34 INR.

So we need to have specific steps/algorithm to find best price when developing Reverse Auction website. The algorithm will be again complicated as few Items won't be available with some Buyers. We need to consider this constraint also when developing Reverse Auction website.

For one of our clients we have implemented this best price finding system. We followed below steps for implementing it.

- Find permutations of all options and insert them into temp table with optionid.
- Delete invalid options from temp table.
- include delivery charge for each option in temp table.
- calculate total charge for each option and then select minimum from them.
- We can find suppliers and delivery charge for the selected option.

The core concept is simple. Just we need to consider all possible combinations and need to find total for each of them. And finally we need to choose a combination which is having least total value.
But we had to spent more time and effort to implement the first step i-e finding permutations of all options.

Because, we are having math formula only for finding permutations to select 'r' items from 'n' only when the value of 'r' is less than the value of 'n'. I-e there won't be any duplicates.

But in our case, we need to consider duplicates also. (i-e Number of Items may be 4. But we may need to select it from 2 Suppliers)

So there won't be any standard math formula/algorithm to get the result.

After doing a lot of search in the internet, finally I got a sample code written in C language for finding permutation even when duplicates available.

I then converted the C code into C# code and successfully implemented it in our Project.
As we used mdb table for doing this process, the I/O process significantly reduced the performance. So again we implemented it using C# Datatable itself.


void findPermutations(int N, int K)  //for finding all permutations
{
int[] slots = new int[K];
OptionID = 0;
while (incr(slots, K, N))
{
OptionID++;
}
}

bool incr(int[] slots, int K, int N) //it will be used by findPermutations
{

int i, carry;

insertOptions(slots, K);

for (i=0, carry=1; i < K; ++i) 
{
int b = slots[i] + carry;
carry = b/N;
slots[i] = b % N;

}




More Articles...

Read more ...

Saturday, June 13, 2009

Comments/Suggestions from QA Expert to improve Quiz


We got email from an QA Expert for improving our Quiz.

In his mail, he pointed out some small issues in Testing part of our Quiz and given comments and suggestions to improve it.

Please find below mail from the QA expert Martyn Walmsley.


Dear Qualitypoint

I am a Test and QA manager for a UK bank with over 25 years in IT and over 16 years in test and QA, 8 of these in test and QA management.

I obtained the ISEB Test Practitioner qualification in 2004.

I've taken your online test, which I found interesting. With my experience, I took all 21 hard questions. Some of them I would regard as basic for someone who has been in the test industry for more than 6 months but I appreciate that an online quiz can only go so deep into the subject. I thought I'd offer my observations on some of the questions as there are some elements I disagree with and some questions which I think could be better expressed. There appear to be some typographical errors also which I will raise questions against.

I offer these comments as improvement suggestions and in a spirit of encouragement so that you can better deliver against your vision statement.

Regards

Martyn


My comments are in blue in the boxes below
2.
Retesting of a single program or component after a change has been made?

I consider the wording of this question to be ambiguous. The question does not specify whether the elements being tested are those which have been changed OR the functionality which has not been changed. If the test is of the functionality which has not been changed, then the answer would be "unit regression". If the test is of the modified functionality, the correct answer would be worded as "unit functional test" so the available answers do not cover the answer set needed by the question.

Your Answer is:Wrong
Your Answer is:Retesting
Correct Answer is:Unit Regression

7.
This type of testing method attempts to find incorrect or missing functions, errors in data structures or external database access, interface errors, Performance errors and initialization and Termination errors. It is called as
Your Answer is:Correct

Answer is:Block Box Testing

Do you mean "Black Box testing" as "Block Box Testing" is not a term I have come across before? It is not a test type identified in the ISEB syllabus at foundation or practitioner level.

8. What is correct Software Process Cycle?
Your Answer is:Correct

Answer is:Plan(P)------>Do(C)------>Check(A)----->Act(D)
Should this read Plan(P)------>Do(D)------>Check(C)----->Act(A)? (Changes underlined)

13. Acceptance testing is known as
Your Answer is:Wrong
Your Answer is:Beta Testing alone
Correct Answer is:Both Alpha Testing and Beta testing
In conventional testing terms, "Acceptance testing" is referred to as "User Acceptance Testing", being that phase of testing carried out by the users

to ensure that the product delivers the required functionality
to gain confidence in the delivered software

to train the user base in the new features delivered with the software
These are the primary purposes of "Acceptance testing". Defects may still be detected but by this phase they should be few in number and minor in impact, being not threatening to the release of the software.

Those delivering the software into "Acceptance testing" should normally be expected to have tested the software against the requirements statement. They should have validated that they can detect no deficiencies against the stated requirements and their expectation should be that no defects would be uncovered during acceptance testing.

For these reasons I suggest that "Acceptance testing" is a "Beta Testing alone" activity.


20. Boundary value analysis belongs to which testing method?
Your Answer is:Correct

Answer is:Black Box testing
Boundary Value Analysis is recognised primarily a Black Box testing technique. The technique can, however, be applied equally to white box testing when analysing paths through decisions, whether they are of the If ... Then or Select Case type decision or whether they are iteration control statements, i.e. loop counters in For ... Next , While ... Wend constructs or Do ... loop Until Constructs. When questioning a job applicant about the application of test techniques, I would expect them to reply in this sort of manner.



Thanks Martyn for your valuable comments. We have corrected the issues and analyzing your comments to make any further corrections.

We are expecting more comments/suggestions from users/visitors to improve our blog and quiz so that it will be more useful for all.


More Articles...
Read more ...

Thursday, June 11, 2009

Google is experimenting Squared which will return search results in structured format


Google Labs is experimenting new search feature.

It is called as Squared.

It will collect the details for the search keyword from many websites and combine them display search results in structured format such as Excel like structure having many rows and many columns.

You can see/test it at http://www.google.com/squared.

Find below the screenshot which show search result for india primeminister.




We can see Name, photo, description, date of birth and some other details of each us president in tabular format.

It will be more useful for doing comparison in Research.

Below screenshot will show the result for browser



Interestingly, when I did a search for "search engine" the result page didn't show the Google. So I thing it is still in very initial stage of testing.



More Articles...

Read more ...

Twitter - Are you hearing this word first time?


There are lot of social networking sites available in the internet.

Digg, reddit, orkut, linkedin, myspace and facebook are some of the leading sites.

Twitter is now getting more popular among all of the social networking sites.

We can say that Twitter is the latest social-networking craze.

It is working based on a very simple question:

What are you doing?


Basically we need to send small text messages (Maximum 140 characters) as answer for the above question. So, it can be considered as Micro-blogging service.

As it is using small text messages it is used widely in mobile devices also.


We need to create a twitter account to start using the Twitter.

This below steps involve in using Twitter.

- Create your Twitter account.
- Search some people from Twitter and go thro' their profiles (e.g qualitypoint profile
- After seeing the profile(eg. qualitypoint) , if you are interested to know the updates from them (i-e from qualitypoint), you can Follow them.

- Once after following qualitypoint you can see the updates from qualitypoint unless until qualitypoint blocks you. There is no need to wait for getting approval from qualitypoint to get updates from qualitypoint.

-
Similarly you can follow any number of people from whom you want to get updates of what they are doing.

-And also, other people can also follow you. They will be called as your followers. They can read you updates.

The updates/message sent thro' the twitter is called as tweet.

So, basically all Followers of any person can read the tweet of that person. And, also we can use feature such as @reply for sending a message (i-e tweet) to a person even when he is not your Follower.

If you want to send tweet to only a particular person and you don't want the other followers to see it, then you can use Direct Message feature.

We can see the current tweets about any keyword by searching it at search.twitter.com.

If you want to specify any keyword in your tweet you can use hash tagging. i-e just add hash symbol (#) in front of the keyword.

The real power of the twitter lies in Re-Tweeting. Your follower can re-tweet yout tweet by specifying RT to his followers. By doing this, you will be getting opportunity to get more followers from the followers of the person who is re-tweeting your Tweet.


Since millions of users using Twitter, it is used for doing marketing and getting more support also.
Especially it is used as Viral Marketing.

There are lot of Twitter applications/Tools are available for using with Twitter.

We are using Twitlet which is a bookmarklet used for handle tiny url effectivly.

Some feed applications are available to automatically post your blog posting to twitter. This feed service is effectively used by marketing persons.

Similarly your latest Tweets can be displayed in your blogs.


And, you can put Twitter badges on your blog to encourage your blog visitors to follow you on Twitter.

Some applications such as Twitter Alerts will sent you email based on your keyword setup to give details of tweets that are having your keyword in it.

TweetLater will help you to schedule your tweets so that you followers will get updates from you even when you are busy with some other work.

You can watch below youTube video to know the basics of Twitter.





One interesting thing is, as of now Twitter website is not having auto refresh functionality. We need to manually click the refresh button in the Browser to get the latest updates/tweets.

I think Twitter is not providing this option to keep the high performance of the Twitter. Anyway, many Twitter applications are available to solve this issue.

Contact Us if you want to develop your own Custom Twitter applications.

More Articles...
Read more ...

Google is taking steps for preventing Plagiarism in knol.


Google knol was criticized for the possibility of potential Plagiarism.

Now, it seems Google is taking solid steps for preventing Plagiarism. Google is allowing the users to complaint about any Plagiarism. You can see the more details at http://www.google.com/dmca_knol.html

Google is showing a poll in the knols which got any complaints to decide whether the complaint was valid.

You can refer this knol for more details.

More Articles...

Read more ...

Tuesday, June 9, 2009

Resolved IE specific issue related to calling function at onclick event using createElement


I have explained about inconsistent behavior of createElement function in IE and mentioned workaround also in my previous post.

Today, we faced similar issue with createElement. This issue is also again related to IE.

Find below the sample code which will create a new button. A function "showmsg" should be called on clicking the new button.


newbutton=document.createElement("Input");
newbutton.name="btnmsg";
newbutton.type="button";
newbutton.setAttribute("onClick","showmsg(this);");


The above code worked fine in FireFox. But it didn't work in IE.

Once after searching the internet we found below workaround for resolving this issue.

Instead of using setAttribute for onclick event, we used below code.

newbutton.onclick=function(){showmsg(this);}

Once after making the above change the code is working fine in both IE and FireFox.

More Articles...

Read more ...

Monday, June 8, 2009

foreach loop equivalent in javascript.


foreach loop will be easy to use when there is a need to iterate thro' an array or any other collection.

But javascript is not having this option.

Anyway, we can use below type of for loop for achieving the same result of foreach loop.


var arrItems = ["item1","item2","item3"];

for ( var i in arrItems )
{
alert( arrItems[i] );
}

The above code will alert each item in the array one by one.

More Articles...

Read more ...

Is it possible to use same domain name for two servers with some setup?


We are having our main site at qualitypointtech.com and quiz at qualityponinttech.0fees.net/quiz .

I thought it will be good to access quiz at qualitypointtech.com/quiz without putting the quiz at main site.(qualitypointtech.com).

Because we can't put the quiz folder at our main site as it won't support php.

I don't know whether it is possible or not. So, asked this question in reddit.com

I got below suggestion as answer from panamaspace



As I understand it, your main domain is on a server where you have no PHP, and you need to show something done in PHP. Two quick and nasty solutions come to mind.

1.An iframe, cheap and easy, but frowned upon. This is one of those few cases where I'd actually consider it... but I don't know the security implications for what you are trying to do. (Sessions, direct access, etc.). Some .htaccess magic could make sure that the page is only opened when linked to from the main domain.
2. A subdomain that points to the PHP-enabled server. Probably more elegant but a little more work, and I don't know if you actually have DNS control of the main domain.

What I would actually do:

1. Just install php on the main server, it's not that hard. Or move the whole thing to a server with PHP.

Edit: p.s. You know that a form action does not necessarily have to be hosted on the server that has the form, right? You can point the form to be processed elsewhere. If I had more specific information, I might be able to help out.



More Articles...

Read more ...

Friday, June 5, 2009

Use Gravatar to display your icon image when adding comment in any gravatar supported blog.


Gravatar(globally recognized avatar) is a service providing globally-unique avatars.

i-e It will show avatar( small icon like profile image) which will be displayed near the profile/user name in a blog/forum based on the email id used for creating the profile.

Once you create your Gravatar at http://en.gravatar.com/ for your email id, the gravatar will be automatically displayed in any gravatar supported blog/forum near your user name whenever you are adding any comment to the blog.

Wordpress is providing built-in support for gravatars as the gravatar is acquired by
Automattic which developed wordpress.

Content Management System (CMS) such as Drupal is providing support for Gravatar.

You can refer below url for implementing Gravator support in your website.

http://en.gravatar.com/site/implement

More Articles...

Read more ...

Use of tinyurl in Twitter


tinyurl.com is providing service for shortening any long url.


The short url will be useful to remember it and also it will be useful when we are having limited space for specifying the url.
For example, twitter will allow only 140 characters. To save space Twitter is using tinyurl service.

Even we can manfully create the tiny url to use it in twitter to effectively handle the 140 characters limit. ie First shortern the long url using tinyurl.com and then enter this tinyurl with your message in twitter.

We need to use tinyurl only when it is really necessary or useful.

Because, it is having its own drawbacks. The reliability of tinyurl is still in question. Because, if the tinyurl site goes down for few minutes we can not access the url for those few minutes even when the actual website is not down.

tinryurl is functioning based on 301 redirect which will not affect the search engine ranking of the site. Anyway, I am not sure whether the search engines will consider the tinyurls exactly same as true urls.

You can enter your long url here to get short url using tinyurl.com



Enter a long URL to make tiny:





Some bookmarklets such as twitlet/ are available to make this easy. i-e just we can enter the message and url in a pop-up window of bookmarklet and then it will be automatically send to twitter after shortening the url.

This main difference between the use of tinyurl in twitter and twitlet is, twitter will restrict the 140 character limit even before shortening the url. But twitlet will truncate the message based on 140 characters limit only after shortening the url.

bigtweet.com/ is also providing similar bookmarklet. It seems it is having more features. But comparatively it is loading slow. For more details you can read
10 awesome Twitter tricks
.

More Articles...

Read more ...

Introduction to Ajax and sample code for learning Ajax


Ajax stands for asynchronous JavaScript and XML


Ajax is not an Technology in itself. It is a term used for representing the technique used for updating the webpage content asynchronously
without affecting existing content of the webpage.

i-e Some part of the existing webpage on a webbrowser can be refreshed with the content from web server without changing other parts of the webpage i-e without refreshing the whole webpage.

Ajax was made popular by Google by using it in the Google Suggest.

So, basically below steps are involved in using ajax for webdevelopment.

- Creating client side code which will call a javascript function on some events such as onChange.
- Creating a XMLHttpRequest which will be used for sending request to web server from javascript itself and used for receiving response from the webserver.

- A place such as div in the client side code for placing the server response got from the ajax call.

We will see the above steps in detail using below sample code.

Consider below HTML code which will be placed within a Form.


<select name="name" id="name" onChange="showUser(this.value);">


The above code will call a javascript function showUser() when changing the drop-down list value in the Select tag.

The selected value (i-e name in this example) will be passed as argument to the showUser.

The showUser javascript function will look like below mentioned code.



function showUser(str)
{
xmlHttp=GetXmlHttpObject();

if (xmlHttp==null)
{
alert ("Browser does not support HTTP Request");
return;
}
var url="getuser.php";
url=url+"?q="+str;

url=url+"&sid="+Math.random();
xmlHttp.onreadystatechange=stateChanged;
xmlHttp.open("POST",url,true);
xmlHttp.send(null);
}



This function creates xmlHttp object by calling a function GetXmlHttpObject()

You can refer the GetXmlHttpObject() below.


function GetXmlHttpObject()
{
var xmlHttp=null;
try
{
// Firefox, Opera 8.0+, Safari
xmlHttp=new XMLHttpRequest();
}
catch (e)
{
//Internet Explorer
try
{
xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
}
catch (e)
{
xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
}
}
return xmlHttp;
}


The url to be sent as server request is created by specifying the server-side webpage (e.g getuser.php), the function argument "name", and a random number to avoid cache problem.

A function stateChanged is called on onreadystatechange event for getting the response from the webserver for the request of this created url.

You can refer the sample stateChanged function below.


function stateChanged()
{

if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
{
document.getElementById("txtHint").innerHTML=xmlHttp.responseText;
}

else
{

document.getElementById('statusdiv').innerHTML=
"<div align=\"center\" class=\"msg\" ><img src=\"loading.gif\"> Loading ...</div>";
}

}



This function will check the readystate status. If it is complete then webserver response text will be placed inside the client side form, otherwise it will show some loading indication.

Find below the sample server side code (e.g getuser.php) which will be used for sending response according to the value selected in the drop-down list.



<?php
$link=project1_db_connect1();
//for connecting database.
function project1_db_connect1()
{
$link=@mysql_connect("localhost","root","") or exit ();
mysql_select_db ("my_db1") or exit ();

return $link;
}
?>
<table border="1" width="100%">
<tr>
<td>First name</td>
<td>last name</td>
<td>age</td>
</tr>
<?php
$q=$_GET["q"];

$sqluser="select * from persons where id=".$q;
$result=mysql_query($sqluser);
while($userrow=mysql_fetch_assoc($result))
{
$firstname=$userrow['FirstName'];
$lastname=$userrow['LastName'];
$age=$userrow['Age'];

?>
<tr>
<td><?php echo $firstname;?></td>
<td><?php echo $lastname;?></td>
<td><?php echo $age;?></td>
</tr>
<?php
}


?>

</table>


The above code is receiving the selected drop-down value as "q" querystring parameter in the url.

sql query will be used for fetching details such as firstname, lastname age for the corresponding "q" value.

The xmlhttp object is receiving the output of this php page.


More Articles...

Read more ...

Thursday, June 4, 2009

Advantages of php over asp and converting asp site into php site.


php is having many advantages over asp in terms of cost, Speed, Security and flexibility.

Refer below articles comparing asp and php.

http://www.webpronews.com/expertarticles/2005/12/22/asp-vs-php
http://www.netconcepts.com/php-versus-asp/

So, it will be useful if we convert any existing asp websites into php site.

Some converters are available to convert any asp website into php site.

You can download asp2php converter here. I haven't tried it yet.

Some online converters are also available to convert asp webpage into php pages.

Find below an online converter.
http://www.design215.com/toolbox/translator/index.php

If you want to manually convert the asp pages into php pages, you can follow below steps.

Conversion of asp to php.



In asp no need to put semicolon at the end of the each line, but semicolon required in php.
1. xml syntax used in php version 4

XML=load(XMLLocalFileName);
replaced by,
$XML=domxml_open_file($XMLLocalFileName);

documentElement
replaced by,
document_element()

SectionNode=RootNode->childNnodes(0);
replaced by,
$childnodes=$RootNode->child_nodes();
$SectionNode=$childnodes[1];


SectionNode->getAttribute("name");
replaced by,
$SectionNode->get_attribute("name");

DescriptionText =(DescriptionNode.text)
replaced by,
$DescriptionText =($DescriptionNode->get_content())

2. asp syntax and php syntax



1. dim DescriptionText
replaced by,
$ DescriptionText;

2. CStr(Request("section"))
replaced by,
$_GET["section"]

3. if isnull(SectionID) or trim(SectionID) = "" then

//body
end if
replaced by,
if($SectionID=="Null" || trim($SectionID)== "")
{
//body
}

4. XMLFileName = BaseXMLPath & "about/" & SectionID & ".xml"
Replaced by,
$XMLFileName = $BaseXMLPath."about/".$SectionID.".xml";

5. XMLLocalFileName = Server.MapPath(XMLFileName)
In asp Server.MapPath() function returns the physical location of the file name of asp file.
It return something like this c:/apache/htdocs/foldername/filename.asp
We can use below workaround to get file location.

$root=$_SERVER['DOCUMENT_ROOT'];
$folder_file=$_SERVER['PHP_SELF'];
$filename=basename($_SERVER['PHP_SELF']);
$filepos=strpos($folder_file,$filename);
$folder=substr($folder_file,0,$filepos);
$file_location=$root.$folder;
$XMLLocalFileName=$file_location.$XMLFileName;
Now the ‘$XMLLocalFileName’ return c:/apache/htdocs/foldername/filename.php
Anyway, if you know alternate simple solution you can share it here.

6. In asp the logical operators used in conditions like this
&&-‘and’ ||- ‘or’

But in php it is replaced by && and ||

7. In asp the array declaration is like this

Array()
But in php it is replaced by array()

8. The asp Request.ServerVariables("URL") function return folder name and filename.
In php its equivalent function is $_SERVER['PHP_SELF'];

9. In asp the function format is

function functionName(argument)
//body of function
end function
but in php function format is
function fuctionName(argument)
{
//body of function
}
10. In asp the for loop format is

for i=0 to sectionNode.length
//body of for loop
next
but in php its equivalent is,

for($i=0;$i<=count($sectionNode);$i++)
{
//body of for loop
}

11. In asp Response.Write() function is used to display content in webpage and Response.End() is used to end the execution flow.

Its equivalent function used in php is echo and die.

12. In asp Request.ServerVariables("HTTP_HOST") return the server name

Its equivalent function used in php is $_SERVER['HTTP_HOST']

13. the Request.Form() and Request.QueryString in asp is same as $GET[‘’] and $_POST[‘’] in php

14. the instr() function return the integer value of find string in asp, its equivalent function used in php is strpos()

15. the Int() function in asp is replaced by intval() in php.

16.the Rnd() function in asp is replaced by rand() in php

17. the Len() function in asp is replaced by strlen() in php

18.The Mid() function in asp returns a specified number of characters from a string, we used substr() function to return the same string in php.

19. the Replace() function in asp is replaced by str_replace() in php .

20. the Trim() function in asp is replaced by trim() in php.

More Articles...
Read more ...

Wednesday, June 3, 2009

Bing - Mircrosoft's Decision Engine. Will it perform better than Google search?


Microsoft has released a new Search Engine named 'Bing' . Microsoft is calling this new search engine as a Decision engine.

It is telling that Bing will be helpful for making a purchase decision, planning a trip, researching a health condition or finding a local business.

You can see the below video which is giving Demo of Bing.



From Demo, we can see the below features of Bing.

-Left side navigation pane called as explorer pane. This pane will be used for showing related searches and category list when showing search results.

- Bing will be used for booking hotels and air tickets.

- It can be used for comparing prices and features of any product such as Digital Camera.

- On mousing over an orange icon near each search result is showing preview of the page. I am not sure whether it will be useful. Because instead of seeing the preview after hovering this icon, we can easily see the actual page itself.


Initially Microsoft planned to name it as "Kumo".


Yahoo is saying that Bing won't affect any existing Search Engine. Yahoo says that Bing will deliver only “temporary interest.”

You can refer Yahoo CEO Carol Bartz view about Bing.

I have tried to know the Google's comments about Bing. I seared both Google and Bing to find Google's comments. But I couldn't see. If anyone knows about Google's comment/opinion about Bing, you can share it here.

Many people are hesitating to trust the Microsoft. Refer this blog
And you can refer this blog also.
So it is difficult for the Bing to compete with Google. But anyway it will perform better than Microsoft's own live search.

See here to know how to integrate Bing with your browser

As promised by Google it is sharing its knol contents with other search engines also.
Search result of Bing is showing knol contents also. Actually I came to know about Bing when I was looking into traffic source for our knol in Google Analytics.

Let us wait and see whether Bing is really a Decision Engine or just an another marketing tactics of Microsoft.

More Articles...
Read more ...

Free online Quiz for learning php, javascript, mysql, testing, qtp and c#


We have recently released Free Online Quiz.

I hope it will be useful for testing/knowing your knowledge in particular topic (e.g php,QTP) and also it will be helpful for learning.

As of now, we have included below topics.

  • PHP

  • Javascript

  • MySql

  • dotNET/C#

  • QTP

  • Software Testing/QA

  • Aptitude

  • English

You can select Question type such as Easy, Medium, and Hard.

We are in the process of adding more topics and more questions in each type.
Currently if you want to attend more questions select "All".

Send your feedback to qualitypointmail@gmail.com. Feel free to contact us if you face any difficulty/issue using our Quiz.

And, don't hesitate to inform us if you feel answer for any of the questions is wrong.

Click here to attend our Quiz

eBook for learning Software Testing and QTP Automation.

More Articles...
Read more ...

Tuesday, June 2, 2009

PHP function for inserting or updating row into database table


Mostly any web development will require to insert or update form data into a database.

The number of fields and names of form fields will vary in each and every form in a website.

And, sometimes we need to insert the data and sometimes we need to update the data based on whether the key field is already available or not.

So, we had to write many different queries to insert/update data in many forms.

Ultimately, it will take lot of time and effort.

Below function written in php will help to save time, as we need not explicitly write the form names. Only thing is you have to give the form field names exactly same as database table field names.



The below function will insert the named $fields of the given $post array into table $table_name if $id is null.

It will update the existing row if $id is not null.

The $id of the row is always returned.

function insert_or_update_row( $table_name, $id, $fields, $post )
{
if ( $id === null )
{
// insert

$sql = "INSERT INTO $table_name (".join(", ",$fields).")
VALUES ('".join("','", map( $fields, sql_field, $post ) )."')";

}
else
{
$sql = "UPDATE $table_name SET ".
join( ", ", map( $fields, update_field, $post ) )."
WHERE id = $id";

}
if ( mysql_query( $sql ) )
{
if ($id === null) return mysql_insert_id();
return $id;
}
else
query_error( $sql );
}

function map( $orig, $fn )
{
for ( $i = 2; $i < func_num_args(); $i++ )
$arg_list[] = func_get_arg($i);

$new = array();
if ( $orig )
{
foreach( $orig as $x )
$new[] = $fn($x,$arg_list);
}
return $new;
}

Note that below functions used in map() are built-in php function.

func_num_args — Returns the number of arguments passed to the function.
func_get_arg — Return an item from the argument list.

Find below the sample usage of this function.
insert_or_update_row( "employee_table", $_POST[id],
array( 'id', 'emp_name', 'address', 'title', 'phone', 'enabled' ),
$_POST )) )


More Articles...
Read more ...

Search This Blog