View Single Post
Old 09-10-2017, 05:48 AM   #1
Tanjamuse
Wizard
Tanjamuse , Klaatu Barada Niktu!Tanjamuse , Klaatu Barada Niktu!Tanjamuse , Klaatu Barada Niktu!Tanjamuse , Klaatu Barada Niktu!Tanjamuse , Klaatu Barada Niktu!Tanjamuse , Klaatu Barada Niktu!Tanjamuse , Klaatu Barada Niktu!Tanjamuse , Klaatu Barada Niktu!Tanjamuse , Klaatu Barada Niktu!Tanjamuse , Klaatu Barada Niktu!Tanjamuse , Klaatu Barada Niktu!
 
Posts: 1,327
Karma: 5306
Join Date: Jan 2014
Device: none
Template Help in S&R

Hello.

Chaley kindly helped me with the following template for S&R and I fiddled a bit with it, because I needed both http and https.

When I tried with the following I got an invalid group reference.

Code:
Template: {#story_url:'re($, '(http(s?)://www.fanfiction.net/s/[0-9]*?/)', strcat('<p class="description"><a href="\1>',  field('title'), '</a></p>'))'}

Search for: .*

Replace with: \1

Destination Field: #story_url

The original story link could be either:

https://www.fanfiction.net/s/7950093/1/

or

http://www.fanfiction.net/s/1962402/1/

It varies if there's is s in the address but always the same with id-number and then the /1/ in the end.

I hope someone can help me.

Thanks in advance.

Last edited by Tanjamuse; 09-10-2017 at 06:24 AM.
Tanjamuse is offline   Reply With Quote