XF 1.3 Trying to run a SQL query for youtube links

dawg

Well-known member
I have already tried the find and replace and is not working for me since i have thousands and thousands of video links. I tried the example code to load 5000 at a time but it degrades over time and you are saving 20 videos at a time. I just dont have the time.


I just want to fix youtube nothing else. I tries this SQL query but nothing. The variable is stumping me.

Code:
UPDATE xf_post SET message = REPLACE(message,'#\[video=youtube;([^\]]+)\]([^\[]+)\[/video\]#siU','[media=youtube]');

Any help would be appreciated.
 
It's probably upper case - change youtube to YOUTUBE.
But i dont see how that command will fix a link like this one.

Code:
[video=youtube;-pzXyOWa7dg]http://www.youtube.com/watch?v=-pzXyOWa7dg[/video]

Doesn't work lower or upper case. I think we need some kind of variable but I'm no expert.
 
Top Bottom