Ask Experts Questions for FREE Help!
 

Free Answers in 3 Easy Steps

Register Now
3 Steps
 


Ask QuestionsprogressAnswer QuestionsprogressBuild ReputationprogressBecome an Expert
 
At Ask Me Help Desk you can ask questions in any topic and have them answered for free by our experts. To ask questions or participate in answering them you must register for a free account. By registering you will be able to:
  • Get free answers from experts in any of our 300+ topics.
  • Accept money for answers that you provide.
  • Communicate privately with other members (PM).
  • See fewer ads.
  View Answers    Answer this question    Ask a question  
 

RickJ
May 22, 2007, 09:13 AM
I suppose this might be more of an "other software" issue than a javascript issue...so let me know if you think it should be moved...

In webpages I use javascript to hide email addresses from bots. I want to search the files of the websites for these javascript uses so I can change the email address in some of them...

When I use Windows to search the folder that all the .html files are in Windows does not find text that is used in javascript.

How can I search my files for all uses of the javascript?

If it helps, here's an example:


<script language="JavaScript" type="text/javascript">
<!--
document.write("<A HREF='mailto:"+"rick@somewebsite.org"+"'>"+"Contact"+" Rick Jackson"+"</A>");
//-->
</script>


Thanks!

RickJ
May 22, 2007, 09:19 AM
PS. Of course I know I can open each page with notepad and search it that way, but I'm looking for something that will search the whole folder of all .html files.

jstrike
May 25, 2007, 12:22 PM
I use UltraEdit (http://www.ultraedit.com).

It can do a search and replace inside of files.

HTH.

RickJ
May 25, 2007, 02:44 PM
Thanks J. I do see they claim to be useful for javascript, so will check out their free trial. I'll post back to confirm how it went.

RickJ
May 29, 2007, 04:12 AM
I tried that app and unless I'm not figuring out how to use it right, it will not search a folder for files that contain a string of text I'm searching.

Is that right?

My goal is to search a folder for a string of text that is within a javascript...just like Windows will search a folder for a string of text in any file in the folder...but Windows will not find text that is in javascript...

jstrike
May 29, 2007, 04:29 AM
In UltraEdit...
Click Search
Select Find in Files.
Type in what you want to find (rick@somewebsite.org) Keep this as small/short as possible to maximize your results.
For In Files/Types enter *.html;*.js (Semicolon to separate)
Make sure you have the right directory in the Directory box.
Under Search In select "Files Listed"
Make sure "Search Sub Directories" is checked.
Click Find.
The results will open in a box at the bottom of the editor. You can double click on the results to open the file in the editor.
The Replace in Files selection works the same way except you give it what you want to change the text to. This is a bit riskier for large changes so I'd recommend doing a Find in Files first to see what it's going to look like.