Author Topic: Problems with cart: Products not added and cart below starting page  (Read 10366 times)

martin.g

  • Beginner
  • *
  • Posts: 8
Hello,

I have two problems with the cart. Maybe they are depending.
A click on "Cart" in my menu redirects me to:
http://www.example.org/joomla/index.php/warenkorb -> That is fine, although I don´t know why there has to be the index.php in it, but okay. Perhaps this depends on SEO.

When I click on "Add to cart", I get redirected to
http://www.example.org/joomla/index.php/shop/myCategory/myProduct/index.php -> This shows the starting page and below the starting content the cart is displayed. Additionally the cart is still empty and in the cart table no product is added.
Perhaps it depends on this error message:
Warning: mysqli_close() [function.mysqli-close]: Couldn't fetch mysqli in /www/example.org/web/joomla/libraries/joomla/database/database/mysqli.php on line 148
I found this message only appearing in context of the cart.

Can you tell me what to do? The only post with this problem on VM2 I found, was this one:
http://forum.virtuemart.net/index.php?topic=89641
And the answer was not quite helpful.

Thanky you and best regards
Martin

Edit: Sorry, I did not want to post this into Administration & Configuration as Milbo said it was wrong in this forum. It was a mistake, although I think this would be a configurable item.
And I use Joomla 1.7 with VM 1.9.8_RC2e

jenkinhill

  • UK Web Developer & Consultant
  • Global Moderator
  • Super Hero
  • *
  • Posts: 28336
  • Always on vacation
    • Jenkin Hill Internet
Re: Problems with cart: Products not added and cart below starting page
« Reply #1 on: August 29, 2011, 16:56:09 pm »
If you are using PHP5.3 then don't use MySQLi - http://forum.virtuemart.net/index.php?topic=90380.msg296347#msg296347
Kelvyn

Jenkin Hill Internet,
Lowestoft, Suffolk, UK

Unsolicited PMs/emails will be ignored.

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

Currently using VirtueMart  4.0.2 10661 on Joomla 3.10.9 PHP 7.4.29

martin.g

  • Beginner
  • *
  • Posts: 8
Re: Problems with cart: Products not added and cart below starting page
« Reply #2 on: August 29, 2011, 17:05:46 pm »
Thank you for the answer. I use PHP 5.2.13
I got got neither an error with installing 1.9.8d nor upgrading to 1.9.8e. But I also get to Error 404 when I click comvirtuemartallinone or comvm-all-in-one in adminmenu. I have both entries and got no error while installation. Is this related to the problem? I didn´t know I could configure anything about the allinone modules and thaught the admin entry was fake.

martin.g

  • Beginner
  • *
  • Posts: 8
Re: Problems with cart: Products not added and cart below starting page
« Reply #3 on: August 29, 2011, 17:17:25 pm »
Well, I tried to switch from MySQLi to MySQL. The only difference is the missing error message :-)

Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 10305
  • VM3.9 Eagle Owl
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: Problems with cart: Products not added and cart below starting page
« Reply #4 on: August 30, 2011, 10:17:28 am »
Yes  the admin entry of the aio is a fake. The new version shows a page with "here is nothing to see uninstall me" lol.

look on the field of your session table of joomla. The field data should be text. in the other case your session field is to short and cannot hold the cart completly.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

martin.g

  • Beginner
  • *
  • Posts: 8
Re: Problems with cart: Products not added and cart below starting page
« Reply #5 on: August 30, 2011, 17:37:52 pm »
Okay, then I will ignore the admin entries. Thank you.
The field type of "data" in "_session" is even "longtext".
Do you have any other suggestions?

Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 10305
  • VM3.9 Eagle Owl
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: Problems with cart: Products not added and cart below starting page
« Reply #6 on: August 30, 2011, 17:51:25 pm »
Does the F version makes a difference? Does it help to disable SEO?
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

martin.g

  • Beginner
  • *
  • Posts: 8
Re: Problems with cart: Products not added and cart below starting page
« Reply #7 on: August 30, 2011, 18:41:36 pm »
Ah, I didn´t get, there is a new version. So I upgraded now, but nothing changed in behaviour.

When I disable SEO (in Joomla and VM) the error still persists. I get redirected to http://www.example.org/joomla/index.php and the cart shows below the index page and no products are in the cart.

martin.g

  • Beginner
  • *
  • Posts: 8
Re: Problems with cart: Products not added and cart below starting page
« Reply #8 on: August 30, 2011, 19:19:24 pm »
Well, I´m a little desperated now. I cleared the table and installed the demo data and the behaviour still is the same :-(

martin.g

  • Beginner
  • *
  • Posts: 8
Re: Problems with cart: Products not added and cart below starting page
« Reply #9 on: August 30, 2011, 19:52:32 pm »
I suppose the reason is a javascript error on the site. I did a new demo installation on a fresh joomla with demo data and now I know how it should look/work. Didn´t know there was a popup layer with question how to proceed. I guess the JS error prevents the JS function that opens this window from being started.
The message (from Firebug) is:
jQuery(".product").product is not a function
in
components/com_virtuemart/asses/js/vmprices.js Line 109

Do you know the reason of this error? Parallel I will try to find out the reason on my own, but I don´t know much about JS on Jommla

Studio 42

  • Contributing Developer
  • Sr. Member
  • *
  • Posts: 4652
  • Joomla & Virtuemart developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 & 3
Re: Problems with cart: Products not added and cart below starting page
« Reply #10 on: August 30, 2011, 21:37:34 pm »
I suppose the reason is a javascript error on the site. I did a new demo installation on a fresh joomla with demo data and now I know how it should look/work. Didn´t know there was a popup layer with question how to proceed. I guess the JS error prevents the JS function that opens this window from being started.
The message (from Firebug) is:
jQuery(".product").product is not a function
in
components/com_virtuemart/asses/js/vmprices.js Line 109

Do you know the reason of this error? Parallel I will try to find out the reason on my own, but I don´t know much about JS on Jommla
Hello,
We use the google Jquery api from "http://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js" , is this loaded ?

Can you test on the defaut template (BEEZ-20)to know if it's not a js/css conflict with a template ?
Try to remove/disable all none Virtuemart 2 modules.

jQuery(".product").product is not a function is typical a mootools  conflict or non existing jQuery library


martin.g

  • Beginner
  • *
  • Posts: 8
Re: Problems with cart: Products not added and cart below starting page
« Reply #11 on: August 31, 2011, 10:11:16 am »
Yes the google jQuery is loaded. Template BEEZ-20 couldn´t be found. I copied from my fresh installation, didn´t change anything.
But I found the solution. After loading the VM skripts the company doing the webdesign loads jquery-1.4.2 .... So jQuery Version is overwritten with an old one. Perhaps I should have changed the complete Joomla Template to BEEZ-20, buit I didn´t realize.
Well guys, thank you for pushing me to solution! I know on the difficulty to assist while not sitting in front of the problem.

Best regards
Martin

Eric Brown

  • Jr. Member
  • **
  • Posts: 77
  • So long, and thanks for all the fish.
    • CBA Web Development
Re: Problems with cart: Products not added and cart below starting page
« Reply #12 on: September 12, 2011, 19:56:34 pm »
Martin.  I am getting this error too.  Please explain where to go to fix this.  I read your post, but am not quite sure where to fix it.

Thanks!

Eric
So long, and thanks for all the fish!

Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 10305
  • VM3.9 Eagle Owl
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: Problems with cart: Products not added and cart below starting page
« Reply #13 on: September 12, 2011, 20:40:27 pm »
load your page, use firebug or simular,... search for jQuery, ensure that only the virtuemart version is loaded.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

Eric Brown

  • Jr. Member
  • **
  • Posts: 77
  • So long, and thanks for all the fish.
    • CBA Web Development
Re: Problems with cart: Products not added and cart below starting page
« Reply #14 on: September 12, 2011, 20:53:01 pm »
Actually.  I got it by setting the database to MySQL instead of MySQLi...weird...

thanks so much!
So long, and thanks for all the fish!