Archive for the ‘OsCommerce’ Category

osCommerce installation problems solved!

Thursday, September 3rd, 2009

I decided to install oscommerce to sell stuff.

Created a vhost, created the database, downloaded oscommerce, copied the files to the proper directory, assigned the right privileges and typed the proper url, up to here everything is really easy, looks smooth.

So here comes an installation screen. It looks like an easy process right?

First you type in the database connection info after you click ok you get a nice message saying that the database was created successfully!, the next steps are trivial, it’s a couple of normal settings. On the last step you can see 2 buttons that take you to the catalog or to the administration tool.

So I clicked catalog…. boom! nothing! just a nasty error page with something like this:

Warning: require(includes/languages/.php) [function.require]: yadda yadda on line 288

Ok, so I tried the administration tool… crap! same screen! something wrong is happening!

Being a PHP programmer I was like OK fine let’s correct the code, so I opened my eclipse and started debugging… after a couple of hours of adding flags, debuging, linking code logic and more I started thinking that it might be a DB problem so I went to the database console and check the language table WOW! it’s empty! ok, lt’s see configuration… empty!

Ok, I don’t think oscommerce delivers an empty database right? so after looking at the code I ended up on line 57 of the file install/rpc.php and there’s the sql source file.

Next thing I did was directly import the file to mysql…. ok 😀

Did a couple of queries to see if the languages and configuration tables were empty and they were not so the last step was to refresh the catalog and administration tools and guess what? They both work!!!!

So I’m writing this post to help anyone that gets the same errors.

I’ll correct the code and let oscommerce know something is wrong with their code.