Jump to content

Works fine on IE and Not on FF


egturnkey

Recommended Posts

Hello friends,

 

I've simple cart script where a button once visitor click on it,it send the item to the cart

 

It works fine on IE and not working on FF due to something called append_cookie

 

here is the code

 

<?
} else if ($productrow['type'] == 0 && (!$isMember && !$isAdmin)) {
echo "<b>Member Download Only</b>";
} else if ($productrow['type'] == 1 || $productrow['type'] == 2) {
echo "<a href='#' onclick='append_cookie(\"cartcontent\", \"".$productrow['productID']."\", \"\")'>";
echo "<img src='$addtocart_button' border=0>";
echo "</a>";
echo "<a href='#' onclick='append_cookie(\"cartcontent\", \"".$productrow['productID']."\", \"\");self.location.replace(\"".FILE_INDEX."?action=checkout\")'>";
echo "<img src='$buy_button' border=0>";
echo "</a>";
}
} else {
echo "<img src='$na_button' border=0>";
}
?>

Link to comment
https://forums.phpfreaks.com/topic/189828-works-fine-on-ie-and-not-on-ff/
Share on other sites

The append_cookie() function is a javascript function that is being called by your code.

In FFX, you can see any javascript errors by opening the error console from the tools menu,

and then load and run your page. You will then see any javascript errors that are generated.

The append_cookie() function is a javascript function that is being called by your code.

In FFX, you can see any javascript errors by opening the error console from the tools menu,

and then load and run your page. You will then see any javascript errors that are generated.

 

Thanks, now i can see it

11261228.jpg

 

but i don't know how to define it  :shrug:

 

here is the js file also may helps

 

http://www.manalnor.com/misc.js

 

thanks

 

Ok that append_cookie() function is certainly in that js file, so when you call it, that file does not seem to have been included.

 

You need to check where the include of the js file is, and where your call to the append_cookie() function is

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.