[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

Searching in Dreamweaver

Posted on 2004-10-25
9
Medium Priority
?
168 Views
Last Modified: 2010-04-25
We are trying to update a website to not include any mailto tags, but instead to have those link to a email form where the emails are sent server side.

Anyway I did a search on the site using
mailto:
as the seach text. I got ZERO results.  However, if I remove the : from the end of the word mailto I get 537 results.  But the text IS mailto: in every single result.

Any ideas as to why?



ANyway my main question is how do I search for all results that do NOT match a specific email address.

For example, I KNOW that every page has a link at the bottom that goes to webmaster@test.mydomain.com
Is there a way to specify with regular expression searching or something in DW that I want to find every OTHER mailto in the site - but NO mailto that is mailto:webmaster@test.mydomain.com?


Thanks!
0
Comment
Question by:mrichmon
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
9 Comments
 
LVL 8

Expert Comment

by:alexhogan
ID: 12413044
Give this a try;

(\w[-._\w]*\w(?<!webmaster)@\w[-._\w]*\w\.\w{2,3})

It should find any email address that doesn't have 'webmaster' preceeding the '@'.
0
 
LVL 35

Author Comment

by:mrichmon
ID: 12413649
Nope - came up with 0 results.

Any other ideas?
0
 
LVL 8

Expert Comment

by:alexhogan
ID: 12413941
Hmm..,

It might be the shortcut characters I'm using that DW doesn't like.

Try it like this and see if it produces results.  You should get the 500+ returns.

(\w[-._\w]*\w@\w[-._\w]*\w\.\w{2,3})

This will bring back all email addresses.

I put both this one and the other expression through RegEx Coach and they passed.

0
Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

 
LVL 35

Author Comment

by:mrichmon
ID: 12414045
Yes it did come back withh all of the results.

Is there a way to modify so I get only those results that don't have a specific email in it?  Because I can get the same results as this regular expression just be searching for "mailto"
0
 
LVL 8

Expert Comment

by:alexhogan
ID: 12414192
Yep..,

Try this;
(\w[-._\w]*\w(?!webmaster)@\w[-._\w]*\w\.\w{2,3})

I think that the < that was there before was causing the problem.
0
 
LVL 8

Expert Comment

by:alexhogan
ID: 12414499
I just tried the first expression and it worked for me.  I was able to determine between these email addresses.

webmaster@mydomain.com
me@mydomain.com
meagain@mydomain.net

It returned the two email addresses.
0
 
LVL 35

Author Comment

by:mrichmon
ID: 12415803
Okay I just got back from a meeting and had a chance to try it.

Unfortunatley it did not work either.  All email results were returned - including the webmaster@mydomain.com  I tried it with a couple different email addresses and they were always included in the results.
0
 
LVL 8

Accepted Solution

by:
alexhogan earned 1500 total points
ID: 12417059
I have been searching everything I can on using regex's in DW and have come up with the same concensus.  It works sporadically and when simple expressions are used.

DW seems to have a documented problem using regex's with the \s, \w, and some bracketed groups.  It also seems to have trouble with tags that have >< without a space > <.

Although I was able to do a successful search using the expression that I posted above, when I ran it several times it failed more times than not.  I can see how this can be extremely frustrating especially when you run your expression through something like Regex Coach or Regulator, and is passes only to find it doesn't work in DW S&R.

I did find a solution that you might want to consider.

This is a free download.
http://www.handyarchive.com/Web-Development/Web-Design/10605-Replace-Tool.html

It is a find and replace utility that when I ran it using the original expression that I posted;
(\w[-._\w]*\w(?<!webmaster)@\w[-._\w]*\w\.\w{2,3})
it found everything but the address(es) webmaster@mydomain.com/net/org/us everytime.  You might want to take a quick look at it.

I was impressed enough that I'm going to add it to my utilities list.
0
 
LVL 35

Author Comment

by:mrichmon
ID: 12423111
Well thanks for the help.

At least I know I'm not crazy or writing my regex's totally wrong.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Adobe Dreamweaver CS5 is a WYSIWYG web page editor that has advanced HTML, CSS, and Javascript rendering functionality and is probably the most well-known HTML editor available. Much of Dreamweaver's appeal centers around the Design View interfac…
This article is very specific and is only intended to help if you are installing Dreamweaver 8 in a Windows 7 environment with Office 2007 installed.   I'm not sure why Microsoft tends to release OS' that should not be released but they do.  Windows…
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…
Suggested Courses

649 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question