It's an asymmetric world

Coredumps from Jesus Castagnetto's brain

  • Increase font size
  • Default font size
  • Decrease font size
Error
  • Error loading feed data.


CachedTemplate: A generalized template caching class - Class CachedTemplate (private methods)

E-mail Print PDF

Private Methods:

_gen_var_val
Prototype:
_gen_var_val (array $vars)
Description:
Converts an associative array of $vars[name] = value into a url query string of the form: name1=val1&name2=val2&...

 

_gen_filename
Prototype:
string _gen_filename (void)
Description:
Generates a unique filename based on the name of the file being cached. First it replaces all slashes (/) by underlines (_), and then if the $USEVARS variable is set to "in_name", appends the rawurlencode'd contents of $VARSVAL to the filename.

 

_key_in_array
Prototype:
boolean _key_in_array (string $key, array $arr)
Description:
Returns true if the key is in the array, false otherwise.
_is_valid_time_unit
Prototype:
boolean _is_valid_time_unit (string $timeunit)
Description:
Returns true if a the parameter passed is a valid time unit, false otherwise.
_mktimestamp
Prototype:
int _mktimestamp (void)
Description:
Returns a timestamp in seconds. Wrapper for time().
_diff_time
Prototype:
int _diff_time (int $end, int $start[, string $timeunit])
Description:
Returns the difference between the $end and $start timestamps, in the units indicated by $timeunit. If the third parameter is omitted, it defaults to "day".
Example:
	// return the number of whole days between the 2 timestamps
echo $obj->_diff_time($end, $start);

// return the number of whole minutes between the 2 timestamps
echo $obj->_diff_time($end, $start, "minute");


 

Our son is here!

Our son Daniel Ken was born on March 09, 2009 at 14:39 PET (UTC - 5). We are happier than we've ever been in our lives.

Now the real work begins, helping a new life develop into this world.

-- Mom and Dad

My son's Blog

My Random Photo

From Airin's Photo Gallery

Green Hosting at Dreamhost.com

Visitors map

Anti-Spam Bots!