Help - Search - Members - Calendar
Full Version: Renaming PHP -> PHP5
CubeCart Forums > CubeCart Version 3 > Installation & Upgrade Help (Version 3)
Rikk03
Im trying to get cubecart to work on my server with php v.5+ however to work, the file extension needs to be named .php5.

This was not a problem, used a handy program to rename all the file endings to .php5. Then I thought about renaming all the references within the code .... tool like dreamweaver can do that .... but im running linx so cant do that! ....... Its ok ..... found an alternative program that did the job nicely.

Then realized that what about the 1% of files that are encoded? Are there references to .php in there? Surely there must be.

Any chance someone could rename all the encoded files ..... then re encode and let me have?

OR ..... perhaps i could provide the files and u guys could do the re-encode and provide it as a package.

Many hosting companies keep servers with older versions of php due to stability / compatibility issues but also provide the ability to use the latest versions like mine.

Not sure i can upload - file too big perhaps ......

See attached archive for altered files.
EverythingWeb
You should have been able to just put a line in your htaccess file which parsed .php files through the PHP5 parser. It would be much much easier.

Also, there are no encoded files in CC3.0.X. Only CC4.0X(Beta) has encoded files.
Robsta
I've not heard of, or come across a requirement to change .php files to .php5 for PHP v5 to work, this seems like a silly thing to require. Are you sure you've read the instructions correctly? or have I missed something?
EverythingWeb
Rob, it is something that hosts that run both PHP4 & PHP5 can use.

.php & .php4 run through PHP4 parser
.php5 run through PHP5 parser.

It's quite common - but there are much easier ways of this chap getting his site using PHP5 smile.gif
Robsta
Ahhh.... I see. That makes sense. Thanks for the info tongue.gif
posty
QUOTE(EverythingWeb @ Jun 27 2007, 09:13 AM) *
Rob, it is something that hosts that run both PHP4 & PHP5 can use.

.php & .php4 run through PHP4 parser
.php5 run through PHP5 parser.

It's quite common - but there are much easier ways of this chap getting his site using PHP5 smile.gif




Can and will you please explaine how to change the files to PHP5?
I use godaddy and they say that if i use PHP5 i need to change the files to PHP5.
Brivtech
Read my post in this topic: http://www.cubecart.com/site/forums/index....showtopic=28679

It gives you details of how to alter the .htaccess file that will solve your problem. wink.gif

It's quick, and easy. There is no need to change the files to .php5 any longer.

The requirement of having a .php5 or .php4 file is that some servers are able to run both php versions for compatibility reasons. The difference in extension allows the different systems to be accessed separately. The fix I gave solves the renaming problem.
posty
QUOTE(Brivtech @ Jul 13 2007, 05:50 PM) *
Read my post in this topic: http://www.cubecart.com/site/forums/index....showtopic=28679

It gives you details of how to alter the .htaccess file that will solve your problem. wink.gif

The problem im having is in step 4 with this message;
MySQL Error Occured 2002: Can't connect to local MySQL server through socket '/usr/local/mysql-5.0/data/mysql.sock' (2)

I read your post and may see another problem and an answer.
I dont see the htaccess file in my root but when i read your post i seen this;

All versions of CubeCart released after February 5th 2008 will require a minimum of PHP Version 5.2 on your server.
The forthcoming version 4.0, the current version 3.0.x, and all releases until Februrary 5th will still be PHP4 compatible, and will remain so for as long as they are supported and maintained.

Im using the latest version of cube cart, v.16 as a stand alone upload. im not using or nor did i have v.15 loaded prior to the v.16 upload. Does this mean that i can v.16 as php4?

Thanks for your help.
Brivtech
QUOTE
I dont see the htaccess file in my root but when i read your post i seen this;

You don't see a .htaccess file, because there probably isn't one - So you need to create one. For clarity, I'll explain it all again in simple terms:

using a text editor like notepad, copy the following:

CODE
AddHandler x-httpd-php5 .php
  AddHandler x-httpd-php .php4


Save the file as ".htaccess", then upload the file to the root directory of your web server.

This will automatically switch any php files on your web server over to php5.

QUOTE
Im using the latest version of cube cart, v.16 as a stand alone upload. im not using or nor did i have v.15 loaded prior to the v.16 upload. Does this mean that i can v.16 as php4?


3.0.16 which is the current release version that you have will support php4. If Devellion releases an updated version before 5 Feb, 08, it will still be php4 compatible. If they release a version after that date, that will need to run on php5.

This doesn't mean that your software will suddenly not work - You can continue to use your CubeCart store as long as you like, but if you wish to upgrade it (after 5 feb), then you'll also need to ensure your server is running php5.2.

You have about 8½ months until you need to worry about this - IF you also need to upgrade.

Are you by any chance confusing your mySQL error with the current mySQL version number being almost identical to the current php version? They are separate things.
posty
No. I dont even know the current version of mysql. That is the error message that i got when going through the installer on step 4. I think i know what happened there and im gonna try something.

I greatly thank you for your help!
EverythingWeb
QUOTE
MySQL Error Occured 2002: Can't connect to local MySQL server through socket '/usr/local/mysql-5.0/data/mysql.sock' (2)


Dont worry about the PHP4/PHP5 parsing smile.gif

You need to talk to your hosting company as there is an issue with MySQL. Nothing to do with PHP.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.