Welcome to the navigation

Mollit cillum voluptate id excepteur sit sint pariatur, officia adipisicing laborum, non qui dolore sed irure nostrud consectetur duis fugiat incididunt commodo aute nisi sunt. Esse do sunt ex ipsum non laboris incididunt aliqua, quis sit lorem in in cillum ut culpa eu eiusmod commodo dolor est aliquip pariatur, enim

Yeah, this will be replaced... But please enjoy the search!

EPiServer Find Wildcard searching

This is a bit of a hidden feature in EPiServer Find. Typically when you want wildcard searching miscellaneous blogs will make us use the EPiServer UnifiedSearch. There is a much simpler solution than so.

public static class SearchExtensions
{
    public static IQueriedSearch<T> WildCardSearch<T>(this ITypeSearch<T> search, string query)
    {
        return search.For<T>(query, q => q.Query = string.Concat("*", query, "*"));
    }
}

Use it like this

var result = SearchClient.Instance.Search<FAQItem>()
                    .WildCardSearch(query)
                    .OrderByDescending(x => x.Name)
                    .FilterForVisitor()
                    .GetContentResult();
Please note that this portal is a BETA site , I will continuously improve all functionality and performance during the coming weeks / the author