wok-6.x rev 5818

tazbb: add stable support
author Pascal Bellard <pascal.bellard@slitaz.org>
date Thu Jul 15 10:25:06 2010 +0200 (2010-07-15)
parents 0c14f687e2d1
children ea926ba90106
files tazbb/stuff/web/conf.php tazbb/stuff/web/index.php
line diff
     1.1 --- a/tazbb/stuff/web/conf.php	Wed Jul 14 11:55:51 2010 +0200
     1.2 +++ b/tazbb/stuff/web/conf.php	Thu Jul 15 10:25:06 2010 +0200
     1.3 @@ -2,11 +2,11 @@
     1.4  
     1.5  // Tazbb web interface configuration
     1.6  
     1.7 -$chroot     = "/home/slitaz/cooking/chroot";
     1.8 +$chroot     = "/home/slitaz/$version/chroot";
     1.9  $lockfile   = "$chroot/var/lock/tazbb.lock";
    1.10  $db_dir     = "$chroot/var/lib/tazbb";
    1.11  $log_dir    = "$chroot/var/log/tazbb";
    1.12  $packages   = "$chroot/home/slitaz/packages";
    1.13 -$hgurl      = "http://hg.slitaz.org/wok";
    1.14 +$hgurl      = "http://hg.slitaz.org/$wok";
    1.15  
    1.16  ?>
     2.1 --- a/tazbb/stuff/web/index.php	Wed Jul 14 11:55:51 2010 +0200
     2.2 +++ b/tazbb/stuff/web/index.php	Thu Jul 15 10:25:06 2010 +0200
     2.3 @@ -1,4 +1,10 @@
     2.4  <?php
     2.5 +$version='cooking';
     2.6 +$wok='wok';
     2.7 +if (isset($_GET['stable'])) {
     2.8 +	$version='stable';
     2.9 +	$wok='wok-stable';
    2.10 +}
    2.11  include("conf.php");
    2.12  ?>
    2.13  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    2.14 @@ -16,11 +22,18 @@
    2.15  <body bgcolor="#ffffff">
    2.16  <!-- Header -->
    2.17  <div id="header">
    2.18 -    <a name="top"></a>
    2.19 +    <a name="top"></a></a><?php if ($version == 'stable') { ?>
    2.20 +<!-- Access -->                                                                 
    2.21 +<div id="access">
    2.22 +    <a href="/<?php if ($version != 'stable')
    2.23 +echo "?stable"; ?>" title="Slitaz <?php
    2.24 +echo $version ?> packages"><?php echo $version ?></a>                          
    2.25 +</div>                                                                         
    2.26 +    <?php } ?>
    2.27      <a href="http://bb.slitaz.org/"><img id="logo"
    2.28      src="pics/website/logo.png" title="bb.slitaz.org" alt="bb.slitaz.org"
    2.29      style="border: 0px solid ; width: 200px; height: 74px;" /></a>
    2.30 -    <p id="titre">#!/bb/packages</p>
    2.31 +    <p id="titre">#!/bb/packages<?php if ($version == 'stable') echo '/stable'; ?></p>
    2.32  </div>
    2.33  
    2.34  <!-- Navigation menu -->