Changeset 277 in t29-www for lib


Ignore:
Timestamp:
Jul 8, 2012, 2:13:09 AM (12 years ago)
Author:
sven
Message:

JavaScript-Preferences-System, mit dem die Einstellungen fuers Menue erhalten bleiben. Refactoring des menu.js-Codes. startup.js um Reihenfolge der Scripte festzulegen. Diverse Bugfixes im PHP und Inhalt.

Location:
lib
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • lib/cache.php

    r275 r277  
    7171        function is_valid() {
    7272                // no double calculation
    73                 if($this->is_valid) return $this->is_valid;
     73                if($this->is_valid !== null) return $this->is_valid;
    7474
    7575                if($this->debug) {
  • lib/loader.php

    r273 r277  
    4848extract($conf); // for saving long human reading times :D
    4949
    50 
    5150require "$lib/cache.php";
    5251$js_cache = new t29Cache();
     
    6059require "$lib/ressourceloader.php";
    6160$loader = new $class($conf);
    62 $js_cache->start_cache(array($loader, 'compression_filter'), true);
     61if(!$debug) $js_cache->start_cache(array($loader, 'compression_filter'), true);
    6362$loader->run();
  • lib/technikum29.php

    r275 r277  
    1313$webroot = realpath("$lib/../");  # file path to root of t29 web installation
    1414$file = substr($_SERVER['SCRIPT_FILENAME'], strlen($_SERVER['DOCUMENT_ROOT'])); # e.g.: "/de/page.php"
     15
     16// exactly define debugging behaviour
     17if(isset($_GET['debug'])) {
     18        $_GET['purge_cache'] = true;
     19        $_GET['rl_debug'] = true;
     20}
    1521
    1622$cache_dir = "$webroot/shared/cache";
  • lib/template.php

    r276 r277  
    104104  <?php
    105105        if(isset($this->conf['version'])) printf('<meta name="t29.version" content="%s">', $this->conf['version']);
     106        if(isset($_GET['debug']))
     107                foreach(explode(' ','debug rl_debug skip_cache purge_cache verbose_cache') as $x)
     108                        printf("\n  <meta name='t29.template.data-%s' content='%s'>", $x, isset($_GET[$x])?'true':'false');
    106109  ?>
    107110 
     
    251254    </footer>
    252255  </div> <!--! end of #container -->
    253 
     256</div><!-- end of div id="footer-background-container" helper -->
    254257
    255258  <!-- JavaScript at the bottom for fast page loading -->
     
    264267                printf('  <script src="%s"></script>'.PHP_EOL, $js);
    265268  ?>
    266 </div><!-- end of div id="footer-background-container" helper -->
    267269</body>
    268270</html>
Note: See TracChangeset for help on using the changeset viewer.
© 2008 - 2013 technikum29 • Sven Köppel • Some rights reserved
Powered by Trac
Expect where otherwise noted, content on this site is licensed under a Creative Commons 3.0 License