I have been investigating and this seems to be a common issue and I attempted to apply a fix so it would strip out 'bad' characters:
public string CleanseSearchTerm(string input)
{
System.Text.RegularExpressions.Regex rgx = new System.Text.RegularExpressions.Regex("[^a-zA-Z0-9 -]");
input = rgx.Replace(input, "");
return input.ToString();
}
However, the issue is that this error is getting generated before it has a chance to hit my method to strip out 'bad' characters. Any ideas of how this can be resolved?
Umbraco Lucene search breaking on 'special characters'
When a user inputs certain special characters i.e a html tag, the user receives this:
Error loading Partial View script (file: ~/Views/MacroPartials/ezSearch.cshtml)
I have been investigating and this seems to be a common issue and I attempted to apply a fix so it would strip out 'bad' characters:
However, the issue is that this error is getting generated before it has a chance to hit my method to strip out 'bad' characters. Any ideas of how this can be resolved?
Hello,
The issue may be two separate dlls are used and both are using SearchResult.
Go to: Partial View Macro Files -> ezSearch
In the bottom choose the one you want for ezSearch
is working on a reply...