Jump to content
Sign in to follow this  
zpanderson

_IEDocReadHTML is not matching IE view source

Recommended Posts

zpanderson

When I view the source of my webpage in Internet Explorer I see calls to javascripts that include the params sent.

<script>callApplet("gridapplet", "Applet.class", "/classes/", "Net.jar", "1400", "-160");</script>
You need a JAVA enabled browser to use this JAVA applet.
<PARAM NAME=ddfirstall value="y">
<PARAM NAME=fontSize value="10">
When I use _IEDocReadHTML I see the <script>...</script> tags but do not see the <PARAM NAME=...> following it.  Is there any way to get that info as well?  I'm trying to validate the parameters sent.
 
Thanks!

Share this post


Link to post
Share on other sites
EKY32

I tried it and it's working:

#include <IE.au3>
#include <MsgBoxConstants.au3>

Local $oIE = _IECreate(@ScriptDir & "\h.html")
Local $sHTML = _IEDocReadHTML($oIE)
MsgBox($MB_SYSTEMMODAL, "Document Source", $sHTML)

_IEQuit($oIE)

post-74823-0-02686800-1379318739_thumb.j

 

post your code if you thing there is something wrong?

Edited by EKY32

[font="'trebuchet ms', helvetica, sans-serif;"]Please mark the answer of your question if you found it.[/font]

Share this post


Link to post
Share on other sites
zpanderson

Thanks for the reply!

I'm confused.  So you just made an .html file that contained exactly what I'm expecting?  

Edited by zpanderson

Share this post


Link to post
Share on other sites
EKY32

Thanks for the reply!

I'm confused.  So you just made an .html file that contained exactly what I'm expecting?  

 

I copied the text of your HTML file you posted up there to my file, and tried to read it with the code i posted up there, and it worked fine.

if you still have a problem post your code here, or the full HTML content if you have other than what you posted.


[font="'trebuchet ms', helvetica, sans-serif;"]Please mark the answer of your question if you found it.[/font]

Share this post


Link to post
Share on other sites
DaleHohm

The _IE functions operate on the DOM after client-side javascript is interpreted.  To see the stream priot to client processing, use something like INETGET or INETGETSOURCE.

Dale


Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl

MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model

Automate input type=file (Related)

Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded  Better Better?

IE.au3 issues with Vista - Workarounds

SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead?

Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble

Share this post


Link to post
Share on other sites
zpanderson

Alright, I tried what you did and just saved my complete source to an html file.  I then used _IECreate to open the file and read the source.

This worked exactly as you say and exactly as I would expect.  Not sure what is happening differently when the page is actually loaded.  

 

Is it possible to use INETGET or _INETGETSOURCE on a page that is already loaded?  The website I'm testing creates a session id and I cannot go directly to the page.

Thanks!

Edited by zpanderson

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×