Guys, anyone give me this help, please! I have a form where people go through youtube links containing songs and will generate for me a list of these songs in the music.html file.
How can I reverse the listing of these songs? The .html file inserts each YouTube link below the other, my need is for it to list one over the other, so it makes it easier not to have to scroll down the list in order to reach the last links sent.
<form action="" method="POST">
<input name="link" type="text" placeholder="Link do Youtube" />
<input type="submit" name="submit" value="Enviar">
</form>
<?php
if (!empty($_POST["link"])) {
$mus = $_POST['link'];
$arquivo = "musicas.html";
date_default_timezone_set('America/Bahia');
$data = date('d/m/Y H:i:s', time());
$fp = fopen($arquivo, "a+");
fwrite($fp,"Data: $data | Link: <a href=$mus>Click Aqui</a><br><br>");
fclose($fp);
echo "Música enviada com sucesso !";
}
?>
Extra Doubt :
How do I blow this Youtube link to modify the video link and take the link to a site to download the .mp3 video?
Example - > www.youtube.com/v=AbCdEFgh _
Explode with the modifications - > www.yout.com/v=AbCdEFgh _
Yout.com allows you to download .mp3 and .mp4 videos, so when I access my music.html file, I will have this result:
Date : 12/04/2016 17:51:21 | Link : Click Here | Download : Click Here
Thank you