/[cvs]/nfo/php/libs/org.netfrag.glib/utils/extensions.php
ViewVC logotype

Diff of /nfo/php/libs/org.netfrag.glib/utils/extensions.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.2 by jonen, Sun Apr 6 01:37:31 2003 UTC revision 1.4 by joko, Wed Apr 9 07:55:47 2003 UTC
# Line 13  Line 13 
13   * $Id$   * $Id$
14   *   *
15   * $Log$   * $Log$
16     * Revision 1.4  2003/04/09 07:55:47  joko
17     * + function untwingle_reference
18     *
19     * Revision 1.3  2003/04/08 22:35:16  joko
20     * + 'function yesno' from utils/links.php
21     *
22   * Revision 1.2  2003/04/06 01:37:31  jonen   * Revision 1.2  2003/04/06 01:37:31  jonen
23   * + added functions to generate and handle unique ID's   * + added functions to generate and handle unique ID's
24   *   *
# Line 658  Bitte versuchen Sie es später nocheinmal Line 664  Bitte versuchen Sie es später nocheinmal
664      return ( implode(unpack("H*",Base64_decode($ID)), '') );      return ( implode(unpack("H*",Base64_decode($ID)), '') );
665    }    }
666    
667      // from: utils/links.php
668      function yesno($bool) {
669        return $bool ? 'yes' : 'no';
670      }
671    
672      function untwingle_reference($item, $options = array()) {
673        
674        // default
675        if (!$options['seperator']) { $options['seperator'] = '_'; }
676        
677        if ( is_string($item) && (substr($item, 0, 2) == "o_") ) {
678          //print "YAI!<br/>";
679          $parts = split($options['seperator'], $item);
680          $result = array(
681            ident => $parts[1],
682            type => $parts[2],
683          );
684          return $result;
685        }
686      }
687    
688  }  }
689    

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.4

MailToCvsAdmin">MailToCvsAdmin
ViewVC Help
Powered by ViewVC 1.1.26 RSS 2.0 feed