themaPoster
http://poster.themasoftware.com/forum/

Forum replacements problems.
http://poster.themasoftware.com/forum/viewtopic.php?f=4&t=634
Page 68 of 74

Author:  Freddy [ January 29th, 2022, 7:51 am ]
Post subject:  Re: Forum replacements problems.

You example seems incomplete, the closing "hide" tag is missing. If you only remove the opening "hide" the BBCode will be invalid and might cause issues.

Author:  Crackpot [ January 29th, 2022, 12:43 pm ]
Post subject:  Re: Forum replacements problems.

modified the previous post. there could be other text content.

i can use multiple text replace. but will it be possible to remove everything from the text file only keep the text pattern `[imdb=tt13309978]` with using only single regex replacement?

Author:  Freddy [ January 29th, 2022, 7:48 pm ]
Post subject:  Re: Forum replacements problems.

Search for:
Code:
(?s)(\[imdb=tt.+?\]).+rapidgator\.net.+?\[/code\]


Replace with:
Code:
$1


Enable regex search.

Author:  Crackpot [ February 16th, 2022, 4:47 am ]
Post subject:  Re: Forum replacements problems.

will it be possible to make this replacement?

Input
Code:
[b]Download From RapidGator[/b]
[code]https://www.keeplinks.org/p35/620c744507504[/code]

[b]Download From UptoBox[/b]
[code]https://www.keeplinks.org/p35/620c7443d5469[/code]



Output
Code:
<a href="https://www.keeplinks.org/p35/620c744507504">Rapidgator</a>

<a href="https://www.keeplinks.org/p35/620c744507504">UptoBox</a>

Author:  Freddy [ February 16th, 2022, 7:50 am ]
Post subject:  Re: Forum replacements problems.

Search for:
Code:
\[b\]Download From (.+?)\[/b\]\s*\[code\](.+?)\[/code\]


Replace with:
Code:
<a href="$2">$1</a>


Enable regex search.

Author:  Crackpot [ February 16th, 2022, 9:18 am ]
Post subject:  Re: Forum replacements problems.

thank you

Author:  Crackpot [ February 16th, 2022, 10:50 pm ]
Post subject:  Re: Forum replacements problems.

input
Code:
first site post content
[SECOND_SITE_POST]
second site post content





remove all content from starting [SECOND_SITE_POST] to end
output 1
Code:
first site post content



remove all content before starting to till [SECOND_SITE_POST]
output 2
Code:
second site post content

Author:  Freddy [ February 17th, 2022, 7:18 am ]
Post subject:  Re: Forum replacements problems.

Search for:
Code:
(?si)(.+?)\[SECOND_SITE_POST\](.+)


Replace with:
Code:
$1


Enable regex search.


Search for:
Code:
(?si)(.+?)\[SECOND_SITE_POST\](.+)


Replace with:
Code:
$2


Enable regex search.

Author:  Crackpot [ February 18th, 2022, 1:44 am ]
Post subject:  Re: Forum replacements problems.

input
Code:
<td><p style="text-align: center">[RG][/RG]


[MULTI][/MULTI]


</td>


output
Code:
<td><p style="text-align: center">[RG][/RG][MULTI][/MULTI]</td>

i could use \n\n but there is multiple whitespace

Author:  Freddy [ February 18th, 2022, 10:55 am ]
Post subject:  Re: Forum replacements problems.

Search for:
Code:
(\[/RG\])\s*(\[MULTI\]\[/MULTI\])\s*


Replace with:
Code:
$1$2


Enable regex search.

Author:  Crackpot [ February 26th, 2022, 1:23 pm ]
Post subject:  Re: Forum replacements problems.

input
Code:
[RG]https://www.keeplinks.org/p35/661122237f4bb[/RG]

[MULTI]https://www.keeplinks.org/p35/62161227de9d98[/MULTI]

<br />Pass:xasd


output
Code:
[RG]https://www.keeplinks.org/p35/661122237f4bb[/RG][MULTI]https://www.keeplinks.org/p35/62161227de9d98[/MULTI]<br />Pass:xasd


i could use \n\n but what if there is multiple blank line? possible to use regex?

Author:  Freddy [ February 26th, 2022, 7:10 pm ]
Post subject:  Re: Forum replacements problems.

If you want to remove all new lines then just replace "\n" with nothing (all new lines will be removed, the result will be as you want).

Search for:
Code:
\n


Replace with:
Code:
(leave empty)


Simple replacement (not regex).

Author:  Crackpot [ March 8th, 2022, 3:29 am ]
Post subject:  Re: Forum replacements problems.

sorry i asked you something similar but i could not able to fig it out how can i do that


input
Code:
first site post content
[SECOND_SITE_POST]
second site post content
[THRID_SITE_POST]
third site post content


output 1
Code:
first site post content


output 2
Code:
second site post content


output 3
Code:
third site post content

Author:  Freddy [ March 8th, 2022, 8:11 am ]
Post subject:  Re: Forum replacements problems.

For first:

Search for:
Code:
(?s)(.+?)\[SECOND_SITE_POST\].*


Replace with:
Code:
$1


Enable regex search.

For second:

Search for:
Code:
(?s).*\[SECOND_SITE_POST\](.+?)\[THRID_SITE_POST\].*


Replace with:
Code:
$1


Enable regex search.

For third:

Search for:
Code:
(?s).*\[THRID_SITE_POST\](.+)


Replace with:
Code:
$1


Enable regex search.

Author:  zaika [ March 14th, 2022, 8:07 pm ]
Post subject:  Re: Forum replacements problems.

if possible this freddy

Before
Code:
[code]https://filecrypt.cc/Container/F18A9A283E.html[/code]
[code]https://www.keeplinks.org/p75/622f5bdddaa5e[/code]


After
Code:
[member][url]https://filecrypt.cc/Container/F18A9A283E.html[/url]
[url]https://www.keeplinks.org/p75/622f5bdddaa5e[/url][/member]


thx for help

Page 68 of 74 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/