Aleks Posted May 5, 2009 Share Posted May 5, 2009 From what I've read in the function documentation, it seems like you should be able to access password protected sites with InetGet using the syntax: InetGet("user:pass@site.com", "file") However, this does not seem to work for me in Vista. I noted that IE 7 dropped support for this syntax in its own URLs. Could this be why this isn't working for me? Does anyone have any fixes or workarounds? Link to comment Share on other sites More sharing options...
BrettF Posted May 6, 2009 Share Posted May 6, 2009 There are other ways, are you sure the syntax is correct? If you were to go to your browser paste the path in does it work?Is it possible to show us your code?Maybe also check out http://www.autoitscript.com/forum/index.php?showtopic=77503.Cheers,Brett Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version! Link to comment Share on other sites More sharing options...
Aleks Posted May 7, 2009 Author Share Posted May 7, 2009 There are other ways, are you sure the syntax is correct? If you were to go to your browser paste the path in does it work? Is it possible to show us your code? Maybe also check out http://www.autoitscript.com/forum/index.php?showtopic=77503. Cheers, Brett It does work if I paste it into a browser like firefox, but not IE. My syntax is: $ds_user_pass = "user:password" $host = "server.ischool.washington.edu" $hostpath = ":60443/computers/get/entry?id=" $macaddr = "some-mac-address" $servername = "https://" & $ds_user_pass & $host $url = $servername & $host_path & $macaddr $saveLocation = "some path" InetGet($url, $saveLocation) Of course that is not the exact code, there are some procedures that run in between which populate the variables. I have it print the $url to a msg box before I try to InetGet, and the url ends up correct. However, the function always returns 0. Link to comment Share on other sites More sharing options...
BrettF Posted May 7, 2009 Share Posted May 7, 2009 What does this return? $ds_user_pass = "user:password" $host = "server.ischool.washington.edu" $host_path = ":60443/computers/get/entry?id=" $macaddr = "some-mac-address" $servername = "https://" & $ds_user_pass & $host $url = $servername & $host_path & $macaddr $saveLocation = "some path" MsgBox (0, "", $url) I think you will see your problem. Also $host_path didn't exist initially (your script defined $hostpathso) I changed it to be correct... Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version! Link to comment Share on other sites More sharing options...
Aleks Posted May 7, 2009 Author Share Posted May 7, 2009 I see what you mean, but it is because I copied the code from my script incorrectly. Here is what I really had: $ds_user_pass = "user:password@" $host = "server.ischool.washington.edu" $host_path = ":60443/computers/get/entry?id=" $macaddr = "some-mac-address" $servername = "https://" & $ds_user_pass & $host $url = $servername & $host_path & $macaddr $saveLocation = "some path" InetGet($url, $saveLocation) I'm 99% sure there isn't anything wrong with the URL, because I've used a msgbox to look at it before it gets passed to InetGet. Link to comment Share on other sites More sharing options...
BrettF Posted May 7, 2009 Share Posted May 7, 2009 Well I'm not sure then. 100% sure the username and passwords are correct? Try looking in example scripts for other methods. Cheers, Brett Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now