Timeline for Find and Replace Links from the value of Rich text field
Current License: CC BY-SA 3.0
8 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Oct 11, 2013 at 18:31 | comment | added | Will Price | I think your answer gives a valid approach to the question "Can I process the output and replace links with some other stuff", however the question leads me to believe that the asker is actually trying to resolve dynamic links in JSP - so should use the standard taglib | |
Oct 11, 2013 at 16:51 | comment | added | Dominic Cronin | The question specifically mentions a Rich Text field | |
Oct 11, 2013 at 16:00 | comment | added | Eric Huiza | I wasn't aware we can replace <a href="TcmUri"></a> into <jsp:include><jsp:param /></jsp:include> out of the box. In my answer I am assuming that the Output (Package Item) is a string (XML, Text, Html) then it can be parsed by a RegExp to convert the <a> tag into <jsp:include> | |
Oct 11, 2013 at 15:57 | comment | added | Bart Koopman | @Quirijn I agree, but that is not what Eric is mentioning in his answer ;) | |
Oct 11, 2013 at 15:40 | comment | added | Quirijn | @BartKoopman Then don't parse the Output but rather the input, in other words the Component. | |
Oct 11, 2013 at 14:45 | comment | added | Bart Koopman | @DominicCronin Because the Output item can be XML, but also quite often is plain text (which most of the time you can load into a DOM Document of course). | |
Oct 11, 2013 at 14:40 | comment | added | Dominic Cronin | No. Even if you wanted/needed to re-write functionality that Tridion ships as standard (see Will's answer), why would you use regexes to find links in XML? | |
Oct 11, 2013 at 13:56 | history | answered | Eric Huiza | CC BY-SA 3.0 |