Advertisement
Guest User

Untitled

a guest
Jun 24th, 2017
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.69 KB | None | 0 0
  1. <?php
  2. $file = $sito . "OnAir.txt?bbb=" . rand();
  3.  
  4. $song = file_get_contents($file,false,$context);
  5.  
  6. $song = htmlentities(substr($song, 0, strlen($song)-2));
  7.  
  8. $song = explode(" - ", $song);
  9.  
  10. echo "var myDiv = document.getElementById('cc_stream_info_song');";
  11.  
  12. echo "var artist = document.createTextNode(\"Artista: $song[0]\");";
  13.  
  14. echo "var title = document.createTextNode(\"Titolo: $song[1]\");";
  15.  
  16. echo "myDiv.removeChild(myDiv.firstChild);";
  17.  
  18. echo "var div2 = document.createElement('div');";
  19.  
  20. echo "var br = document.createElement('br');";
  21.  
  22. echo "div2.appendChild(artist);";
  23.  
  24. echo "div2.appendChild(br);";
  25.  
  26. echo "div2.appendChild(title);";
  27.  
  28. echo "myDiv.appendChild(div2);";
  29.  
  30. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement