Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Icon

About: Deezer:Download
edited May 16 in Script Discussions Chrome

¿Is it possible to put a icon in each track?, I tried to use this css but I can not see the icon.
if (showMp3_320) if (getFilesize(track, 'MP3_320') > 0) linksEl.appendChild(generateDlLink(track, '<*img src="cdn6.aptoide.com/imgs/f/3/3/f332882c38a4855e6b51db18aede9c0e_icon.png?w=120">', fmtMp3_320, getFilesize(track, 'MP3_320')));

Comments

  • edited May 17 Chrome

    What are you expect to see?
    Of course it will display text instead of parsed HTML.
    XSS, my friend. Only textContent. No exclusions.

    So if you wanna see your image, you have to replace in function generateDlLink

    el.textContent = `⬇ ${fmt_name}`;
    with
    el.innerHTML = '<img src="//cdn6.aptoide.com/imgs/f/3/3/f332882c38a4855e6b51db18aede9c0e_icon.png?w=120">'
    or even better with
    el.appendChild(new Image).src = '//cdn6.aptoide.com/imgs/f/3/3/f332882c38a4855e6b51db18aede9c0e_icon.png?w=20';
    
  • I can not understand.

  • Me too. What are you want to get?

  • This code do I have to change? by which?

    if (showMp3_320) if (getFilesize(track, 'MP3_320') > 0) linksEl.appendChild(generateDlLink(track, 'mp3 320', fmtMp3_320, getFilesize(track, 'MP3_320')));

  • You have to replace

    el.textContent = `⬇ ${fmt_name}`;
    

    with

    el.appendChild(new Image).src = '//cdn6.aptoide.com/imgs/f/3/3/f332882c38a4855e6b51db18aede9c0e_icon.png?w=20';
    
  • edited May 17 Chrome

    I will be eternally grateful AHOHNMYC ! ;) , now if the icon appears on each track.

Sign In or Register to comment.