[pmwiki-users] Beginner question...

IchBin weconsul at ptd.net
Fri Sep 8 13:04:59 CDT 2006

Sorry I am new to php and pmwiki. Having said that I have taken the
'VisitorsLogging' recipe and create a new recipe called
'VisitorsLoggingDB'. The new recipe persist all of the data to a
database. This is for my own use and not sure if other people would want
to use it. Anyway, my question is: How do I pass the defined vars in the
config.php so they are usable in the recipe?

All works as designed. Now I want to be able to pass some configured
vars from the config to the VisitorsLoggingDB recipe. Problem is that
when I step thru the code using a debugger I do not see these vars
available for the recipe.

Example: I define this is my config:

## - ( VisitorsLogging \DB)
     $VisitorsLoggingDBDatabase = 'visitors_log';
     $VisitorsLoggingDBServer   = 'localhost:3306';
     $VisitorsLoggingDBUserid   = 'DBUserid';
     $VisitorsLoggingDBPassword = DBPassword';
     $VisitorsLoggingDBHome     = 'weconsultants.phpnet.us';

In the recipe I do the following to make sure the vars have the value

     SDV($VisitorsLoggingDBDatabase, ' ');
     SDV($VisitorsLoggingDBServer, ' ');
     SDV($VisitorsLoggingDBUserid, ' ');
     SDV($VisitorsLoggingDBPassword, ' ');
     SDV($VisitorsLoggingDBHome, ' ');

All are evaluated to be ' ';  What do I have to do to pass the defined
vars and their  value to the recipe from the config?

Thanks in Advance...
IchBin, Pocono Lake, Pa, USA              http://weconsultants.phpnet.us
'If there is one, Knowledge is the "Fountain of Youth"'
-William E. Taylor,  Regular Guy (1952-)

More information about the pmwiki-users mailing list