I'd like to combine some static variables but can't get any of the following to work:
class tableNaming{
private static $MYTABLES_PRE = 'me_';
private static $users_table = $MYTABLES_PRE . 'users';
}
class tableNaming2{
private static $MYTABLES_PRE = 'me_';
private static $users_table = self::$MYTABLES_PRE . 'users';
}
class tableNaming3{
private static $MYTABLES_PRE = 'me_';
private static $users_table = tableNaming3::$MYTABLES_PRE . 'users';
}
class tableNaming4{
private static $MYTABLES_PRE = 'me_';
private static $users_table = $this->$MYTABLES_PRE . 'users';
}
class tableNaming5{
private static $MYTABLES_PRE = 'me_';
private static $users_table = self::getMyTables() . 'users'; // try line below as well
// private static $users_table = $this->getMyTables() . 'users'; // tried both
public static function getMyTables(){ return self::$MYTABLES_PRE; }
}
any ideas? I really thought #5 would work (it's the one I like the least though)
thanks for the help, this is really ruining my night.