joined:May 19, 2016
I'm getting a huge volume of 500 errors generated by various bots when they call pages with asp functions embedded via include files. I've now blocked everything but the major search engines to reduce the impact, but I'd like to know if there's something I'm missing and/or any way to fix it properly.
The most common issue is a short function for replacing quotes and apostrophes in form data with db friendly equivalents ... I've been using it for years, but now when the Googlebot hits it I get an error saying it's an invalid use of 'replace', because there's no variable being passed to the function.
There is an if/then check to ensure there's a value submitted, but that doesn't prevent the Googlebot from trying to execute the function empty?
The pages display quite OK in Webmaster Tools, though the scripts are loaded after the page body, so that's expected. No errors reported there though.
Any suggestions or directions to relevant resources much appreciated... whether there's a better way to perform the function, or a better way to manage the bots?
This is really starting to impact all the sites on this server with timeouts and crashes but so far I haven't been able to find anything relevant.