Page 1 of 2

Moderator text on website

Posted: 12 Aug 2014 08:32
by friso
Bernd

Is it possible, or is there a way to display the moderator text on the website with the linebreaks i created in the moderator text box itself?
Now all the text is displayed without any linebreaks?

Thanx

Friso

Re: Moderator text on website

Posted: 12 Aug 2014 19:16
by radio42
What control-command do you use to transfer the moderator text to your web site?

However, note, that your local moderator text might contain Carriage Return/Line Break characters (\r\n) which your web-site does not translate automatically.
I.e. HTML does not 'understand' those text formatting characters, as HTML expects the "<br />" sequence instead.
There are two possibilities:
a) in your web-site you enclose the moderator text into a "<code>"/"</code>" block
b) you replace any Carriage Return/Line Break characters (\r\n) by respective "<br />" characters (either within your web-site or with the "*[REPLACE:{value}:{source}:{destin}]" macro function)

I suggest to discuss these options with your web site designers...

Re: Moderator text on website

Posted: 12 Aug 2014 20:44
by friso
Bernd

It works, when i add 2 times <br><br>. After that on the website there is one blanc line so that looks much better.
Is it possible to add a button in tag editor that automatically adds the <br><br>?
Or something wich does the same.

Thanx
Friso

Re: Moderator text on website

Posted: 12 Aug 2014 21:19
by radio42
Yes, as said, you can use the "*[REPLACE:{value}:{source}:{destin}]" macro function to do so when uploading your moderator text to the web site.
E.g.:
*[REPLACE:{${moderatortext}}:{\r\n}:{<br/><br/>}]

Re: Moderator text on website

Posted: 13 Aug 2014 10:20
by friso
Bernd

Do i have to put these macro in Proppfrexx in the http_get, or in my php script?

Re: Moderator text on website

Posted: 13 Aug 2014 10:31
by friso
Bernd

Ok, but how can i use this macro you give me
Now i got this: http://frisotrip.nl/proppfrexx/insert_d ... }&modtext="*[REPLACE:{${moderatortext}}:{\r\n}:{<br/><br/>}]"

But that gives me the whole rule as text.

Re: Moderator text on website

Posted: 13 Aug 2014 12:37
by radio42
How did your command look like before?

Re: Moderator text on website

Posted: 13 Aug 2014 13:30
by friso
Bernd

It looked like this:
Now i got this: http://frisotrip.nl/proppfrexx/insert_d ... p?artist=${artist}&title=${title}&albumart=${albumart}&modtext=${moderatortext}

Re: Moderator text on website

Posted: 13 Aug 2014 15:04
by friso
Bernd

Thanx i solved it in php:)

Re: Moderator text on website

Posted: 13 Aug 2014 20:02
by radio42
I am not sure, if line breaks can really be translated within macros.
So at best you leave the original code and translate that on the web (PHP) side, e.g. using the "str_replace()" function.