Hi, I'm looking for a way to search the generated source of a webpage ( document.innerHTML) for a string, in javascript.
I wouldn't want to use window.find() since i might have to look for id's or names too.
Any help would be appreciated.
Thanks
Hi, I'm looking for a way to search the generated source of a webpage ( document.innerHTML) for a string, in javascript.
I wouldn't want to use window.find() since i might have to look for id's or names too.
Any help would be appreciated.
Thanks
document.innerHTML
is undefined
var source = document.getElementsByTagName('html')[0].innerHTML;
var found = source.search("searchString");