Jump to content

vBulletin 4 importer [video] tag regex possible problem


sudo
Go to solution Solved by Marc Stridgen,

Recommended Posts

Hi

I have been testing the importer against our vbulletin 4 install and I think I may have spotted a possible problem with the importer.

Carnage trailer is out - 

[video=youtube_share;-FmWuCgJmxo]https://youtu.be/-FmWuCgJmxo[/video]

Above is the post content example in vb4 but the regex on line 588 of the importer Vbulletin.php is:

#\[video=[a-z_]+;[a-z0-9_]+\](.*?)\[\/video\]#i

Which wont match as the second part needs to add a "-" into its search.

#\[video=[a-z_]+;[a-z0-9_-]+\](.*?)\[\/video\]#i

The url for the video is correct and has a "-" in it as do quite a few video share links we have such as [video=youtube_share;pMJFM-p5a-c]. The rebuild posts task does embed the videos but it leaves the [video=youtube_share;-FmWuCgJmxo] part behind as its not been stripped by above.

I think the addition of the "-" above should fixed our import but I am going to run it again to confirm as it takes a while.

Cheers

Edited by sudo
Link to comment
Share on other sites

  • 1 month later...

I see this has not been added yet to the latest build. The minor change I made to covert/sources/software/core/vbulletin.php above by adding the "-" fixed the issue for us.

Its not a major major issue but it would be frustrating for any sites with a lot of youtube videos which get broken embedding because of a missing -

Edited by sudo
Link to comment
Share on other sites

8 hours ago, sudo said:

I see this has not been added yet to the latest build. The minor change I made to covert/sources/software/core/vbulletin.php above by adding the "-" fixed the issue for us.

Its not a major major issue but it would be frustrating for any sites with a lot of youtube videos which get broken embedding because of a missing -

It has not been addressed in the core platform as of yet, no.

Link to comment
Share on other sites

  • 3 months later...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...