How Can I append text to all HTML documents in a folder
Windows Server Forum Index Windows Server
Server discussion on Windows platform.
 
 FAQFAQ   MemberlistMemberlist     RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
Google
 
Web winserverhelp.com
How Can I append text to all HTML documents in a folder

 
Post new topic   Reply to topic    Windows Server Forum Index -> Programming
Author Message
David Ramos
Guest





Posted: Wed Nov 09, 2005 9:51 pm    Post subject: How Can I append text to all HTML documents in a folder Reply with quote

Hi all,

Newby here to Windows scripting, but ok with VB.

I have run into some cross-domain issues with our LMS and our Web-Based
training servers. The documented solution is to put in the following text
into each HTML page on the Web-Based training side:
document.domain = "mydomain.com"

I tried creating a batch file that would append the text from file1 into
each html file. But it puts the text at the top of the page. I need to find
the following text in each HTML first:
<script language = "JavaScript">

Then enter a carriage return and place the text:
document.domain = "mydomain.com"

So the end result would be
....
<script language = "JavaScript">

document.domain = "mydomain.com"

....

Is there anyone out there that can help me?

Thanks,
David Ramos
Back to top
 
Post new topic   Reply to topic    Windows Server Forum Index -> Programming All times are GMT
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum




New Topics Powered by phpBB