This is the code :
#!/bin/bash
head=`curl -D -s "http://example.com/" | grep "j_id__v_0:javax.faces.ViewState:2"`
echo $head
and the output in terminal :
</script>
<input type="hidden" name="GlobalFooter_SUBMIT" value="1" />
<input type="hidden" name="javax.faces.ViewState" id="j_id__v_0:javax.faces.ViewState:2" value="V7wZDq4cDizFPZ0i52hQGUD25XgWp5NJC+hCql33eTTwC2hm" autocomplete="off" />
</form>
</div>
</div>
How do I print the contents of the value?