thiswebshoprules

git clone https://git.tarina.org/thiswebshoprules
Log | Files | Refs

almost.html (2369B)


      1 $def with (products,bag,sessionkey,productname,inbag,db,getprice,getrate,category,markdown,visitors, total, unique)
      2 
      3 $ siteconfig = db.select('propaganda', what='id, name, description, description2')[0]
      4 
      5 <HEAD>
      6     <meta charset="utf-8">
      7     <title>$siteconfig.name | $siteconfig.description</title>
      8     <link rel="stylesheet" href="/static/splash.css?v=101" type="text/css" rel="stylesheet"/>
      9     <meta name="viewport" content="width=device-width, initial-scale=1">
     10     <meta http-equiv="cache-control" content="no-cache">
     11 </HEAD>
     12 
     13 <BODY>
     14 
     15 $ totsats = 0
     16 $ toteuro = 0
     17 $ x = 0
     18 $if sessionkey != 'empty':
     19     <div id="bag">
     20     <div id="insidebag">
     21     in your cart:<br> 
     22     $for i in bag: 
     23         $code:
     24             price = getprice(i.product)
     25             quantity = i.quantity
     26             p_totsats=i.quantity*price[0]
     27             p_toteuro=i.quantity*price[1]
     28         $i.quantity x $productname(i.product)
     29         $#$p_totsats $p_toteuro&euro; <a href="/dropitem/$i.product">remove</a>
     30         <a href="/dropitem/$i.product">remove</a>
     31         <br>
     32         $code:
     33             totsats += p_totsats
     34             toteuro += p_toteuro
     35     $if totsats > 0:
     36         total: $totsats Satoshi or $toteuro &euro;
     37         <br>
     38         <h5><a href="/checkout">Checkout 🛒 --></a></h5>
     39         <code>~</code>
     40     </div>
     41     </div>
     42 <div id="visitors">
     43 last visits by countries: 
     44 $for i in visitors:
     45     <img src="/static/flags/${i}.png"> 
     46 <br>
     47 unique visits since Feb 20 2025: $unique <br>
     48 <br>
     49 </div>
     50 <div class="introtext">
     51 <br>
     52 <code>~*~</code>
     53 <br>
     54 <br>
     55 $#<h1>$siteconfig.name</h1>
     56 $#$:markdown.markdown(siteconfig.description)
     57 <h1>$siteconfig.name</h1>
     58 $:markdown.markdown(siteconfig.description)
     59 $:markdown.markdown(siteconfig.description2)
     60 <code>~</code>
     61 <br>
     62 <br>
     63 </div>
     64 
     65 $ goodies = db.query("SELECT * FROM propagandapics;")
     66 $for g in goodies:
     67     $if g.soundname[-5:] == '.jpeg' or g.soundname[-4:] == '.png':
     68         <div class="promopic">
     69         <img src="/static/img/web/$g.soundname">
     70         <br>
     71         <br>
     72         <code>~*~</code>
     73         <br>
     74         <br>
     75         <div class="promotext">
     76         $:markdown.markdown(g.name)
     77         $:markdown.markdown(g.description)
     78         $:markdown.markdown(g.description2)
     79         <br>
     80         <code>~</code>
     81         <br>
     82         </div>
     83         </div>
     84 <br>
     85 <br>
     86 <br>
     87 
     88 </div>
     89 <br>
     90 <br>
     91 <br>
     92 <br>
     93 <br>
     94 <br>
     95 <br>
     96 
     97 </BODY>