mpmcleod
Jun-08-2006, 11:10 AM
I am having some problems with making RegExp work in both FF and IE. Specifically it has to do with the /.
In FF the following works fine:
replaceText = new RegExp(">save photo</a>\\s*\\|");
if ( replaceText.test(document.body.innerHTML) == true) {
}
but it doesn't work in IE nor in Opera.
I have tried escaping the / by using 1,2 and 3 \ but none works.
What I am trying to do is shown here:
http://mpmcleod.smugmug.com/gallery/1470992
Currently I have a second routine that is called which checks '>save photo<' and replaces just that text for IE and Opera.
thanks for any help or ideas.
In FF the following works fine:
replaceText = new RegExp(">save photo</a>\\s*\\|");
if ( replaceText.test(document.body.innerHTML) == true) {
}
but it doesn't work in IE nor in Opera.
I have tried escaping the / by using 1,2 and 3 \ but none works.
What I am trying to do is shown here:
http://mpmcleod.smugmug.com/gallery/1470992
Currently I have a second routine that is called which checks '>save photo<' and replaces just that text for IE and Opera.
thanks for any help or ideas.