Resource icon

Post Content Find / Replace 1.0.0

No permission to download
Not a problem.

Seeing something other than the default in your post I have edited the expression above to account for the following possibilities:
[USER=144]Punita[/USER]
@[USER=144]Punita[/USER]
[USER=144]@Punita[/USER]

So yes now that expression should work for you.

Happy new year to you as well.
 
Last edited:
Just to induce posterity here and now in this new year here as well as in those yet to come, could I trouble you to put full examples within [code]<TABLE class=POST DATA HERE</TABLE>[/code] blocks like this?

For non XF standard stuff I really need to see full examples including the tags (html, bbcode etc) and the content within them in order to establish the pattern which I need to lock onto.
 
Just to induce posterity here and now in this new year here as well as in those yet to come, could I trouble you to put full examples within [code]<TABLE class=POST DATA HERE</TABLE>[/code] blocks like this?

For non XF standard stuff I really need to see full examples including the tags (html, bbcode etc) and the content within them in order to establish the pattern which I need to lock onto.

Checked and found some data that is important to the context between Acronym. So only other 2 are 'important'. Look not so easy to do, if to much trouble you can disregard the request ;) It is not so important that it has to go.

Here is Table Style
http://forum.bodybuilding.nl/topics/ik-naar-n-jaartje-flink-bulke.250481/page-3#post-5142936

Table Class
http://forum.bodybuilding.nl/topics/cell-tech-hardcore-pro-series.248750/#post-5019527
 
Last edited:
What I wonder is why you are just not removing the tags anyways (or creating custom bbcodes for).

Unless you have something different going on I'm pretty sure that those html type of tags are useless to you within your forum posts as they are right?

There are a bunch of solutions I can imagine all of which (not knowing the entire situation and all that) where I would think of keeping the content as being the only important part and the manipulation of the tags around them being the secondary cause.
 
What I wonder is why you are just not removing the tags anyways (or creating custom bbcodes for).

Unless you have something different going on I'm pretty sure that those html type of tags are useless to you within your forum posts as they are right?

There are a bunch of solutions I can imagine all of which (not knowing the entire situation and all that) where I would think of keeping the content as being the only important part and the manipulation of the tags around them being the secondary cause.

That are old tags from the vBulletin days (some of them i think, i only know the forum frum 2006 as a member and previous admin has past away a few months ago). They are indeed useless but only apear in some content till 2010 and most of them in 2002-2005.

Was also thinking of just keeping the content when looking at it now.
 
I'm trying to update all the vB4 hyperlinks in my post using this tool. I don't think I quite have it right.
Here is an old link: http://www.zl-oa.com/forums/showthread.php?14919-CARB-REBUILD-KIT-by-K-amp-L
Here is a new link: http://www.zl-oa.com/community/threads/carb-rebuild-kit-by-k-l.14919/

I tried this:
Quick find:
Code:
www.zl-oa.com/forums
Regular Expression:
Code:
#http://www\.zl-oa\.com/forums/[a-zA-Z0-9_\-]+/([0-9]+)-[a-zA-Z0-9_\-]+\.html\#post-([0-9]+)#siU
Replacement String:
Code:
http://www.zl-oa.com/community/posts/\2/

It doesn't do anything, can somebody help?
 
Awesome work @EQnoble !

I did have to slightly modify the Replacement string, but I figured it out.

Code:
\1community/threads/\3.\2

THANK-YOU!!!! Hope you slept well ;)
 
I overslept, and did that WELL. Apparently after reading my above post I would also say that I went to sleep well before I was laying in bed.

Good catch on that fix.

UPDATED
 
Tried to convert youtube links to embeds.. now i got these in the posts:

-> www.[/media]]YouTube - Mike Bernardo vs Jerome Lebanner

-> [ media=youtube]GcZdh02cW5g[/media]

First one i used the wrong replace \1 instead of \3 and it auto-fetched the title (was on). Think this one can't be fixed.

Second one is correct, but not embeded (added a space because here it embeds). When i edit and save post it embeds, but with a favicon in front. So i checked and there is a link added on the embed code -> http://[media =youtube]GcZdh02cW5g[/media]


What i used:

quick search: youtube.com

regex: #(?<!view\:\s|\')http\:\/\/(www\.)?youtube.com\/watch\?([a-z]+\=[^\=\&\'\[\]\s]+\&)*v\=([^\]\&\[\'\s]+)(\&[a-z]+\=[^\=\&\]\[\s]+)*#siu

replace: [media =youtube]\3[/media]

How can i fix? I think a backup restore is the best option (server made one last night) because there is no info to convert with first link (4500 links). Also what i used was for plain tekst to convert to links i found out..
 
Last edited:
@Jake Bunce

I'm trying to remove the tapatalk sig spam using this addon and have entered "tapatalk" in the Quick find field and the following for the Regular expression field:

/Sent from my (.+) using Tapatalk/i

And the addon finds a number of posts but if I leave the Replacement String field blank (since I'm trying to remove the sig) I get an error of:

"Please enter a valid message."

Is there a way to use this add-on to search for the above expression and have it simply remove it without adding more text?
 
@WoodiE

If it doesn't allow an empty replacement then you could always use a non-empty replacement like:

___OLD TAPATALK SIG___

Then run a replacement query afterwards:

Code:
UPDATE xf_post
SET message = REPLACE(message, '___OLD TAPATALK SIG___', '')
 
Thanks @Jake Bunce I was able to correct the issue. It seems the first post it was going to replace only had an attachment image (not full). I edited the post to make it a full attachment display then run the post replace again and all is good.
 
I want to remove all imageshack images because they are all broken but I couldn't find regular expression.

Code:
[IMG]http://img509.imageshack.us/img509/3456/20232179.png[/IMG]

Can anybody help me ?

I figured it out ;

Code:
#\[(img)](http://)\img[^\.]+.(imageshack\.us)/img[^\.]+/([^/s\.]+)/([^\]]+)\[/img]#siu
 
Last edited:
@Jake Bunce's batch process edits don't seem to do anything for me and I've more then triple checked to make sure I'm not making a mistake, hitting proceed only refreshes the page.

Am I doing something wrong?

I have about 8 million posts. With out this edit, hitting proceed just produces a 503 error instantly. Anything I should raise or tweak?
 
This may potentially be the explanation (you can check to find out).

1st I have to say it (don't shoot the messenger) check to make sure that the save changes box is checked.

Assuming that is not the problem you very well may be saving the changes but fooling yourself into thinking you are not, when you run the thing with "save changes" checked it will appear to show the same results basically though the 'save changes' box should now be unchecked and if you run the expression again a new set of results should come up.

At that point if they do everything worked as expected and you will automatically be looking at the next batch.
 
This may potentially be the explanation (you can check to find out).

1st I have to say it (don't shoot the messenger) check to make sure that the save changes box is checked.

Assuming that is not the problem you very well may be saving the changes but fooling yourself into thinking you are not, when you run the thing with "save changes" checked it will appear to show the same results basically though the 'save changes' box should now be unchecked and if you run the expression again a new set of results should come up.

At that point if they do everything worked as expected and you will automatically be looking at the next batch.

chrome_2017-02-13_18-36-42.png


This is what I'm trying to do.

When I check save changes and hit proceed, nothing actually happens, the page immediately refreshes and that is it.
 
Top Bottom