Look in your php.ini file for error_reporting = XXXXXX and change it to
error_reporting = E_ALL & ~E_NOTICE
This will keep this message from popping up where you use an undeclared variable.
Or, alternatively, you can place the following line of code:
error_reporting(E_ALL & ~E_NOTICE);
at the top of the script and that should resolve the issues as well.
Hope that helps:
Chris King