forked from La_Bureautique/zeg1jeux
lien TiddlyWiki
parent
218abd321d
commit
57360f9c85
16
home.php
16
home.php
|
@ -2,21 +2,29 @@
|
|||
|
||||
require_once('config.php');
|
||||
require_once('lib/Gchange.class.php');
|
||||
require_once('lib/Keygen.class.php');
|
||||
|
||||
$bodyIds = 'home';
|
||||
include_once('header.php');
|
||||
|
||||
$gchange = new Gchange();
|
||||
|
||||
$keygen = new Keygen();
|
||||
|
||||
$ipfsHost = 'http://astroport.localhost:8080';
|
||||
|
||||
try {
|
||||
|
||||
$player = $gchange->getUser($_SESSION['player_pubkey']);
|
||||
|
||||
$twLink = $ipfsHost . '/ipns/' . $keygen->getIPNSPub($_SESSION['salt'], $_SESSION['pepper']);
|
||||
|
||||
} catch (Exception $errMsg) {
|
||||
|
||||
ErrorsHandler::kaput($errMsg);
|
||||
}
|
||||
|
||||
|
||||
echo '
|
||||
<header>
|
||||
Bienvenue '. $player->getUserName() . ' !
|
||||
|
@ -56,6 +64,14 @@ echo '
|
|||
</span>
|
||||
</a>
|
||||
</li>
|
||||
|
||||
<li id="dashboard-tiddlywiki">
|
||||
<a href="'. $twLink .'">
|
||||
<span>
|
||||
'. ('Mon TiddlyWiki') .'
|
||||
</span>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
|
|
@ -4,15 +4,15 @@ class Fred {
|
|||
|
||||
private $gatewayProtocol = 'http';
|
||||
|
||||
private $gatewayDomain = 'libra.copylaradio.com';
|
||||
// private $gatewayDomain = 'libra.copylaradio.com';
|
||||
// private $gatewayDomain = 'aries.copylaradio.com';
|
||||
// private $gatewayDomain = 'astroport.localhost';
|
||||
private $gatewayDomain = 'astroport.localhost';
|
||||
|
||||
private $gatewayPort = '1234';
|
||||
|
||||
private $gatewayDelay = 3;
|
||||
|
||||
private $gatewayMaxRounds = 1;
|
||||
private $gatewayMaxRounds = 20;
|
||||
|
||||
public function __construct () {
|
||||
|
||||
|
@ -40,6 +40,7 @@ class Fred {
|
|||
|
||||
$url = $matches[1];
|
||||
|
||||
die($url);
|
||||
$opts2 = array(
|
||||
'http'=>array(
|
||||
'method'=>"GET",
|
||||
|
@ -48,6 +49,8 @@ class Fred {
|
|||
)
|
||||
);
|
||||
|
||||
echo 'fred 2';
|
||||
|
||||
$context2 = stream_context_create($opts2);
|
||||
|
||||
$page2 = false;
|
||||
|
|
|
@ -24,7 +24,7 @@ class Keygen {
|
|||
$cmd .= ' -t duniter';
|
||||
$cmd .= ' "'. $salt .'"';
|
||||
$cmd .= ' -p "'. $pepper .'"';
|
||||
|
||||
|
||||
$output=null;
|
||||
$result_code=null;
|
||||
exec($cmd, $output, $result_code);
|
||||
|
|
|
@ -11,13 +11,12 @@ $boris = '25zB1gSC7Qhwnx463cuDLDCKLRVieLAgFiPbYq6jVHG9';
|
|||
$playerG1Id = null;
|
||||
|
||||
if (isset($_POST['salt'], $_POST['pepper'])) {
|
||||
|
||||
$fred = new Fred();
|
||||
|
||||
$keygen = new Keygen();
|
||||
|
||||
try {
|
||||
|
||||
$playerG1Id = $fred->donneMoiSaPutaindeG1Pub($_POST['salt'], $_POST['pepper']);
|
||||
$playerG1Id = $keygen->getG1Pub($_POST['salt'], $_POST['pepper']);
|
||||
$keygen->generatePubsec($_POST['salt'], $_POST['pepper']);
|
||||
|
||||
} catch (Exception $errMsg) {
|
||||
|
|
|
@ -13,6 +13,7 @@ body#home nav ul {
|
|||
padding: 0;
|
||||
display: flex;
|
||||
justify-content: space-evenly;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
#dashboard-map {
|
||||
|
@ -22,7 +23,8 @@ body#home nav ul {
|
|||
|
||||
#dashboard-map a span,
|
||||
#dashboard-messenger a span,
|
||||
#dashboard-farfetched a span {
|
||||
#dashboard-farfetched a span,
|
||||
#dashboard-minelife a span {
|
||||
|
||||
display: none;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue