The Search Form feature in the Automatic YouTube Gallery plugin allows visitors to search for videos within a specific gallery, making it easier to find relevant content quickly. It is especially useful for galleries with a large number of videos, helping users locate the exact content they are looking for without scrolling through multiple pages.
How to Enable the Search Form?
To enable the search form for a gallery:

- Navigate to YouTube Gallery / Dashboard in your WordPress Admin Dashboard.
- Open the Shortcode Builder.
- Go to the Search Form tab.
- Check the Search Form option to enable it.
Note: If you’re using the Gutenberg block or widget, you’ll find the same option under the Search Form tab.
Once enabled, a search box will appear above the gallery on the front end.
Supported Layouts:
The search form is supported only on the following layouts:
- Classic
- Popup
- Inline
How the Search Form Works
The search form uses a custom-built database structure where video data loaded into a gallery is stored and indexed. When a user performs a search, the plugin searches through this stored data and displays matching videos from the current gallery. This ensures fast, relevant results without sending additional requests to the YouTube API.
The search functionality only works with videos that have been loaded into the gallery and stored (indexed) in the database. This means:
- If your gallery is paginated and only some pages have been visited, only the videos from those pages are searchable.
- Videos from pages that haven’t been visited yet will not be included in the search results.
How to Ensure Accurate Search Results
To ensure the search form works as expected across your entire gallery, all videos need to be indexed in the database.
As a site owner, you can simply visit all the pages of the gallery yourself to load and index the videos. Or simply allow your visitors to browse the gallery—videos will be indexed automatically as they’re viewed.
Once all videos are indexed, the search form will provide complete and accurate results for every video in the gallery.
Coming Soon
We’re working on new features to improve the indexing and search experience:
- Automatic Indexing: We’re planning to implement a CRON-based automation that will periodically index all videos in the background—even if they haven’t been viewed manually.
Stay tuned for future updates!
FAQ
Why is the search not finding some videos?
This usually happens when the videos haven’t been indexed yet. Videos are only searchable once they’ve been loaded on the front end. Make sure to visit all gallery pages or allow visitors to naturally browse the gallery to complete the indexing process.
The Search Form is a valuable addition to enhance user experience, particularly for large galleries with extensive video collections. Enable the search form and ensure videos are indexed to get the most out of this feature.