Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

upgrade to php5 and php5CGI


lindsayanng

Recommended Posts

I THOUGHT i was running on PHP5, but i guess not. I was getting weird errors (you can see my post in general chit-chat) and when i contacted my host, they told me it might help if i upgraded to php5 (it doesnt really make sense to me why though)

 

So basically my host gives me a few options.. This is what their php configure upgrade page looks like:

If you are not familiar with these options, do NOT change them.

This can cause all PHP scripts on your site to stop functioning if misconfigured.

NOTES:

# Since it is being deprecated, PHP4 is no longer available with FastCGI Support.

# If you have custom handlers specified in ~/public_html/.htaccess, changing these settings can overwrite them. If you are not sure, make a backup of ~/public_html/.htaccess before changing settings.

PHP4

All files with the extension .php will be handled by the PHP4 engine.

This version of PHP will be deprecated soon, and it is suggested to only use it until you can safely migrate your scripts to PHP5. Here is a migration guide to help you upgrade to PHP5:

# Migration Guide

PHP5

All files with the extension .php will be handled by the PHP5 engine.

Current, most reliable and best performing version of PHP

PHP5 (FastCGI)

All files with the extension .php will be handled by PHP5 FastCGI processes.

FastCGI for PHP makes all your PHP applications run through mod_fastcgi instead of mod_suphp. This eliminates the overhead of loading the PHP interpretor on every hit. Since it is always in memory ready for the next hit, the responses will be generated faster.

 

NO MODIFICATIONS to your existing PHP applications will be performed so you can easily enable and disable it at will.

# Questions? click question for more info What are the benefits of using FastCGI for PHP with your hosting account?

# What are the potential problems with FastCGI and why I might want to disable it for PHP?

 

 

Does oscommerce work with the PHPCGI or should i just upgrade to the regular PHP5?

 

Also, how difficult is it to patch up all the errors that i will have when i switch over??

 

All my host says is this:

 

Migrating Configuration Files

 

Since the ISAPI modules changed their names, from php4xxx to php5xxx, you need to make some changes in the configuration files. There were also changes in the CLI and CGI filenames. Please refer to the corresponding section for more information.

 

Migrating the Apache configuration is extremely easy. See the example below to check the change you need to do:

 

Example #1 Migrating Apache configuration files for PHP 5

 

# change this line:

LoadModule php4_module /php/sapi/php4apache2.dll

 

# with this one:

LoadModule php5_module /php/php5apache2.dll

 

If your web server is running PHP in CGI mode, you should note that the CGI version has changed its name from php.exe to php-cgi.exe. In Apache, you should do something like this:

 

Example #2 Migrating Apache configuration files for PHP 5, CGI mode

 

# change this line:

Action application/x-httpd-php "/php/php.exe"

 

# with this one:

Action application/x-httpd-php "/php/php-cgi.exe"

 

In other web servers you need to change either the CGI or the ISAPI module filenames.

 

please be patient.> I am VERY new at all this, and just want to make sure my site is fully functional, up to date, and SAFE from hackers.. this is what my host told me to do..

 

THANKS FOR YOU HELP!!!

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

nevermind. my host said that the php5 fast CGI was just an auto update which required little work on my part.

 

When i switched to php5, i didnt get ANY errors on my site.. it bothers me that i didnt get any errors.. is that normal.

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

If your running the rc2 version then there shouldn't be any errors. If your running ms2 and thought you were running PHP 5 already and installed the patchs then you shouldn't get any errors either. Be happy that there was none. Just test everything to be sure it still works.

Link to comment
Share on other sites

If your running the rc2 version then there shouldn't be any errors. If your running ms2 and thought you were running PHP 5 already and installed the patchs then you shouldn't get any errors either. Be happy that there was none. Just test everything to be sure it still works.

 

 

When you say patches do you mean the upgrade files you find when you download oscommerce???

 

So if someone is using MS2.2 he first has to upgrade to RC1 by using "upgrade-22rc1.html" found under extras and then use the upgrade.html file to upgrade from rc1 to rc2????

 

Also at the risk at going off-topic i am using a template that instead of using <?php uses <?= and is not compatible with php5 even if you replace the = with php (YES I did that in all the files), do you think that it is not compatible with php5 because of the template or because i dint upgrade to RC2 from M2.2

Link to comment
Share on other sites

Your server configuration disallows the use of PHP "Short Tags", and that has nothing directly to do with the version of PHP being run.

 

You can allow the use of Short Tags by editing the php.ini file (if you have access to one).

 

Vger

Link to comment
Share on other sites

oh crap.. i guess i was wrong..

 

the cache that was saved on my cpu at home must have made it LOOK like everything was ok, but its not.

 

It is really weird, when i go to the index page, everything is FINE, there are no broken images or errors.. but when i log in with my account, i get directed to the login sucess page and ALL of the images are gone and i loose my style. But then, when i go to the product description, I get all my images back!!

 

and i get this error if i try to CREATE an account:

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

 

Please contact the server administrator, root@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error.

 

More information about this error may be available in the server error log.

 

Is this a normal occurance when you upgrade to php5?

 

I cant seem to find the guide to patching oscommerce for the upgrade to php5.. if someone would be nice enough to post it, i would be happy

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

With PHP5 on You need to apply register globals patch.

 

There are a few contrib available to do this.

 

This patch is needed if You store is prior to Rc1 where the register globals were to be set to on.

 

Satish

Ask/Skype for Free osCommerce value addon/SEO suggestion tips for your site.

 

Check My About US For who am I and what My company does.

Link to comment
Share on other sites

so if i just go to the contributions page and search REGISTER GLOBALS, i will get all the info i need??

 

Thats it? its that easy?? i sure hope so!! i cant get into my admin right now either

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

I think there is a patch by VGER on Register globals try that.

 

Or download RC2 and compare code as to what all had been done to handle this(more complex then applying a patch thru contrib).

 

Satish

Ask/Skype for Free osCommerce value addon/SEO suggestion tips for your site.

 

Check My About US For who am I and what My company does.

Link to comment
Share on other sites

thank you. I will look into that tonight.. HOPEFULLY that is my only issue.

 

if you have time, would you mind explaining to me what register_globals does and means?? I am still new at this whole thing and am trying to learn how it all works.

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

The php5 patches I thik your after are here

http://www.oscommerce.com/community/contributions,4654

Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Link to comment
Share on other sites

thanks sam.. I haven't gotten any errors like that though. My products are all there!!

 

Look at the site if you would like:

 

Furry Family

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

ok SATISH.. i think your advice was a little "off" i downloaded VGER's register globals contribution and was reading through the text which was VERY informational (i actually kinda learned WHAT register globals did) but what it said in BIG BOLD LETTERS was DO NOT INSTALL ON EXISTING STORES THIS IS FOR A FRESH INSTALL ONLY

 

so i need to know what kind of PATCHES i can put on an existing store that has been highly modified.

 

 

i REALLY would appreciate any direction. I searched the forums and such, but i can not find a solution to my issue (and you guys know me, i TRY to answer my own questions first!)

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

nevermind.. I figured out that my site is just FINE and the broken images had NOTHING to do with the php5 upgrade.. when i spoke with the host support guy, he also told me to turn my hotlink protection ON and that broke my images on my shared SSL pages because i did not add my host as an allowed website.

 

All is well now,a nd i GUESS since i THOUGHT all a long that i was on PHP5, i already installed all the patches for the upgrade.. NICE

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...