Get [URL] and [IMG] data in array (post_id => array(url, title)) from posts


Well-known member
If a post with id=5 is like this [U RL should be URL]

Hello [U RL='[url]']Googlelink[/url][/U RL], this is [U RL][/U RL] [I MG][/I MG]

it should return this array
[5]['url'][0]['link'] =""
[5]['url'][0]['title'] "Googlelink"
[5]['url'][1]['link'] =""
[5]['url'][1]['title'] ""
[5]['img'][0] = ""

I want to fetch the data from existing posts, too. It would be best to hook into an existing routine like rebuild post index. Do you know where I should hook into, and if there is an existing XenForo function that helps me fetch the bbcode data?

BbCode_Parter:: parse() returns an array like above, but is there a parent function that is executed in the rebuild counters so I don't have to rewrite a "rebuild bbcode for all posts" function - and with the added benefit to store the bbcode in cache?
Last edited: