VBS who gets text from URL and put it in .txt

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
websec
Posts: 2
Joined: 28 Jan 2013 05:40

VBS who gets text from URL and put it in .txt

#1 Post by websec » 28 Jan 2013 05:45

So I have this code

Code: Select all

Dim document : Set document = WScript.GetObject("https://secure.wikimedia.org/") 
 
 While document.readystate <> "complete"
     WScript.Sleep 200
 Wend
 
 WScript.Echo document.documentElement.outerHTML


which is getting to text/source from a link. Can somebody help me to make a .bat file who is using this code, but not open a popup window with the text/source, but send it in some .txt.
Thanks

websec
Posts: 2
Joined: 28 Jan 2013 05:40

Re: VBS who gets text from URL and put it in .txt

#2 Post by websec » 05 Mar 2013 14:06

Somebody :roll:

pditty8811
Posts: 184
Joined: 21 Feb 2013 15:54

Re: VBS who gets text from URL and put it in .txt

#3 Post by pditty8811 » 05 Mar 2013 14:15

try stackoverflow.com

Squashman
Expert
Posts: 4488
Joined: 23 Dec 2011 13:59

Re: VBS who gets text from URL and put it in .txt

#4 Post by Squashman » 05 Mar 2013 16:38

I know next to nothing about Vbscript.

Code: Select all

@echo off
cscript //nologo geturl.vbs >Output.txt

Sponge Belly
Posts: 234
Joined: 01 Oct 2012 13:32
Location: Ireland
Contact:

Re: VBS who gets text from URL and put it in .txt

#5 Post by Sponge Belly » 01 Apr 2013 06:52

Hi Websec!

Have a look at abc0502’s program in the last user posted on forum topic. You should be able to modify his code to suit your needs. If you run into any more problems, feel free to post a question here, but I don’t know much about VBScript. Good luck!

- SB

Post Reply