I have a couple of easy ones. These are "hanging chads" from a conversion that I never caught and never got back to.
I have the following instances of code related to old animated smilies
This one is a broken path (not a full URL)
Code:
/DesktopModules/ActiveForums/themes/_default/emoticons/biggrin.gif
This one is the full IMG code link
Code:
[IMG]http://www.myforum.org/DesktopModules/ActiveForums/themes/_default/emoticons/whistling.gif[/IMG]
and I need to change these to
Code:
[IMG]http://www.myforum.org/data/emoticons/whistling.gif[/IMG]
The filename is not relevant, it's only this
Code:
/DesktopModules/ActiveForums/themes/_default/emoticons
that needs to change to this
It's easy to fix with
Quick
Reg
Code:
/\/DesktopModules\/ActiveForums\/themes\/_default\/emoticons/i
repl
But that also catches the "broken" ones in a way that makes them difficult to then pinpoint - i.e. I have to look for /data/emoticons that is not part of a larger URL.
So I figure if I first fix the full URLs, all that will be left will be the broken ones.
I need the regex then for matching this
Code:
[IMG]http://www.myforum.org/DesktopModules/ActiveForums/themes/_default/emoticons/ABCDEFG.gif[/IMG]
and changing it to this
Code:
[IMG]http://www.myforum.org/data/emoticons/ABCDEFG.gif[/IMG]
where ABCDEFG is one of many .gif filenames like sad, biggrin, wink, angry, cry, blink, rolleyes, etc.
Which I THINK is this
Code:
(\[IMG\]http:\/\/www\.myforum\.org)\/DesktopModules\/ActiveForums\/themes\/_default\/emoticons(\/[\w\-]+\.gif\[\/IMG\])
and sub this