anothertester Posted December 26, 2006 Share Posted December 26, 2006 Hello all, I haven't been using Autoit for a while but I had some fun with it before. Now I got lazy again and I wanted to make script that copies/pastes a HTML content to some file for me... or at least copy to the clipboard. But there's a problem - my script fails to return contents of the page. The site I'm trying to get contents from is o-game.co.kr. This is Korean version of O-game. The page source, when viewed, is like this <frameset rows="*,0" frameborder="no" border="0" framespacing="0"> <frame name="mainframe" src="/index.php?frameset=1" frameborder="0" scrolling="yes" noresize> <frame name="trk" src="http://analytics.gameforge.de/cp.php?game=ogame&action=visit&gr=&lang=kr&kid=" frameborder="0" noresize> </frameset> But the actual contents being shown aren't like that. Some sample of the contents I need to retreive are: 홈 빌딩 자원 연구 쉽야드 함대 기술 갤럭시 방어시설and 갤럭시 0:02:03 함대 함대가 행성 Kampchaka [4:452:1]에서 행성 LeGranBleu [4:452:3] 로 도착합니다. 미션: 공격. 0:02:15 함대 함대가 행성 Kampchaka [4:452:1]에서 행성 AquaMarine[4:456:2] 로 도착합니다. 미션: 공격. I tried _IEFrameGetCollection and _IEDocReadHTML to get contents of frames but it doesn't return much... Can anyone give me some kind of direction or tips? Link to comment Share on other sites More sharing options...
Moderators big_daddy Posted December 26, 2006 Moderators Share Posted December 26, 2006 See if this gives you the text you are wanting. #include <IE.au3> $sURL = "http://o-game.co.kr/portal/?lang=kr&frameset=1" $oIE = _IECreate($sURL) ConsoleWrite(_IEBodyReadText($oIE) & @CR) Link to comment Share on other sites More sharing options...
anothertester Posted January 31, 2007 Author Share Posted January 31, 2007 See if this gives you the text you are wanting. #include <IE.au3> $sURL = "http://o-game.co.kr/portal/?lang=kr&frameset=1" $oIE = _IECreate($sURL) ConsoleWrite(_IEBodyReadText($oIE) & @CR) Yes it does work like a charm! Thank you very much. Now I can get the text I needed. How did you find that url? I couldn't find it before... Link to comment Share on other sites More sharing options...
Moderators big_daddy Posted January 31, 2007 Moderators Share Posted January 31, 2007 Your welcome! It is the "src" value of the frame. 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