Results 1 to 3 of 3

Thread: Post with WinhttpRequest syntax problem

Threaded View

  1. #1

    Thread Starter
    New Member
    Join Date
    Feb 2013
    Posts
    2

    Post with WinhttpRequest syntax problem

    Trying to use WinhttpRequest to automatically login to a Multi-functional copier. BELOW is the code from the Copier where it references the Login form and associated functions/PHPs. I'm using a function copied from the web, GetDataFromURL with 3 args; URL, Method (GET or POST), Data. Not knowing exactly what I'm doing, I can't figure out how to interact properly with the Java on the Copier's webpage. My code is something like:
    Getdatafromurl "http://13.246.29.15/userpost/xerox.set", "POST","_fun_function=HTTP_Authenticate_fn&NextPage=/properties/authentication/luidLogin.php&webUsername=admin&webPassword=password&frmaltDomain=default");

    Hopefully someone that DOES know what they're doing can figure out how to construct this so that I can get the Login to work. I do a GET shortly after this to a admin protected page which would load if I were properly logged in but the page returned is the default index page with a warning that I need admin priviledges to view the requested page.

    Thanks to any brainiacs out there that can help with this. Cheers, j

    Code:
    <body onLoad="Docload()">
    <form method="post" action="/userpost/xerox.set">
    <div class="boundingBox normalSpacing addTopMargin">
    	<input type="hidden" name="_fun_function" value="HTTP_Authenticate_fn">
    	<input type="hidden" name="NextPage" value="/properties/authentication/luidLogin.php">
    
    	<div class="titleBar">
    		<h3>Login</h3>
    	</div>
    	<div class="boxBody">
    		<h6>User ID</h6>
    		<div class="component">
    			<input type="text" name="webUsername" size="32" maxlength="32">
    		</div>
    
    		<h6>Password</h6>
    		<div class="component">
    			<input type="password" name="webPassword" size="32" maxlength="63">
    		</div><input type="hidden" name="frmaltDomain" value="default">	</div>
    </div>
    <div class="horizButtonBarBelowTableLeft">
    	<button type="submit">Login</button>
    </div>
    <script type="text/javascript">
    	document.forms[0].webUsername.focus();</script></form>
    
    </body>
    </html>
    Last edited by gep13; Feb 5th, 2013 at 03:02 AM. Reason: Added code tags

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width