COD3369 Posted September 13, 2013 Share Posted September 13, 2013 (edited) #include "WinHttp.au3" Opt("MustDeclareVars", 1) Local $hOpen = _WinHttpOpen() Local $hConnect = _WinHttpConnect($hOpen, "siteball.com") Local $hRequest = _WinHttpOpenRequest($hConnect, Default, "/search.php") _WinHttpSendRequest($hRequest) _WinHttpReceiveResponse($hRequest) Local $sHeader = _WinHttpQueryHeaders($hRequest) _WinHttpCloseHandle($hRequest) _WinHttpCloseHandle($hConnect) _WinHttpCloseHandle($hOpen) MsgBox(0, "Header", $sHeader) I have Inputbox that contain: "http://www.siteball.com/search.php" i dont wont to use StringTrimLeft becoz my url gonna change sometime.. what i want is split the url after first "/" from left and then set the variable $shost = "siteball.com" $sFile = "/search.php" so later i can use for display the exact header detail in msg box. Edited September 13, 2013 by verma123 Link to comment Share on other sites More sharing options...
FireFox Posted September 13, 2013 Share Posted September 13, 2013 Hi, Have you looked at the others String functions? >Help file. Br, FireFox. Link to comment Share on other sites More sharing options...
COD3369 Posted September 13, 2013 Author Share Posted September 13, 2013 yes !! please guide me !! Link to comment Share on other sites More sharing options...
FireFox Posted September 13, 2013 Share Posted September 13, 2013 What don't you understand with these functions, helpfile examples? Br, FireFox. Link to comment Share on other sites More sharing options...
mikell Posted September 13, 2013 Share Posted September 13, 2013 what i want is split the url Guess what ? Link to comment Share on other sites More sharing options...
AutID Posted September 14, 2013 Share Posted September 14, 2013 #include "WinHttp.au3" Opt("MustDeclareVars", 1) Local $hOpen = _WinHttpOpen() Local $hConnect = _WinHttpConnect($hOpen, "siteball.com") Local $hRequest = _WinHttpOpenRequest($hConnect, Default, "/search.php") _WinHttpSendRequest($hRequest) _WinHttpReceiveResponse($hRequest) Local $sHeader = _WinHttpQueryHeaders($hRequest) _WinHttpCloseHandle($hRequest) _WinHttpCloseHandle($hConnect) _WinHttpCloseHandle($hOpen) MsgBox(0, "Header", $sHeader) I have Inputbox that contain: "http://www.siteball.com/search.php" i dont wont to use StringTrimLeft becoz my url gonna change sometime.. what i want is split the url after first "/" from left and then set the variable $shost = "siteball.com" $sFile = "/search.php" so later i can use for display the exact header detail in msg box. You can create a var with the entire link and the split the url in mini vars so you can use them as you want. https://iblockify.wordpress.com/ 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