AndreasW2000 Posted November 9, 2020 Posted November 9, 2020 In my older forum I had added some custom BBCode to the BBCode parser as well as a custom icon to the editor. Now, even if I turn on BBCode parsing, there does not seem to be any option to add custom BBCode anywhere. So probably I would need to edit some files. Where would I find this?
Nathan Explosion Posted November 9, 2020 Posted November 9, 2020 You won't find it as the specific feature was phased out quite a long while ago. Instead, you now add buttons to the Editor via Customization -> Editor -> Toolbars -> Add button -> Custom
AndreasW2000 Posted November 9, 2020 Author Posted November 9, 2020 Ah, cool, that will definitely help from now on. Still I also need to be able to parse all the custom BBCode which has been added in the past 15 years. Where can I find and edit the parser?
bfarber Posted November 9, 2020 Posted November 9, 2020 There's no way to support custom bbcode in 4.5.x. You can enable/disable parsing of "core" bbcode still, but it is deprecated. SeNioR- 1
AndreasW2000 Posted November 10, 2020 Author Posted November 10, 2020 Which is good. What's bad is is that my 15 year old forum is now full with cryptic sniplets across some 400K postings and I have no way to filter them out or better yet parse them with any logic.
Nathan Explosion Posted November 10, 2020 Posted November 10, 2020 Might have to get busy with SQL - it's how I converted my custom bbcode prior to upgrading to IPS 4.x Post an example of one your custom bbcodes for people to look at - what are the tags used? What do they convert to?
AndreasW2000 Posted November 10, 2020 Author Posted November 10, 2020 Oh it's really old, don't know what my replacer-code was. It used the old 10-digit ISBN numbers of books and would then replace my custom BBcode ISBN - e.g. [ISBN=3956691416] - with an iframe widget available viathe Amazon Associates program, so that it would display a small product preview including my affiliate code. Maybe the Books plugin can do something similar in the future, looking into that, but the challenge remains to get rid of the old [ISBN=??????????] and replace it with something meaningful. I did a search and found out it was used about 800 times, so manual is no option. And SQL is not something I'd dare to touch nowadays, last time I did something resembling that was using Lotus 1-2-3 on 80286 machine ... 🤐
Nathan Explosion Posted November 10, 2020 Posted November 10, 2020 (edited) So the content is currently stored as "[ISBN=3956691416]"? 7 minutes ago, AndreasW2000 said: replace it with something meaningful What do you want it replaced with? If you don't know what it is then figure out what you might want to replace it with and then come back here and provide the code. If I am able to, I'll see if I can dig up my query from my own efforts. Edited November 10, 2020 by Nathan Explosion
AndreasW2000 Posted November 10, 2020 Author Posted November 10, 2020 Yes, it's stored as [ISBN=??????????] - meaning always some 10-digit number as parameter in the brackets. I mean, sure, it's not super ugly, but also pointless and makes the main information of that posting missing, which was the product preview. Thanks for the offer, that would be awseome! I shall come back. Once I have looked at the Books plugin if that's useful for me and if maybe it's possible to replace the old code with something that make it useful for the plugin even.
Recommended Posts