Forum Moderators: coopster

Message Too Old, No Replies

Undefined index error

interspire shopping cart error

         

HetzelCreative

3:55 pm on May 18, 2011 (gmt 0)

10+ Year Member



I am getting this error on my modified Interspire shopping cart when I click on "View your order" after a purchase has been made:


Notice: Undefined index: ISC_CLASS_PRODUCT in /nfs/c08/h04/mnt/123587/domains/johnpitzersales.com/html/includes/display/SideProductAddToWishList.php on line 8

Fatal error: Call to a member function GetProductName() on a non-object in /nfs/c08/h04/mnt/123587/domains/johnpitzersales.com/html/includes/display/SideProductAddToWishList.php on line 8


Would anybody happen to know what is causing this? The fatal error details mention the Add To Wish List file. I'm not even using that, so do you think if I just deleted it it would fix the issue? (by the way, the website this occurs on is www.johnpitzersales.com. You can recreate the error by clicking on "My Account" at the top. Thanks for your guys' help!

rocknbil

4:29 pm on May 18, 2011 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Welcome aboard, don't know the software but what I can tell you . . .

ISC_CLASS_PRODUCT <-- this is a constant. Constants are values that don't change throughout the program. Generally this is something set in some configuration file.

An index is a reference to an array, for example, a, b, c are the indices in the following array.

$foo = (
'a' => 'Ayee',
'b' => 'Bee',
'c' => 'Cee'
);

So if I tried to do
echo $foo['d'];

I'd get "undefined index d"

Somewhere the constant is being called in an array and it's not set.

Fatal error: Call to a member function GetProductName() on a non-object

The missing or unset constant is probably the cause of this error. That is, the next "step" in the programming is probably relying on a value for
ISC_CLASS_PRODUCT to create an object that GetProductName requires to do whatever it does.

Combining the two, you have some misconfiguration or already have files missing, or in the wrong place, or file permissions won't allow it to execute, or can't be read . . . something. It may even be some setting you need to change for your products, like "allow these files to be in wish lists" (who knows, just throwing an example out there.) The only place to go from here is back to the software documentation, check everything with a fine tooth comb. I wouldn't delete files. That will only make matters worse.