thanks mlseim. You are right. By checking the number of rows found in the query result , i got the output what i expect.
Please tell me something about the submit and review buttons.
I've to do another thing. i.e.) I've a submit button and review button. By clicking submit button the answer get saved and the not answered image will change to answered image.
But by clicking the review button the written answers should get save in a txt file and then the not answered image is get updated to review _answer image.
How shall i do this. Any ideas please tell me.