News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Fatal error: Cannot redeclare class vmVersion

Started by easypony, August 03, 2016, 03:02:46 AM

Previous topic - Next topic

easypony

Hi

Joomla version 3.6.0, PHP 5.5.30

I have updated to VM 3.0.14 and am getting a white screen on the front-end. After switching on error reporting I see the error:

Fatal error: Cannot redeclare class vmVersion in /home/XXXX/public_html/XXXX/administrator/components/com_virtuemart/version.php on line 22

I have searched for this error and cannot find an instance of it.

Please help.

Steve

GJC Web Design

GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

easypony

Hi

Thanks for the reply.

I did install 3.0.16 and exactly the same error.

If I comment out the lines:

//if(!class_exists('vmVersion')) require(VMPATH_ADMIN.DS.'version.php');
//defined('VM_REV') or define('VM_REV',vmVersion::$REVISION);


From the administrator/components/com_virtuemart/helpers/config.php I get the site back but now with the error (only if error reporting is on so not a fatal error):

Notice: Use of undefined constant VM_REV - assumed 'VM_REV' in /home/XXXX/public_html/XXXX/administrator/components/com_virtuemart/helpers/vmjsapi.php on line 91

Notice: Use of undefined constant VM_REV - assumed 'VM_REV' in /home/XXXX/public_html/XXXX/administrator/components/com_virtuemart/helpers/vmjsapi.php on line 209


I hope that helps as I need to get this sorted.

Thanks
Steve

GJC Web Design

As I say.. no other reports of this and the line

if(!class_exists('vmVersion')) require(VMPATH_ADMIN.DS.'version.php');

is there to prevent the

Fatal error: Cannot redeclare class vmVersion in /home/XXXX/public_html/XXXX/administrator/components/com_virtuemart/version.php on line 22

VM_REV needs to be declared of course

Can only suggest that vmVersion is being declared somewhere else by old files etc

what is the site history?

GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

PRO

what about the AIO component?

did you update it?

easypony


GJC Web Design

then u need to do a trace or enable Xdebug etc to find where it is already declared..

but as we already asked the history of the site....    :-\
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation