14. A method in a computing device for determining relevance of web pages to queries, the web pages containing text and images, each web page having a layout when the web page is rendered, the method comprising: for images of web pages, identifying image text associated with the image by extracting from the web page that contains the image the image text that is determined to be associated with the image based on analysis of the layout of the web page that contains the image; receiving a query; generating a search result of web pages for the received query; for each web page in the generated search result, calculating an image relevance score indicating relevance of image text associated with an image of the web page to the query; and calculating an image importance score for the image of the web page indicating importance of the image to the web page; and ranking the web pages of the generated search result based on the calculated image relevance scores and the calculated image importance scores.
14. A method in a computing device for determining relevance of web pages to queries, the web pages containing text and images, each web page having a layout when the web page is rendered, the method comprising: for images of web pages, identifying image text associated with the image by extracting from the web page that contains the image the image text that is determined to be associated with the image based on analysis of the layout of the web page that contains the image; receiving a query; generating a search result of web pages for the received query; for each web page in the generated search result, calculating an image relevance score indicating relevance of image text associated with an image of the web page to the query; and calculating an image importance score for the image of the web page indicating importance of the image to the web page; and ranking the web pages of the generated search result based on the calculated image relevance scores and the calculated image importance scores. 15. The method of claim 14 wherein when a web page has multiple images, the web pages are ranked based on the image relevance score of the image of the web page with the highest image importance score.