[Cs-webapplibs-commits] SF.net SVN: cs-webapplibs:[162] trunk/0.3/cs_tabs.class.php
Status: Beta
Brought to you by:
crazedsanity
From: <cra...@us...> - 2010-05-27 14:49:18
|
Revision: 162 http://cs-webapplibs.svn.sourceforge.net/cs-webapplibs/?rev=162&view=rev Author: crazedsanity Date: 2010-05-27 14:49:12 +0000 (Thu, 27 May 2010) Log Message: ----------- Ability to retrieve internal properties from cs_tabs{}. /cs_tabs.class.php: * __get() [NEW]: -- ability to retrieve any (existing) internal property (easily allows for page titles to be dynamically set to name of selected tab). Modified Paths: -------------- trunk/0.3/cs_tabs.class.php Modified: trunk/0.3/cs_tabs.class.php =================================================================== --- trunk/0.3/cs_tabs.class.php 2010-05-27 14:31:40 UTC (rev 161) +++ trunk/0.3/cs_tabs.class.php 2010-05-27 14:49:12 UTC (rev 162) @@ -184,5 +184,19 @@ }//end rename_tab(); //--------------------------------------------------------------------------------------------- + + + //--------------------------------------------------------------------------------------------- + public function __get($name) { + if(isset($this->$name)) { + $retval = $this->$name; + } + else { + throw new exception(__METHOD__ .": no such var (". $name .")"); + } + return($retval); + }//end __get() + //--------------------------------------------------------------------------------------------- + } ?> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |