11

Simple string replace. If javascript, string split()[0]

Simple string replace. If javascript, string split()[0]

8 comments

[–] pembo210 1 points (+1|-0) Edited

It's something in the way that the BeautifulSoup title plugin works. It put's it there automatically. I'll see if I can figure something out. It annoys me too.

edit: title.rsplit('-', 1) ...

[–] xyzzy 0 points (+0|-0)

It's not only Youtube, many if not most sites do this. If you start with YT, where do you stop?

When users stop requesting it. It's really easy to create a .config or xml file with a new entry that the site can read without making changes to the code. If a request is popular enough, add it to the file as a new line and call it a day.

[–] CDanger 1 points (+1|-0) Edited

Exactly, no reason to make "better" the enemy of "perfect".

Aye, getting something 95% of the way there is easy and usually cheap. That last 5% or so percent is what kills ya.