Josiah, I can add a simple logic as whole word option but here whole word means a word separated from other part of the text by two spaces.
The problem is, it will fail to distinguish punctuation. So, it can find " test " but not " test!". Anyway, snr can do many search and replace jobs, but one needs to be careful like the example you gave above! he in she, shell, shelf, ... If TW got a Javascript replace function, the code will be much simpler, if not using current TW features the logic will be difficult to make whole words search. --Mohammad On Thursday, February 28, 2019 at 6:19:57 PM UTC+3:30, @TiddlyTweeter wrote: > > Mohammad > > Really excellent. Its working well and I haven't been able to get it to > fail. It will have huge use I am sure. > > I do think an issue is UNDO. > > Let me show why ... > > On a balmy day SHE took advice that HE needed to walk. > > If we replace "SHE" with "HE" we get ... > > On a balmy day HE took advice that HE needed to walk. > > But it can't easily be reversed just switching "find" & "replace" terms > as you'd get ... > > On a balmy day SHE took advice that SHE needed to walk. > > > I think the simplest way to deal with this is that a Tiddler under s-n-r > is cloned to a state tiddler before changes occur that can be RESTORED. > > What do you think? > > Best wishes > Josiah > > > > Could the tiddler/s you working on be > > On Thursday, 28 February 2019 07:54:26 UTC+1, Mohammad wrote: >> >> Announcement: SNR >> >> This is a simple script, search-n-replcae (*snr*) to search in tiddler >> contents (including all fields) for a searchValue and replace them with >> replaceValue. >> >> See the original post here! >> >> https://groups.google.com/d/msg/tiddlywiki/lTYxRbGon1o/V8PVsvt1AgAJ >> >> >> Demo: https://kookma.github.io/search-n-replace/ >> >> >> --Mohammad >> > -- You received this message because you are subscribed to the Google Groups "TiddlyWiki" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/tiddlywiki. To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/c303bbed-b722-43a0-8b14-ddfb74a5ed5e%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.

