1

i am new to solr.

i want the result of solr output into jsp format or page

by default it shows result in xml format.

please help me.

  • Ankit, your question is fairly vague. Can you provide more details about what you're trying to accomplish? Without that context, @ryacii probably has the best answer at this time. – Nick Zadrozny Jun 14 '12 at 14:58
  • when i start solr(java -jar start.jar) http://localhost:8983/solr/admin/ , and when i fire some query in a search box it shows the result in xml form, it generates that xml on run time .. but i dont want data in xml form, i want data in normal format... it reads the schema.xml and solr.xml and create the result at run time – Ankit Sharma Jun 15 '12 at 09:43

1 Answers1

2

Basically you need to parse xml on your java code.
Before doing this, you need to find ways to call solr url in your code. There are several ways of doing this, the basic one is by using org.apache.http.client.HttpClient to execute post method.
You can then parse the returned data, xml format data and load it on your jsp pages.

Please refer to the following tutorials:
1. Overview on how to use HttpClient
2. Parsing XML using Java

ryacii
  • 527
  • 4
  • 11