Search And Replace
Find a word or a name across the content of a site and replace it in the items you choose, from jContent: every change is previewed before it is written, links, tags, system values and sub-pages are never touched, and everything runs with the editor's own rights. In English and French.
Search and Replace adds a Search & Replace app to jContent. A product is renamed, a slogan changes, a person leaves: editors find every place the old wording appears in the site, check what will change, and replace it in one pass, without opening each content item.
Find
- Search the content of the site in the language you choose, through Jahia's full-text index. Upper and lower case, accents and formatting do not hide a match.
- Narrow the results by content type and by creation or modification date. Also find parts of words finds a term inside longer words when the index finds nothing.
- Each result shows its content type, its path, a link to open its page or folder in jContent, and the text around every match, highlighted.
Check
- Matches the replacement will not change are shown apart, under Not replaced, with the reason: a system value, a link or a list value, or a term only found with other accents or split by formatting.
- An item with Nothing to replace cannot be selected.
- Choose the properties to update, then Preview: the server shows, for every selected item, each value before and after, computed with exactly the rules of the replacement.
Replace
- Only the text editors write changes: titles, descriptions, text and rich text. Links, image sources, tags, URLs, list values and system properties stay as they are, and in rich text only the visible text changes, never the markup.
- Selecting a page covers its title and the content of its areas, never its sub-pages. A folder covers only itself.
- Only the language you searched in changes. Each item is saved on its own: an item that cannot be changed is reported, the others are kept.
- Nothing is published: changes wait for your usual publication.
Secure by design
- Everything runs with the editor's own Jahia rights: search only returns content they can read, and an item they may not change, or not in that language, is refused.
- Using the app requires the searchAndReplace permission on the site. Site administrators hold it; grant it to other roles as you see fit.
- Rich text shown in the results and the preview is sanitized with an allowlist, so content cannot run code in the back office.
Built with Jahia's own design system, in English and French.
Requirements: Jahia 8.2 with jContent 3.7 or later. Enable the module on the sites that use it. Documentation and full change history: github.com/smonier/search-and-replace.
Screenshots
How to install
- Build the module jar from the project root:
mvn clean install
- Confirm the artifact exists:
ls -l target/search-and-replace-1.0.0-SNAPSHOT.jar
- Install it in Jahia:
- Open Jahia Administration > Modules.
- Upload/install target/search-and-replace-1.0.0-SNAPSHOT.jar.
- Start the module if not auto-started.
- Verify module activation:
- Check module status is Started in Module Manager.
- Optionally check logs for GraphQL extension/provider activation.
- Use it on a site:
- Open JContent for a site where the module is installed.
- Go to Content tools and open Search and Replace.
- If not visible:
- Ensure the module is installed for that site (search-and-replace).
- Clear browser cache and refresh JContent.
- Restart Jahia if GraphQL schema cache didn’t refresh.
FAQ
Where is the app in jContent?
In the Content Tools accordion, entry Search & Replace, on the sites where the module is enabled, for users who hold the searchAndReplace permission.
Who can use it?
Site administrators, through the searchAndReplace permission, which sits under site-admin. To open it to editors, add the permission to their role in Administration > Roles. Whoever uses it can still only read and change the content their own rights allow.
Why are some matches listed under "Not replaced"?
The replacement changes only the text editors write. A tag, a link, a list value or a system property is shown for information but never changed, and so is a term found only with other accents or split by formatting. An item where nothing can be replaced shows Nothing to replace and cannot be selected.
Does it change sub-pages?
No. Selecting a page covers its title and the content of its areas; each sub-page is a result of its own.
Are the changes published? Can I undo them?
Changes are saved in the edit workspace and published with your usual publication, so you can review them before visitors see them. There is no undo button: check the Preview, which shows every value before and after.
MIT License
Copyright (c) 2026 Stephane Monier
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.