Author Topic: Does VM 2 still support PHP 5.1?  (Read 2620 times)

skeg64

  • Beginner
  • *
  • Posts: 3
Does VM 2 still support PHP 5.1?
« on: November 29, 2011, 11:35:53 am »
I have searched but can't find system requirements anywhere.

I am using PHP 5.1.6, which is supported by Joomla 1.5

If so, I have found references in VM to PHP functions that aren't supported in 5.1.

RolandD

  • Full Member
  • ***
  • Posts: 780
    • Home of CSVI
Re: Does VM 2 still support PHP 5.1?
« Reply #1 on: November 29, 2011, 15:59:39 pm »
I don't think VM2 should support PHP 5.1.6 it is old and no longer maintained and so is PHP 5.2. Everything should move to PHP 5.3, this is the current maintained version.
Regards,

RolandD

CSVI
http://www.csvimproved.com/

skeg64

  • Beginner
  • *
  • Posts: 3
Re: Does VM 2 still support PHP 5.1?
« Reply #2 on: November 30, 2011, 01:45:36 am »
I agree, but that was not the question.

Should I report PHP 5.1 incompatibilities as bugs or not?

Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 9997
  • VM3.2 Cached and Optimized
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: Does VM 2 still support PHP 5.1?
« Reply #3 on: November 30, 2011, 14:51:57 pm »
No, dont report this as a bug.
Imho we just support one of the latest 5.2.x, but not 5.1
I should fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

skeg64

  • Beginner
  • *
  • Posts: 3
Re: Does VM 2 still support PHP 5.1?
« Reply #4 on: December 01, 2011, 03:03:10 am »
OK, but so far I have only had to make the following change: In adminstrator/components/com_virtuemart/models/config.php around line 90 there is a call to PHP's pathinfo() function. This function doesn't return the 'filename' in PHP 5.1. So I changed:

Code: [Select]
$path_info = pathinfo($file);

to:

Code: [Select]
$path_info = pathinfo($file);
if (!array_key_exists('filename', $path_info)) {
$path_info['filename'] = str_replace('.'.$path_info['extension'], '', $path_info['basename']);
}

see: http://php.net/manual/en/function.pathinfo.php

Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 9997
  • VM3.2 Cached and Optimized
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: Does VM 2 still support PHP 5.1?
« Reply #5 on: December 01, 2011, 11:02:35 am »
ah good to know, yeah to add such a small fix for php5.1  should be considered. yes
I should fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/