Line breaks in descriptions

Discussion about the website and interfaces.
Report general bugs here.
Forum rules
DO NOT POST SERIES REQUESTS HERE.
Use the appropriate forum.
Requests posted here are subject to immediate deletion.
rrg
Posts: 6
Joined: Sun Sep 16, 2018 11:23 am
Location: USA

Line breaks in descriptions

Postby rrg » Sun Sep 16, 2018 11:38 am

I've been entering some series data and I want to put line breaks in the descriptions. I observed that bare newlines don't work for this because they're ignored and all the text runs together when the description is displayed on thetvdb.com.

I discovered that HTML line-breaks (<br>) are honored, and that appending <br> to each line does have the desired effect for display on thetvdb.com.

But when Plex pulls the descriptions and displays them, the <br>'s are shown, which is not what I want.

Is there a workaround for this, or do I have to write the descriptions without line breaks so that the appearance will be the same note here and in Plex?

Imzadi
Site Moderator
Posts: 2075
Joined: Tue Jun 24, 2008 2:14 pm
Location: Germany

Re: Line breaks in descriptions

Postby Imzadi » Sun Sep 16, 2018 11:41 am

No, html shouldn't be used. If it works for some reason, it will be fixed sooner rather than later.

Text should be entered with breaks, what happens with it is up to plex.

rrg
Posts: 6
Joined: Sun Sep 16, 2018 11:23 am
Location: USA

Re: Line breaks in descriptions

Postby rrg » Sun Sep 16, 2018 12:09 pm

Okay, but on tvdb.com itself, the line breaks seem to be ignored when the description is displayed, i.e. the text on the following line follows immediately without any visible break. Is that the intention?

Mistywing
Posts: 996
Joined: Mon Jul 18, 2016 1:59 am

Re: Line breaks in descriptions

Postby Mistywing » Sun Sep 16, 2018 8:18 pm

The appearance here ignores line breaks but they are returned properly in applications such as Plex. They are also saved properly in the text fields, so when the appearance issue is fixed (if it is) it should display properly even on the site.
Keep writing the descriptions with the line breaks (no html) you want to show up in other apps and ignore the result on TVDB for now.

rrg
Posts: 6
Joined: Sun Sep 16, 2018 11:23 am
Location: USA

Re: Line breaks in descriptions

Postby rrg » Sun Sep 16, 2018 9:24 pm

Excellent, thank you. I removed <br> from all the entries. Plex caches tvdb.com for 24 hours so I can't immediately confirm the appearance there, but I'll check that tomorrow.

rrg
Posts: 6
Joined: Sun Sep 16, 2018 11:23 am
Location: USA

Re: Line breaks in descriptions

Postby rrg » Sun Sep 16, 2018 9:50 pm

Some of the updated descriptions are now visible in Plex and the behavior is suboptimal: instead of wrapping the lines at the line breaks, Plex inserts blank lines. Very annoying. At least that's how Plex's Web client behaves.

I realize this is caused on the Plex side, but is there no other workaround for this issue? Blank lines are (perhaps) a little better than run-on text, but still ugly.

Mistywing
Posts: 996
Joined: Mon Jul 18, 2016 1:59 am

Re: Line breaks in descriptions

Postby Mistywing » Sun Sep 16, 2018 10:19 pm

Blank lines seems to be Plex's fault (extra <p>), it also does this on my installation. Sonarr that I also use seems to just completely ignore their existence altogether so it could be worse :cry:

rrg
Posts: 6
Joined: Sun Sep 16, 2018 11:23 am
Location: USA

Re: Line breaks in descriptions

Postby rrg » Sun Sep 16, 2018 10:57 pm

I checked what the API is actually returning, and each line break is a CRLF, i.e. "\r\n". That shouldn't be an issue, but perhaps it is.

I guess there's nothing to be done about it except to complain to Plex--which I may do, though it's unlikely they'll be responsive.

rrg
Posts: 6
Joined: Sun Sep 16, 2018 11:23 am
Location: USA

Re: Line breaks in descriptions

Postby rrg » Sun Sep 16, 2018 11:50 pm

Aha! It seems that every Plex client handles this differently. Their Web client behaves as I described, their Apple TV app displays the text exactly as it was entered at thetvdb.com (which I consider the right way), and their iPhone and iPad apps ignore line breaks and run all the lines together (just as thetvdb.com itself when displaying the descriptions).

I'd be curious to hear about the behavior on other Plex clients (I don't have any others myself).