Hello again, I made the snippet i had asked for using the
HtmlUnit I think that there is a far better way to be done and i am looking for it but and this works for me.
The code
public void search() throws FailingHttpStatusCodeException, MalformedURLException, IOException { //load the page WebClient client = new WebClient(); HtmlPage webPage = (HtmlPage) client.getPage("http://www.google.com/"); //find the elements q is the name of the text field and btnG the button for submitting HtmlForm form = webPage.getFormByName("f"); HtmlTextInput text = (HtmlTextInput) form.getInputByName("q"); HtmlSubmitInput submit = (HtmlSubmitInput) form.getInputByName("btnG"); //set java in the tex field and click the button text.setValueAttribute("java"); HtmlPage resultPage = (HtmlPage) submit.click(); //print the result System.out.println(resultPage.asText()); } you will need all the lib folder from the htmlunit i think you don't need any specail knowledge of html for making something like this. But i think if you want togo ahead with a web bot you need to know some.
Last i want to apologise for replying late but i have to go school during the week.
Yours Souperk
Ps: i will edit the post's title and i will mark it as solved