[pLog-svn] r5490 - plog/trunk

Jon Daley plogworld at jon.limedaley.com
Tue Jun 5 17:37:33 EDT 2007


 	Ah, I actually understand why that won't work now - after playing 
with all that xmlrpc including things.  Whenever a class or function is 
defined, it automatically goes to the global scope, even if included from 
inside a function.  But, variables get the function scope.
 	So, any file that has a global variable in it can't be included 
with lt_include.  Seems like we would have run into more problems with it 
than we did.
 	There isn't any such thing as a macro in php, where the 
"if(!included) include(filename)" could be included as a macro instead of 
a function, is there?

On Tue, 5 Jun 2007, Oscar Renalias wrote:

> This won't work:
>
>> -    include_once( PLOG_CLASS_PATH."install/
>> dbschemas.properties.php" );
>> +    lt_include( PLOG_CLASS_PATH."install/dbschemas.properties.php" );
>>      // default configuration values for 1.1
>> -    include_once( PLOG_CLASS_PATH."install/
>> defaultconfig.properties.php" );
>> +    lt_include( PLOG_CLASS_PATH."install/
>> defaultconfig.properties.php" );
>>      // post schema changes after upgrade
>> -    include_once( PLOG_CLASS_PATH."install/
>> changes_10_11.properties.php" );
>> +    lt_include( PLOG_CLASS_PATH."install/
>> changes_10_11.properties.php" );
>
> Using lt_include to import a .php file which defined an array instead
> of a class did not work, so they had to be kept as include() or
> include_once().
>
> But if you had merged wizard.php from lifetype-1.2 to the one in
> trunk/ you wouldn't have needed this. I suppose you forgot about
> wizard.php... But I think we can take the easy route and copy the
> wizard over from the lifetype-1.2 branch, as the one in the trunk/
> was not special for the branch anyway.
>
> Oscar
> _______________________________________________
> pLog-svn mailing list
> pLog-svn at devel.lifetype.net
> http://limedaley.com/mailman/listinfo/plog-svn
>

-- 
Jon Daley
http://jon.limedaley.com/

If you're really afraid of some bad outcome, that's what you're going
to get.  If you behave as if you trust somebody, you're more likely to
get trust back.
-- Charles Green, founder of Trusted Advisor Associates


More information about the pLog-svn mailing list