Missing Dialog Text in VirtueMart 1.1.2

Posted by: gbluma

Tagged in: Untagged 

I've noticed that in VirtueMart (only on some server setups, mind you) the dialog that pops up when you "Add to Cart" is missing it's message (as follows):

virtuemart_missing_text

instead of:

virtuemart_with_text

I've been struggling with this bug in VirtueMart for a few weeks now. It's been particularly difficult to pin-down since it is intermittent and might have something to do with our server implementation. Regardless, the solution I outline here fix the issue and the only downside is that VirtueMart will not be able to log it's errors to file (which you might not need anyway).

The Solution:

What we can do is disable VirtueMart's vmFileLogger object from being attached to the composite logger that VirtueMart uses to pass messages from different functions. I still don't know why this is an issue, but with a solution in my grasp I'm satisfied enough to let it go.

To make the fix you can do the following:

At about line 133 of administrator/components/com_virtuemart/classes/Log/LogInit.php change

$vmLogger->addChild($vmFileLogger);

to:

//$vmLogger->addChild($vmFileLogger);

This will keep the fileLogger from getting passed around with the other global variables in use by VirtueMart. Again, I can't wrap my head around why this is the case, but I'm happy it works.

Comments (1)add comment

Ryan said:

0
Wow
Wow, thanks! What a random issue and this fix worked perfectly.
 
February 14, 2010
Votes: +0

Leave a Comment

busy