Help Center Live Community

Please login or register.

Login with username, password and session length
Advanced search  

News:

Pages: [1]   Go Down

Author Topic: Undefined variable: blob when creating an operator  (Read 7495 times)

victor

  • HCL Member
  • ****
  • Offline Offline
  • Posts: 266
    • Victor Pereyra
Undefined variable: blob when creating an operator
« on: September 04, 2007, 02:03:33 PM »

I use HCL 2.1.5 on a linux server and everytime I create an operator I receive the following error

Notice: Undefined variable: blob in /home2/user/public_html/support/class/operator.php on line 196

The operator gets created but this error is anoying

Any ideas about it?

Thanks

HCL Admin

  • Administrator
  • HCL Superstar
  • *****
  • Offline Offline
  • Posts: 882
    • Help Center Live
Re: Undefined variable: blob when creating an operator
« Reply #1 on: September 04, 2007, 03:51:50 PM »

Your error reporting setting for PHP is set too low.  I believe in /class/include.php you can change it.  Just set it from E_ALL to 0 and that will go away.  It's not actually an error, it's just a notice that the variable wasn't predefined.  I'll change it in the source code so the notice doesn't come up again.
Logged
how may I help you today?

gazoi

  • Not too much to say...
  • *
  • Offline Offline
  • Posts: 10
Re: Undefined variable: blob when creating an operator
« Reply #2 on: September 18, 2007, 02:43:31 AM »


I would suggest that if a variable is to be used, it should be defined, no matter what the error reporting level.

This warning manifests itself when an operator is added with an image to be stored as a blob.

In hcl/class/operator.php,

replace code on line 196

Code: [Select]
if ($blob === '') $blob = ' ';
with

Code: [Select]
if( isset($blob) ) {
  if ($blob === '') $blob = ' ';
}

Logged

HCL Admin

  • Administrator
  • HCL Superstar
  • *****
  • Offline Offline
  • Posts: 882
    • Help Center Live
Re: Undefined variable: blob when creating an operator
« Reply #3 on: September 18, 2007, 03:44:33 AM »

Actually, that won't work.  That was done because if a bug in certain versions of PHP (yet another reason to go the PHP5+ route!).  Look at the logic, if it is set, then if it's null...  The actual fix is before the variable is assigned from the request, to do a var $blob; :)
Logged
how may I help you today?

XtremeCrash

  • Not too much to say...
  • *
  • Offline Offline
  • Posts: 1
Re: Undefined variable: blob when creating an operator
« Reply #4 on: September 19, 2007, 08:47:31 PM »

Actully I get the same problem.I just installed today.Also The chat window pops up an theres a blank page.
Logged

victor

  • HCL Member
  • ****
  • Offline Offline
  • Posts: 266
    • Victor Pereyra
Re: Undefined variable: blob when creating an operator
« Reply #5 on: September 20, 2007, 08:50:16 AM »

I solved my problem with mlzhosting advice, but I didn't have the "blank page" issue, take a look at this post

http://www.helpcenterlive.com/smf/index.php/topic,218.0.html
Pages: [1]   Go Up
 

Page created in 0.164 seconds with 18 queries.