tobi2006 Posted January 7, 2011 Share Posted January 7, 2011 hey guys, i want to get from a webpage's body text a special part! I already played around with _StringBetween, but no success: _StringBetween(_IEBodyReadText($ie),"Aktueller Titel:","") Getting "0" or nothing everytime. Can anyone help me? Link to comment Share on other sites More sharing options...
MrPPP Posted January 7, 2011 Share Posted January 7, 2011 If you can give us the link of the page your trying to access it will be a lot easier to help;) Link to comment Share on other sites More sharing options...
tobi2006 Posted January 7, 2011 Author Share Posted January 7, 2011 If you can give us the link of the page your trying to access it will be a lot easier to help;)Link: http://ww3.servemp3.com/s1-Single-Charts.htmlIt's the line with "Aktueller Titel:". I want to get what's after "Aktueller Titel:" Link to comment Share on other sites More sharing options...
MrPPP Posted January 7, 2011 Share Posted January 7, 2011 Link: http://ww3.servemp3.com/s1-Single-Charts.html It's the line with "Aktueller Titel:". I want to get what's after "Aktueller Titel:" I guess two things could be wrong. Or your $ie does not work or you don't know that _StringBetween returns an array. Because if I use this: #include <IE.au3> #include <string.au3> $oIE = _IECreate ( "http://ww3.servemp3.com/s1-Single-Charts.html" ) sleep (2000) $text = _IEBodyReadText ( $oIE ) $result = _StringBetween ( $text , "Aktueller Titel:", "Server") MsgBox ( 0, "asf", $text) MsgBox ( 0, "asf", $result[0]) It works fine;) Link to comment Share on other sites More sharing options...
tobi2006 Posted January 7, 2011 Author Share Posted January 7, 2011 I guess two things could be wrong. Or your $ie does not work or you don't know that _StringBetween returns an array. Because if I use this: #include <IE.au3> #include <string.au3> $oIE = _IECreate ( "http://ww3.servemp3.com/s1-Single-Charts.html" ) sleep (2000) $text = _IEBodyReadText ( $oIE ) $result = _StringBetween ( $text , "Aktueller Titel:", "Server") MsgBox ( 0, "asf", $text) MsgBox ( 0, "asf", $result[0]) It works fine;) It works! Thanks! Think problem was $result[0]... Link to comment Share on other sites More sharing options...
MrPPP Posted January 7, 2011 Share Posted January 7, 2011 It works! Thanks! Think problem was $result[0]... Probably it was;) Good luck with it! 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