Here you can find the source of retrieveHiddenInputs(Document doc)
public static Map<String, String> retrieveHiddenInputs(Document doc)
//package com.java2s; /******************************************************************************* * Copyright (c) 2014,2015 Hideki Yatomi * All rights reserved. This program and the accompanying materials are made * available under the terms of the Eclipse Public License v1.0 which * accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html ******************************************************************************/ import java.util.*; import org.jsoup.nodes.*; public class Main { public static Map<String, String> retrieveHiddenInputs(Document doc) { Map<String, String> map = new HashMap<>(); for (Element e : doc.select("form input[type=hidden]")) { String name = e.attr("name"); String value = e.attr("value"); map.put(name, value);//from www.j ava 2s. c om } return map; } }