467,132 Members | 1,149 Online
Bytes | Developer Community
Ask Question

Home New Posts Topics Members FAQ

Post your question to a community of 467,132 developers. It's quick & easy.

Script to Update Multiple Files in a Directory

I need a script to process all of the files in a directory (and
sub-directories). Nearly all of the .ASX files have an out-of-date
Copyright date.

Example:

<ASX version = "3.0">
<TITLE>Hello World</TITLE>
<ENTRY>
<AUTHOR>Me</AUTHOR>
<COPYRIGHT>Copyright 1995-2000 Me, Inc.</COPYRIGHT>
</ENTRY>
</ASX>

The <COPYRIGHTtag needs to be updated to be -2006. Each file is
different. Some may have 2000, others may have 2001, etc. The opening
date could be 1995, or something else. Those need to stay whatever they
were in the file. ONLY change the "to" date.

For this, the script has to take the whole set of ASX files, update
them.

Nov 2 '06 #1
  • viewed: 1451
Share:
1 Reply
rh****@gmail.com said the following on 11/2/2006 4:16 PM:
I need a script to process all of the files in a directory (and
sub-directories). Nearly all of the .ASX files have an out-of-date
Copyright date.

Example:

<ASX version = "3.0">
<TITLE>Hello World</TITLE>
<ENTRY>
<AUTHOR>Me</AUTHOR>
<COPYRIGHT>Copyright 1995-2000 Me, Inc.</COPYRIGHT>
</ENTRY>
</ASX>

The <COPYRIGHTtag needs to be updated to be -2006. Each file is
different. Some may have 2000, others may have 2001, etc. The opening
date could be 1995, or something else. Those need to stay whatever they
were in the file. ONLY change the "to" date.

For this, the script has to take the whole set of ASX files, update
them.
Download Notetab: <URL: http://www.notetab.com/Then open all your ASX
files (Notetab, when you do File>Open you can open *.ASX and it will
open them all at once). Then do a global search/replace and replace them
all. Then save them all. No Javascript needed. And, client side script
can't modify server side files.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Nov 2 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

8 posts views Thread by Sticks | last post: by
10 posts views Thread by shumaker@cs.fsu.edu | last post: by
7 posts views Thread by pbd22 | last post: by
3 posts views Thread by David | last post: by
reply views Thread by Clay Hobbs | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.