| Summary: | embed lyrics | ||
|---|---|---|---|
| Product: | [Applications] kid3 | Reporter: | nekto <sergantiche> |
| Component: | general | Assignee: | Urs Fleisch <ufleisch> |
| Status: | RESOLVED FIXED | ||
| Severity: | major | ||
| Priority: | NOR | ||
| Version First Reported In: | 3.9.x | ||
| Target Milestone: | --- | ||
| Platform: | Debian stable | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
| Attachments: | attachment-2533283-0.html | ||
|
Description
nekto
2024-04-30 23:20:58 UTC
The HTML class has changed. Try the following change:
--- a/src/qml/script/EmbedLyrics.qml
+++ b/src/qml/script/EmbedLyrics.qml
@@ -71,9 +71,9 @@ Kid3Script {
"/" + encodeURIComponent(title)
},
parseResponse: function(resp) {
- var begin = resp.indexOf('<div class="cnt-letra">')
+ var begin = resp.indexOf('<div class="lyric-original">')
if (begin !== -1) {
- begin += 23
+ begin += 29
var end = resp.indexOf("</div>", begin)
var txt = resp.substring(begin, end).trim()
if (txt.substring(0, 3) === "<p>") {
Created attachment 169102 [details] attachment-2533283-0.html thank you, but I can’t do it, because I really don’t understand how it should be correctly :( please send me the ready-made EmbedLyrics.qml script on sergantiche@gmail.com :) чт, 2 мая 2024 г. в 08:25, Urs Fleisch <bugzilla_noreply@kde.org>: > https://bugs.kde.org/show_bug.cgi?id=486370 > > Urs Fleisch <ufleisch@users.sourceforge.net> changed: > > What |Removed |Added > > ---------------------------------------------------------------------------- > Ever confirmed|0 |1 > Status|REPORTED |CONFIRMED > > --- Comment #1 from Urs Fleisch <ufleisch@users.sourceforge.net> --- > The HTML class has changed. Try the following change: > > --- a/src/qml/script/EmbedLyrics.qml > +++ b/src/qml/script/EmbedLyrics.qml > @@ -71,9 +71,9 @@ Kid3Script { > "/" + encodeURIComponent(title) > }, > parseResponse: function(resp) { > - var begin = resp.indexOf('<div class="cnt-letra">') > + var begin = resp.indexOf('<div class="lyric-original">') > if (begin !== -1) { > - begin += 23 > + begin += 29 > var end = resp.indexOf("</div>", begin) > var txt = resp.substring(begin, end).trim() > if (txt.substring(0, 3) === "<p>") { > > -- > You are receiving this mail because: > You reported the bug. An unpleasant detail was revealed. if the song title contains the characters: ' " / ( [, the text is not found, but if these characters are removed from the title, then the song text is found 🤔 Fixed in version 3.9.7. |