AddSearch supports crawling and indexing several document types. In addition to webpages, AddSearch can crawl and index PDFs as well as Microsoft Word, PowerPoint and Excel documents.
You can set up document types feature by following these instructions or taking the following steps
When the setting is changed, a full re-crawl is required.
Please note: each document counts as a separate page in your plan’s page quota. Enabling the “Document types” feature may cause you to exceed your quota.
The size limit of PDFs is 20 MB. If your PDFs exceed the size limit, you can request a custom limitation.
In addition to the content, AddSearch indexes the metadata from PDFs and Microsoft Office documents. There are settings we can use to enhance what is indexed as well as what is shown in the search results. Please contact AddSearch Customer Support if you need help in setting up the search.
You can filter search results based on document types using a filter object. The following document types are automatically indexed with these category identifiers:
The following examples show how to use document types as filters with the Search Widget. Before constructing the filters, please note the following:
Include search results with PDF as the document type:
<!-- Settings object --> <script> window.addsearch_settings = { "asw_01": { "baseFilters": { "category": "doctype_pdf" } } } </script>
<!-- Search script --> <script src="https://cdn.addsearch.com/v5/addsearch-ui.min.js?key=YOUR_PUBLIC_SITE_KEY&id=asw_01"></script>
Include search results with pptx as the document type:
<!-- Settings object --> <script> window.addsearch_settings = { "asw_01": { "baseFilters": { "category": "doctype_pptx" } } } </script>
<!-- Search script --> <script src="https://cdn.addsearch.com/v5/addsearch-ui.min.js?key=YOUR_PUBLIC_SITE_KEY&id=asw_01"></script>
You can also create combinations of document types to include in the search results. For instance, the following filter includes search results with PDF, pptx, and doc as the document types:
<!-- Settings object --> <script> window.addsearch_settings = { "asw_01": { // Use "or" operator to match any of these document types "or": [ { "category": "doctype_pdf" }, { "category": "doctype_pptx" }, { "category": "doctype_doc" } ] } } </script>
<!-- Search script --> <script src="https://cdn.addsearch.com/v5/addsearch-ui.min.js?key=YOUR_PUBLIC_SITE_KEY&id=asw_01"></script>
For more information on category filters, please refer to the documentation on Search Filters.
We’re always happy to help with code or other questions you might have. Search our documentation, contact support, or connect with our sales team.