Changes between Version 3 and Version 4 of XcacheApi


Ignore:
Timestamp:
2006-05-20T05:38:37+02:00 (9 years ago)
Author:
moo
Comment:

typo, new example

Legend:

Unmodified
Added
Removed
Modified
  • XcacheApi

    v3 v4  
    1919Examples: 
    2020 
    21 * Simple Counter 
     21 * Simple Counter 
    2222{{{ 
    2323This guest book has been visited <?php echo xcache_inc("count"); ?> times. 
    2424}}} 
    2525 
    26 * Cacher 
     26 * Advanced Counter 
     27{{{ 
     28<?php 
     29if (!xcache_isset("count")) { 
     30 xcache_set("count", load_count_from_mysql()); 
     31} 
     32?> 
     33This guest book has been visited <?php echo $count = xcache_inc("count"); ?> times. 
     34<?php 
     35// save every 100 hits 
     36if (($count % 10) == 100) { 
     37 save_count_to_mysql($count); 
     38} 
     39?> 
     40}}} 
     41 
     42 * Cacher 
    2743{{{ 
    2844<?php 
     
    6177an admin php script will be available in [wiki:GettingSource XCache Source Repo] later, that use admin functions. 
    6278 
    63 == De/Assembler Opcode Functions == 
     79== Dis/Assembler Opcode Functions == 
    6480{{{ 
    6581string xcache_asm(string filename)