Page 1 of 1

This is a javascript problem. Context: These codes are Spotify Iframe api javascript and spotify iframes. The javascript

Posted: Fri May 20, 2022 2:33 pm
by answerhappygod
This is a javascript problem.
Context: These codes are Spotify Iframe api javascript and
spotify iframes. The javascript functions allows the sound to play
when you hover over the iframes respective to the id.
HTML Iframe Codes:
Code 1:
<iframe class="clickme" id="sp_1" "width=300"
height="200" scrolling="no" frameborder="0" style="display: 100px"
allow="autoplay"></iframe>
Code 2:
<iframe class="clickme" id="sp_2" "width=300" height="200"
scrolling="no" frameborder="0" style="display: 100px"
allow="autoplay"></iframe>
Spotify Iframe API Javascript Codes:
Code 1:
<script>
$(document).ready(function () {
console.log("ready!");
$(".clickme").mouseenter(function () {
console.log('start ');
element.play();
});
$(".clickme").mouseleave(function () {
console.log('finish ');
element.pause();
});
}());
</script>
Images of iframes:
This Is A Javascript Problem Context These Codes Are Spotify Iframe Api Javascript And Spotify Iframes The Javascript 1
This Is A Javascript Problem Context These Codes Are Spotify Iframe Api Javascript And Spotify Iframes The Javascript 1 (100.85 KiB) Viewed 34 times
Problem:
I need you to modify the javascript code to where the
appropriate sound will play when you hover over the iframe, pause
when the mouse is off iframe, and start the track over
when it ends. Note: Modify the code to where it does this for a
infinite number of iframes; Do not set it to a specific number.
I.COM ARIANA Simple And Clean Hikaru Utada DEL REY ANGEL Don't Call Me Angel (Charlie's Angels) Ariana Grande, Miley Cyrus, Lana Del Rey K 1 Don't Call Me Angel (Charlie's Angels) (with Miley Cyrus... 3:10