sshrum Posted October 10, 2005 Share Posted October 10, 2005 (edited) $sAppDonations = "http://www.shrum.net/cats.php?body=/code/donations.shtml&dir=/code" RunWait(@ComSpec & " /c " & "start " & $sAppDonations) Everything works up to the point where the "&" is which is getting cut off. What do I need to do in order for this to get passed in its entirety to the browser? TIA Edited October 10, 2005 by sshrum Sean Shrum :: http://www.shrum.net All my published AU3-based apps and utilities 'Make it idiot-proof, and someone will make a better idiot' Link to comment Share on other sites More sharing options...
jefhal Posted October 10, 2005 Share Posted October 10, 2005 (edited) Never mind... Edited October 10, 2005 by jefhal ...by the way, it's pronounced: "JIF"... Bob Berry --- inventor of the GIF format Link to comment Share on other sites More sharing options...
Valuater Posted October 10, 2005 Share Posted October 10, 2005 (edited) this worked ;$sAppDonations = "http://www.shrum.net/cats.php?body=/code/donations.shtml&dir=/code" $sAppDonations = "www.XPCleanMenu.HostRocket.com" RunWait(@ComSpec & " /c " & "start " & $sAppDonations, "", @SW_MINIMIZE) its in your web indentification 8) Edited October 10, 2005 by Valuater Link to comment Share on other sites More sharing options...
sshrum Posted October 10, 2005 Author Share Posted October 10, 2005 (edited) (Note the original post)Try passing a web URL with multiple arguments...it will pass the first but strip everything at and past the first '&' you supply.URLs with 0 arguments: worksURLs with 1 argument: worksURLs with 2 or more arguments: fail due to missing 2nd, 3rd, nth argumentThe website URL I am using works fine if I type it into a browser. I'm trying to get it passed as a command line to the associated browser via the shell.When this code is executed, the browser brings up:+ http://www.shrum.net/cats.php?body=/code/donations.shtmlInstead of:+ http://www.shrum.net/cats.php?body=/code/d...shtml&dir=/code Edited October 10, 2005 by sshrum Sean Shrum :: http://www.shrum.net All my published AU3-based apps and utilities 'Make it idiot-proof, and someone will make a better idiot' Link to comment Share on other sites More sharing options...
Valuater Posted October 10, 2005 Share Posted October 10, 2005 this worked $sAppDonations = "http://www.shrum.net/cats.php?body=/code/donations.shtml" & "dir=/code" ;$sAppDonations = "www.XPCleanMenu.HostRocket.com" RunWait(@ComSpec & " /c " & "start " & $sAppDonations, "", @SW_MINIMIZE) 8) Link to comment Share on other sites More sharing options...
Developers Jos Posted October 10, 2005 Developers Share Posted October 10, 2005 (edited) $sAppDonations = "http://www.shrum.net/cats.php?body=/code/donations.shtml" & "dir=/code"There's a big difference between your line and the posted issue ... This demo's the issue that everyting gets cut off after the &:$sAppDonations = "http://www.shrum.net/cats.php?body=/code/donations.shtml&dir=/code"RunWait(@ComSpec & " /c " & "start echo " & $sAppDonations)Don't have a real good solution but this works so maybe triggers ideas to get to the solution:$sAppDonations = '"http://www.shrum.net/cats.php?body=/code/donations.shtml&dir=/code"'RunWait(@ComSpec & " /c " & "start explorer " & $sAppDonations) Edited October 10, 2005 by JdeB SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
flyingboz Posted October 10, 2005 Share Posted October 10, 2005 (edited) There's a big difference between your line and the posted issue ... There is no need to "fix" - the proper arguments must be supplied to the command shell.& is the 'command chain' operator in dos and dos-like shells (also *nix, from which dos derived some of its most useful features i.e., from a command prompt type date /t & time /t both programs will run.If I remember my dos, the solution is to "escape" the &, using the ^ operator. i.e.echo this will not display the ampersand & echo this will display the ampersand ^& Edited October 10, 2005 by flyingboz Reading the help file before you post... Not only will it make you look smarter, it will make you smarter. Link to comment Share on other sites More sharing options...
sshrum Posted October 10, 2005 Author Share Posted October 10, 2005 (edited) The "^" fixed it. $sAppDonations = "http://www.shrum.net/cats.php?body=/code/donations.shtml^&dir=/code" Edited October 10, 2005 by sshrum Sean Shrum :: http://www.shrum.net All my published AU3-based apps and utilities 'Make it idiot-proof, and someone will make a better idiot' Link to comment Share on other sites More sharing options...
Valuater Posted October 10, 2005 Share Posted October 10, 2005 There is no need to "fix" - the proper arguments must be supplied to the command shell.& is the 'command chain' operator in dos and dos-like shells (also *nix, from which dos derived some of its most useful features i.e., from a command prompt type date /t & time /t both programs will run.If I remember my dos, the solution is to "escape" the &, using the ^ operator. i.e.echo this will not display the ampersand & echo this will display the ampersand ^&so.... in laymans terms ( other wise known as "hobbyist terms")this is a valid approach or not a valid approach to the posters question ( it does work)$sAppDonations = "http://www.shrum.net/cats.php?body=/code/donations.shtml" & "dir=/code" RunWait(@ComSpec & " /c " & "start " & $sAppDonations, "", @SW_MINIMIZE)?????thx8) Link to comment Share on other sites More sharing options...
jefhal Posted October 10, 2005 Share Posted October 10, 2005 If I test your url on the command line with iexplore:c:\iexplore.exe" http://www.shrum.net/cats.php?body=/code/d...shtml&dir=/codeIt gives an error:Parameter format not correct - "code".Looks like your url is not acceptable, at least to IE... ...by the way, it's pronounced: "JIF"... Bob Berry --- inventor of the GIF format Link to comment Share on other sites More sharing options...
flyingboz Posted October 11, 2005 Share Posted October 11, 2005 @sshrum - glad to help @valuater - The key, in my mind, whether you are a "hobbyist", or make a living programming , is whether you understand the issue, and the advantages / limitations of the proposed solution. Reading the help file before you post... Not only will it make you look smarter, it will make you smarter. Link to comment Share on other sites More sharing options...
w0uter Posted October 11, 2005 Share Posted October 11, 2005 just use alternative ways then @ComSpec _INetBrowse has like 3 other My UDF's:;mem stuff_Mem;ftp stuff_FTP ( OLD );inet stuff_INetGetSource ( OLD )_INetGetImage _INetBrowse ( Collection )_EncodeUrl_NetStat_Google;random stuff_iPixelSearch_DiceRoll Link to comment Share on other sites More sharing options...
Developers Jos Posted October 11, 2005 Developers Share Posted October 11, 2005 If I remember my dos, the solution is to "escape" the &, using the ^ operator. i.e.Thanks for reminding the solution... I knew there was one but just couldn't remember it.. (guess the DOS stuff is slowly fading..) so.... in laymans terms ( other wise known as "hobbyist terms")this is a valid approach or not a valid approach to the posters question ( it does work)$sAppDonations = "http://www.shrum.net/cats.php?body=/code/donations.shtml" & "dir=/code"As mentioned: its not the same. $sAppDonations = "http://www.shrum.net/cats.php?body=/code/donations.shtml" & "dir=/code"results in $sAppDonations containing "http://www.shrum.net/cats.php?body=/code/donations.shtmldir=/code"But the URL needed is :"http://www.shrum.net/cats.php?body=/code/donations.shtml&dir=/code"See the difference ? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. 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