[ENH] Cohérence style pour étapes 2 et 3 + changement du fonctionnement du tunnel de paiement (bouton au lieu de QR code)

This commit is contained in:
Boris 2021-08-27 19:47:18 +02:00
parent b991c34fdd
commit efeb57a165
2 changed files with 72 additions and 32 deletions

View File

@ -3,7 +3,7 @@
<head>
<title>$TITLE in Astroport</title>
<meta charset="UTF-8">
<meta http-equiv="Refresh" content="7;URL=https://tube.copylaradio.com/ipns/$IPNSLINK/${G1PUB}/">
<meta http-equiv="Refresh" content="7;URL=http://astroport/ipns/$IPNSLINK/${G1PUB}/">
<link rel='stylesheet' href='http://astroport/styles/astroport/style.css' type='text/css' />
<link rel='icon' type='image/png' href='http://astroport/styles/astroport/logo.png' />
</head>

View File

@ -290,63 +290,103 @@ rm /tmp/.ipfsid
IPNSLINK=$(ipfs key list -l | grep ${MEDIAKEY} | cut -d ' ' -f 1)
## FIRST REDIRECT PAGE ${MEDIAKEY}/index.html
# https://tube.copylaradio.com/ipns/$IPNSLINK
echo "<!DOCTYPE html>
#envsubst < ./www/boris/youtube_watch_step2.html > ~/.zen/ipfs/.${IPFSNODEID}/KEY/${MEDIAKEY}/index.html
cat >~/.zen/ipfs/.${IPFSNODEID}/KEY/${MEDIAKEY}/index.html <<EOF
<!DOCTYPE html>
<html>
<head>
<title>$TITLE in Astroport</title>
<meta charset=\"UTF-8\">
<meta http-equiv=\"Refresh\" content=\"10;URL=https://tube.copylaradio.com/ipns/$IPNSLINK/${G1PUB}/\">
<link rel='stylesheet' href='/crowdbunker.css' type='text/css' />
<link rel='icon' type='image/png' href='/astrocrowdbunker.png' />
<meta charset="UTF-8">
<meta http-equiv="Refresh" content="7;URL=http://astroport/ipns/$IPNSLINK/${G1PUB}/">
<link rel='stylesheet' href='http://astroport/styles/astroport/style.css' type='text/css' />
<link rel='icon' type='image/png' href='http://astroport/styles/astroport/logo.png' />
</head>
<body>
<header>
<h6>
<a href='https://astroport.com'><span>ASTROPORT</span> × <span> DEMO</span></a>
<a href='http://astroport/'><span>ASTROPORT</span> <q>${XZUID}</q></a>
</h6>
</header>
<main>
<article><h2>$TITLE</h2>
<a href=\"$LOCALTUBELINK\">LECTURE LOCALHOST</a>!<br><br>Lancement de la video dans 10 secondes ...<br>
<h1 class='video-title'>Ce service est disponible sur <a href='https://copylaradio.com'>astrXbian</a> BETA Live TEstNET</h1>
<article>
<h1>$TITLE</h1>
<p>Lancement de la video dans 7 secondes...</p>
<p class="pubkey-and-copy-button">
Ce fichier vous est servi par une station amie. Faites lui un don pour la remercier&nbsp;:
<input type="text" id="pubkey" readonly value="${G1PUB}" />
<button id="copy">Tip !</button>
</p>
<p id="successMsg">
La clef de la station amie est maintenant copiée dans le presse-papier. Vous pouvez la coller dans le client Ğ1 de votre choix (Cesium par exemple) afin de faire votre don 😉
</p>
<script>
function copy() {
var copyText = document.querySelector("input#pubkey");
copyText.select();
document.execCommand("copy");
var successMsg = document.querySelector("#successMsg");
successMsg.style.opacity = "1";
var copyButton = document.querySelector("button#copy");
copyButton.style.animation = "none";
}
document.querySelector("button#copy").addEventListener("click", copy);
</script>
</article>
</main>
<center><br>Démonstration Streaming du Datacenter P2P Libre et Légal.<br>
<br>Les dons au portefeuille du Media (${MEDIAKEY}) rapportent à son Auteur, et payent son hébergement.
<br>
<br><a target='tube' href=\"https://www.gchange.fr/#/app/user/${G1PUB}/\"><img width=222 src=\"https://tube.copylaradio.com/ipns/$IPNSLINK/QR.png\"></a></center>
</body>
</html>" > ~/.zen/ipfs/.${IPFSNODEID}/KEY/${MEDIAKEY}/index.html
</html>
EOF
## SECOND REDIRECT PAGE ${MEDIAKEY}/${G1PUB}/index.html
# https://tube.copylaradio.com/ipns/$IPNSLINK/${G1PUB}/
echo "<!DOCTYPE html>
#envsubst < ./www/boris/youtube_watch_step3.html > ~/.zen/ipfs/.${IPFSNODEID}/KEY/${MEDIAKEY}/${G1PUB}/index.html
cat > ~/.zen/ipfs/.${IPFSNODEID}/KEY/${MEDIAKEY}/${G1PUB}/index.html <<EOF
<!DOCTYPE html>
<html>
<head>
<title>$TITLE in Astroport</title>
<meta charset=\"UTF-8\">
<meta http-equiv=\"Refresh\" content=\"10;URL=http://127.0.0.1:8181/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME\">
<link rel='stylesheet' href='/crowdbunker.css' type='text/css' />
<link rel='icon' type='image/png' href='/astrocrowdbunker.png' />
<meta charset="UTF-8">
<link rel='stylesheet' href='http://astroport/styles/astroport/style.css' type='text/css' />
<link rel='icon' type='image/png' href='http://astroport/styles/astroport/logo.png' />
</head>
<body>
<header>
<h5>
<a href=\"http://127.0.0.1:8181/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME\"><span>Lien direct qui fonctionne depuis votre Station Astroport/KODI</span></a>!
</h5>
<h6>
<a href='http://astroport/'><span>ASTROPORT</span> <q>${XZUID}</q></a>
</h6>
</header>
<main>
<article><h2>$TITLE</h2>
<br>Accédez immédiatement à cette vidéo depuis votre station Astroport/KODI ...<br>
<h1 class='video-title'>Essayez <a href='https://copylaradio.com'>astrXbian</a> Le BETA Live TEstNET Astroport</h1>
</article>
<article>
<video autoplay="autoplay" controls>
<source src="http://astroport/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME">
<a href="http://astroport/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME">$TITLE</a>
</video>
<h1 class="video-title">
$TITLE
</h1>
</article>
</main>
<center><br>Service Video Club / Datacenter P2P Libre et Légal.<br>
<br>Les dons au portefeuille du Media (${MEDIAKEY}) rapportent à son Auteur, et payent son hébergement.
<br>
<br><a target='tube' href=\"https://www.gchange.fr/#/app/user/${G1PUB}/\"><img width=222 src=\"https://tube.copylaradio.com/ipns/$IPNSLINK/QR.png\"></a></center>
</body>
</html>" > ~/.zen/ipfs/.${IPFSNODEID}/KEY/${MEDIAKEY}/${G1PUB}/index.html
</html>
EOF
# echo "<meta http-equiv=\"Refresh\" content=\"0;URL=http://127.0.0.1:8181/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME\">" > ~/.zen/ipfs/.${IPFSNODEID}/KEY/${MEDIAKEY}/${G1PUB}/index.html
########################################################################
## MODIFY INTO "./zen/ipns_TAG_refresh.sh" (add crypto/contracts there)