Author Topic: 2.0.1.N error T_PAAMAYIM_NEKUDOTAYIM error (SOLVED)  (Read 4446 times)

osp

  • 3rd party VirtueMart Developer
  • Jr. Member
  • *
  • Posts: 66
2.0.1.N error T_PAAMAYIM_NEKUDOTAYIM error (SOLVED)
« on: February 22, 2012, 18:42:17 pm »
Parse error: syntax error, unexpected T_PAAMAYIM_NEKUDOTAYIM in C:\apm\www\elshp\administrator\components\com_virtuemart\models\user.php on line 129


Uuhaa...
Windows, Apache,  J1.7, VM2.0.1.N, PHP5.2

So for all of those who installed 2.0.1.N and see this error and wants to use it (as me because Max implemented conditional redirector / thankx), momental bug fix is to edit administrator/models/user.php

change line 129
      $userId = $vendorModel::getUserIdByVendorId($vendorId);
to

      $userId = $vendorModel->getUserIdByVendorId($vendorId);

Well, static members cannot be accesed on instances  :) Okay, this happens.
I just wonder noone saw this error during testing, it smashes VM down on first touch on category listing...

Cheers...




Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 10283
  • VM3.9 Eagle Owl
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: 2.0.1.N error T_PAAMAYIM_NEKUDOTAYIM error (SOLVED)
« Reply #1 on: February 22, 2012, 18:55:29 pm »
Thank you spilka, I posted already a slightly better method in another thread, but yours will be easier to find.

The last trouble is the line 129, please use this line
Code: [Select]
$userId = VirtueMartModelVendor::getUserIdByVendorId($vendorId);
When you have this error, treat your admin hard to get php5.3
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

Fintan

  • Jr. Member
  • **
  • Posts: 128
Re: 2.0.1.N error T_PAAMAYIM_NEKUDOTAYIM error (SOLVED)
« Reply #2 on: February 24, 2012, 10:31:34 am »
Thanks guys. This worked:
Code: [Select]
$userId = $vendorModel->getUserIdByVendorId($vendorId);
Cheers :)