The problem is writing back to the tiddler, where it loses some formatting! Also, it cannot distinguish the whole words like change "is" to "was" in
This is test! --Mohammad On Wednesday, February 27, 2019 at 4:40:44 PM UTC+3:30, BurningTreeC wrote: > > BTC, >> >> I am still struggling with search-n-replace with no success! (also >> split[]joing[] failed) >> I even tried to use JavaScript *replace* macro (while I really want to >> stick to TW script) it simply receives the tiddler text field >> searchValue and replcaeValue, but amazingly it removes some of >> formatting! >> >> So, these questions raised from trial and error with TW scripts to see >> how can I figure out this, using Tiddlywiki widgets, filters, operators... >> >> Any light you can shed to this case is highly appreciated! >> > > What's the problem? The snr macro already had search and replace working > with the use of the example I gave you in the other thread > > What do you want to use the split op for? > > I need a real code example > > > >> >> --Mohammad >> >> >> On Wednesday, February 27, 2019 at 4:11:16 PM UTC+3:30, BurningTreeC >> wrote: >>> >>> Consider the below example in which a macro output contains some >>>> wikitext has been fed to a wikify widget! >>>> >>>> >>>> \define mc() This is a `code` and __underline__. >>>> >>>> >>>> >>>> <$wikify name="result" text="""<<mc>>"""> >>>> >>>> <<result>> >>>> >>>> </$wikify> >>>> >>>> Result is: >>>> >>>> This is a code and underline. >>>> >>>> While I expect an output like this: >>>> >>>> This is a code and *underline*. >>>> >>>> >>>> What is the problem? Note to the code and underlined text! >>>> >>>> --Mohammae >>>> >>>> Note: The use case is to store the result and send it to another widget >>>> (another scope) >>>> >>>> >>>> >>> Hi Mohammad, in cases like this, the wikiparser does its magic first ... >>> >>> do you remember the example I gave you, where I wikified the text field >>> of another tiddler, but viewing it with <$view tiddler="bla" mode="block" >>> format="text"/> >>> >>> <$wikify name="something" text="""<$view tiddler="bla" mode="block" >>> format="text"/>"""> >>> >>> <<something>> >>> >>> </$wikify> >>> >>> the view widget here assures that the plain text comes in ... >>> >>> in your example here you have no such "helper" >>> >>> ... >>> >>> if you change your mc macro to >>> >>> \define mc() >>> \rules only >>> This is a `code` and __underline__. >>> \end >>> >>> ... you prevent the parser from kicking in in this macro block and it >>> works >>> >> -- 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/0499cb2b-180b-4694-9234-ddbc049311f5%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.

