Ajax Search Pro Documentation
Get Ajax Search Pro!Get SupportKnowledge BaseDevelopment
  • Ajax Search Pro Documentation
  • GDPR and Cookie policy
  • Video Guides
  • Plugin Updates
    • Automatic Updates
      • Activation on Development and Staging environments
      • Managing purchase codes
      • Purchase Code (license key)
    • Manual Updates
    • Safe Update Guide
    • Plugin update issues or errors
    • Disabling update check
  • Installation instructions
    • Uninstallation & Reset
  • Getting started
    • Importing from the Lite version
    • Editor Blocks
    • Search Shortcodes
    • Search Widget
    • Gutenberg and Other Page Editors
    • Replacing the default theme search bar
    • Placing the search shortcode in theme files
    • Search as menu item
    • Custom result box position
    • Custom filters box position
    • Shortcode generator
  • Search Sources
    • Search Engine
    • Post, Page, Product and other Post Type Search
    • Searching Titles, Content, Excerpt
    • Search in custom fields
      • Search By Product SKU
    • Search by categories, tags or other terms
    • Search in Attachments
      • Mime types table
    • Search in File contents (pdf, word, excel etc..)
    • Search in Users
      • User meta fields
    • Limits (number of results)
    • Categories and terms as results
    • Image options
    • Result ordering
    • Peepso Groups & Group activities search
    • Grouping title duplicates
  • Behavior
    • Return/Enter key and Magnifier icon click actions
    • Search logic (primary and secondary)
      • Exact Matches vs Fuzzy Matches
      • Search logics explained
    • Live search triggering events
    • Results page override
    • Results, Archive Page and Shop Live Search and Filter
  • Elementor Integration
    • Elementor Pro Posts Widget Live Filter
    • Elementor Loop Grid Integration
    • Elementor Pro Product Widget Live Filter
    • Custom results page with Elementor Pro
    • Elementor custom search page archive override and live filter
  • Other Integration
    • Jet Engine Listing Grid Integration
  • Multisite Settings
  • Frontend Search Settings & Search Filters
    • Settings layout, position and visibility
    • Generic Selectors
    • Content Type filters
    • Date filters
    • Category and Taxponomy term filters
    • Post type Filters
    • Custom field filters - selectors
    • Search button
    • Reset button
  • Layout Settings
    • Result Layout Types
    • Results information box
    • Results position & snap
    • Content, author, date and description in results
    • More results loader and infinite scroll feature
    • Results behavior
    • Results text keyword highlighter
    • Compact search box layout
    • Auto Populate - Automatic search results on initial page load
  • Autocomplete and Keyword suggestions
    • Autocomplete
    • Results and Keyword suggestions
    • "Try these" - suggested phrases
  • Theme Options - Visual changes to the search bar
    • Theme chooser
    • Preview
    • Search box and input field layout
    • Settings and Magnifier icon
    • Settings dropdown
    • Typography
  • Index Table
    • Generating the index table
    • Enabling index table engine
    • File Content Search Addon
    • Index table FAQ
    • Synonyms
  • Relevance Options
  • Advanced Options and Uses
    • Using the Results shortcode as a custom results page
    • Shortcodes in results content
    • HTML tags in results
    • Primary and Secondary title and description fields
    • Advanced title and Content fields
      • User Search - Advanced Title and Content fields
    • Excluding & Including results
      • Exclude by category or terms
      • Exclude or Include by authors (users)
      • Exclude or Include by date
      • Exclude by Item or ID
      • Include by ID
      • Include by categories or terms (restrict to category)
      • Exclude or Include by custom field values
    • Grouping results
    • Keyword Exception & Exclusions
  • Result priority settings
    • Individual Priorities
    • Priorities by Rules (priority groups)
  • Performance Tuning
    • Fine tuning the search configuration
    • Cache
    • Visual performance
    • Ajax performance tracker
  • Compatibility Settings
    • Javascript Compatibility
  • Google Analytics Integration (GA4)
    • Tracking with Google Site Tag (gtag.js)
    • Tracking with Google Tag Manager
    • Site Search Tracking
  • Troubleshooting
    • Styling issues
    • The response data is missing from the ajax request error message
  • Translating components
    • Translating with WPML
    • Translating with Polylang
  • Pre-Purchase FAQ
  • Plugin API
    • Actions list and usage
    • Filters list and usage
    • asp_query_args filter
    • Theme functions
    • Front-end filters API
    • Javascript API
  • Other Useful Things
    • Additional search keywords for post types
    • Negative keywords
    • Meta box on post editor screen
Powered by GitBook
On this page
  • Prerequisites
  • Step 1 - Index table configuration
  • Choosing the Attachment post type to index
  • Media Service parser feature - Recommended
  • Choosing the file mime types to index
  • Enabling file content indexing
  • Save and Index
  • Step 2 - Search instance configuration
  • Local Parsers
  • Minimum requirements & supported formats
  • Possible limitations - fair use
  1. Search Sources

Search in File contents (pdf, word, excel etc..)

This section will guide you each step to index and search media f contents.

PreviousMime types tableNextSearch in Users

Last updated 6 months ago

Prerequisites

To search attachment contents, the index table engine is required. Before you start with this tutorial, I highly suggest reading up the .

Step 1 - Index table configuration

Open up the Index table submenu, located under the Ajax Search Pro main menu.

Choosing the Attachment post type to index

On the General panel, under the Post types to index option, choose the Attachment - Media post type, that will unlock the Media Service and File indexing options.

Media Service parser feature - Recommended

What happens if I don't want use the Media Parser?

Choosing the file mime types to index

Each attachment has a so-called mime type. The file mime type determines what file the system is dealing with.

Too choose the type, simply scroll down to the File indexing options section, and choose the file types you wish to index.

Entering the mime types manually

If you wish, you can switch to manual mode by clicking the >>Enter Manually<< link.

Enabling file content indexing

After entering the desired mime types, the the file content indexing options will unlock (based on which mime types are entered)

Click on the On/Off buttons to switch which file type contents should be indexed.

Save and Index

After choosing all the desired options, it is time to Save the configuration on the bottom of the page, and then generating the index.

Step 2 - Search instance configuration

On the search instance options, go to the Search Sources -> Media Files Search panel. After doing so, change the first two options:

  • Return media files as results: ON

  • Search engine for media results: Index table engine

Save the options, and it is done. The search should return attachments based on their content now.

Local Parsers

Minimum requirements & supported formats

Only some of the parser scripts require some standard libraries to be installed/enabled. Usually these modules are enabled on most server hosts by default.

Older MS office 97-2003 file formats may not work correctly! These include .xls, .doc, .ppt

Indexing other documents is still possible, without meeting these requirements (RTF, TXT, CSV etc..)

Possible limitations - fair use

The local parser libraries are highly optimized, and their performance mostly depends on the actual server performance, however there are a few things to consider when using an average server, that may affect the performance greatly:

  • Document length - documents over 30-60 pages can get very difficult to index, and may fail, especially PDF files. Therefore it is not recommended to use this feature to index long books/documents.

  • File size - documents with large images/attachments can be difficult and costly to read from the servers perspective. Optimally, the document should only contain the text to be indexed, although some graphics should not be an issue at all.

  • Secured or Password protected documents - Secure or password protected documents are not possible to parse.

Registering a (Free version available!) will enable sending the files to an external server for the best and most accurate file indexing.

Once you have a license key, you can on how to enable it - although it is fairly simple, you just put the key into the input field, and hit the Activate button. Once it is activated, the plugin will attempt to index all file types selected via this parser automatically. That's it!

No worries! Then the local, built-in file parser will be used. In most cases they do the job, but they are much less efficient. Please check the section below for more information.

you can find the list of supported mime types.

We are almost done, now the desired search instance needs to be configured to use the index table for attachments. If you have not created a search instance yet, make sure to .

When the is not enabled, the local file parsers are used. Because these have to be executed on your local server, they depend on the local server performance as well, and they are generally less accurate and less efficient.

For Microsoft Office and Open Office documents - and PHP modules (enabled on most hosts) Supported file types: .docx, .xlsx, .pptx, .odt, .ott, .odm, .ods, .odp

Use the - it is much more efficient, and you don't have to worry about anything. It will index all documents as accurately as possible.

Media Service license key
this documentation
Here
do it first
Media Service
ZipArchive
php-xml
Media Service feature
Local Parsers
introduction to the index table