When I make the call, the response coming back has no form or input fields. Is there another way to post data without a form? Or do I have an incorrect $url
? What am I missing?
$c = Invoke-WebRequest -Uri $url -WebSession $sess_var
$c.forms.count
Output is zero for the form count. I have also tried to set fields like below and post with -Body $form3
(gave an error):
$form3 = $c.Forms[0]
$form3.somefieldIknow = "good value"
EDIT: The website is internal to my network and is not visible to the outside. Here is a snippet from the output from $c, hopefully this may help. I downloaded Fiddler but its not showing fields for some reason. I am not able to decipher below. Maybe someone can lend a hand. thanks.
ParsedHtml : mshtml.HTMLDocumentClass
Forms : {}
InputFields : {@{innerHTML=; innerText=; outerHTML=<INPUT id=arid302889100 class="text f9 dat" style="HEIGHT: 21px;
WIDTH: 31px; LEFT: 0px; TOP: 0px" readOnly>; outerText=; tagName=INPUT; id=arid302889100; class=text
f9 dat; style=HEIGHT: 21px; WIDTH: 31px; LEFT: 0px; TOP: 0px; readOnly=},
Links : {@{innerHTML=<IMG class=tbright alt="Show toolbar" src="../../../../resources/images/mt_sprites.gif"><IMG class=tbdown alt="Hide toolbar" src="../../../../resources/images/mt_sprites.gif">; innerText=; outerHTML=<A class="btn TBTopBarBox"
href="javascript:"><IMG class=tbright alt="Show toolbar"