commit b798cbda457c687d43fb4424d897c9707e8cc039
parent aee31d8c2185bb0e1a342e93e04f929a2f2f4943
Author: Marcello Stanisci <marcello.stanisci@inria.fr>
Date: Tue, 16 Feb 2016 21:24:37 +0100
changing 'let' to 'var' in frontends JS
Diffstat:
4 files changed, 7 insertions(+), 15 deletions(-)
diff --git a/src/backend/merchant.conf b/src/backend/merchant.conf
@@ -11,7 +11,7 @@ HOSTNAME = localhost
KEYFILE = merchant.priv
# What currency does this backend accept?
-CURRENCY = EUR
+CURRENCY = PUDOS
# FIXME: to be revised
TRUSTED_MINTS = taler
diff --git a/src/frontend/index.php b/src/frontend/index.php
@@ -14,14 +14,14 @@ echo "\tvar shop_currency = '$MERCHANT_CURRENCY';\n";
function addOption(value, label) {
var s = document.getElementById("taler-donation");
- let e = document.createElement("option");
+ var e = document.createElement("option");
e.textContent = label ? label : ("".concat(value, " ", shop_currency));
e.value = value;
s.appendChild(e);
}
function init() {
- let e = document.getElementById("currency-input");
+ var e = document.getElementById("currency-input");
e.value = shop_currency;
addOption("0.1");
addOption("1.0");
diff --git a/src/frontend_blog/essay_contract.php b/src/frontend_blog/essay_contract.php
@@ -15,19 +15,11 @@
TALER; see the file COPYING. If not, If not, see <http://www.gnu.org/licenses/>
*/
-/**
- * This file should:
- *
- * 1. check if some article is going to be bought
- * 2. check if the wallet is installed TODO
- * 3. get the contract (having the teaser as product detail) to the wallet
- *
- */
include("../frontend_lib/merchants.php");
include("../frontend_lib/util.php");
include("../frontend_lib/config.php");
include("./blog_lib.php");
-session_start();
+
$article = get($_GET['article']);
if (null == $article){
echo "Please land here just to buy articles";
@@ -81,7 +73,7 @@ else
{
$got_json = json_decode($resp->body->toString(), true);
$hc = $got_json["H_contract"];
-
+ session_start();
$payments = &pull($_SESSION, "payments", array());
$payments[$hc] = array(
'article' => $article,
diff --git a/src/frontend_lib/config.php b/src/frontend_lib/config.php
@@ -1,7 +1,7 @@
<?php
-//$explicit_currency = false;
-$explicit_currency = "EUR";
+$explicit_currency = false;
+//$explicit_currency = "PUDOS";
$host = $_SERVER["HTTP_HOST"];
switch ($host) {