This question about Not sure...: Answered

How can I parse out numbers from a topic name. eg. Item0002

Is there any easy way to get a number from a topic name. For example get "0002" out of a topic named Item0002? .

Answer

Here you go: TWiki:Support/HowToShortenTopicNamesInSearchResult


Thanks. The following example taken from that link works great:
%SEARCH{
  "%TOPIC%"
  scope="topic"
  nonoise="on"
  format="$percntCALC{$REPLACE($topic,1,$EVAL($LENGTH($topic)-4))}$percnt"
}%

It would still be super awesome if we could do something like:
%TRIM{%TOPIC%, 0, 4}%
parameters are: {string to trim, beginning position, end position}

Thanks guys. IsmaelAntadillas
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. see CopyrightStatement. Creative Commons LicenseGet Foswiki at sourceforge.net. Fast, secure and Free Open Source software downloads