Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

after install, I get PHP warning saying


jasonfb2

Recommended Posts

After I get through the 7 steps of the install, I am presented with "Installation was succesfful" with a button that says "Catalog" and "Admin Tool"

 

I notice that a mysql DB has been created with 26 tables.

 

When I click either "Catalog" or "Admin Tool" a new window opens with this error message:

 

Warning: main(includes/languages/.php) [function.main]: failed to create stream: No such file or directory in /Library/WebServer/homesite/client_projects/alice_jewelry/catalog/admin/includes/application_top.php on line 130

 

Fatal error: main() [function.main]: Failed opening required 'includes/languages/.php' (include_path='.:/usr/local/lib/php') in /Library/WebServer/homesite/client_projects/alice_jewelry/catalog/admin/includes/application_top.php on line 130

 

 

I have installed OS COmmerce on this server before and gotten it to work, so I don't know why I'm getting this error message.

Link to comment
Share on other sites

the directory

/Library/WebServer/homesite/client_projects/alice_jewelry/catalog/admin/includes

 

seems to be readable by everyone:

drwxr-xr-x 21 jason admin 714 Jul 12 14:46 includes

 

and so does:

/Library/WebServer/homesite/client_projects/alice_jewelry/catalog/includes/languages/

 

 

drwxr-xr-x 8 jason admin 272 Jul 12 14:46 languages

 

I will try to install the software some where else on the server. maybe it's a realm problem

Link to comment
Share on other sites

OK, one more time. I've now tried installing OS Commerce again, went though successful installation of the package (all the steps, got to the last screen) and got the same result...

 

http://jfb.homeip.net/client_projects/selmasbeads/index.php

 

and I get the same error:

 

Warning: main(includes/languages/.php) [function.main]: failed to create stream: No such file or directory in /Library/WebServer/homesite/client_projects/selmasbeads/includes/application_top.php on line 285

 

Fatal error: main() [function.main]: Failed opening required 'includes/languages/.php' (include_path='.:/usr/local/lib/php') in /Library/WebServer/homesite/client_projects/selmasbeads/includes/application_top.php on line 285

 

 

 

 

and

http://jfb.homeip.net/client_projects/selm...admin/index.php

 

produces

 

Warning: main(includes/languages/.php) [function.main]: failed to create stream: No such file or directory in /Library/WebServer/homesite/client_projects/selmasbeads/admin/includes/application_top.php on line 130

 

Fatal error: main() [function.main]: Failed opening required 'includes/languages/.php' (include_path='.:/usr/local/lib/php') in /Library/WebServer/homesite/client_projects/selmasbeads/admin/includes/application_top.php on line 130

 

 

 

Now I'm not sure about this, but doesn't it seem that the script in application_top.php on line 130 is trying to include a file "includes/languages/.php"? But that can't be right because there is no ".php" file in this folder -- the correct file it should be including is "english.php",

right?

 

So in this application_top.php script why is the $language variable empty, producing "includes/languages/.php" instead of "includes/languages/english.php"?

Link to comment
Share on other sites

I have just installed the system myself (a few times) with the same problems. This seems to be a consistant problem with people and although there are many posts on the topic no one has provided the solution.

 

Could someone please provide their solution to the language problem outlined here... I am using the newest version

 

osCommerce 2.2 Milestone 2 from the download section

 

Fatal error: Failed opening required 'includes/languages/.php' (include_path='') in /home/www/mysite/catalog/admin/includes/application_top.php on line 130

 

AND

 

Fatal error: Failed opening required 'includes/languages/.php' (include_path='') in /home/www/mysite/catalog/includes/application_top.php on line 285

 

A solution might sound like .. open application_top.php in the admin includes directory and replace

 

if (file_exists(DIR_WS_LANGUAGES . $language . '/' . $current_page)) {

include(DIR_WS_LANGUAGES . $language . '/' . $current_page);

}

 

with

 

if (file_exists(DIR_WS_LANGUAGES . english . '/' . $current_page)) {

include(DIR_WS_LANGUAGES . $language . '/' . $current_page);

}

 

 

_____________________

 

I have edited text all over the place in order to make this thing work. It has sometimes opened a page and other times created other failures. The truth is that other people have gotten this software to work while others cannot.

 

Why are there some people who install without this problem and others who do have this issue. Is it in the tables?...

 

Please help if you have a solution.

Link to comment
Share on other sites

I have fixed this problem... It may have had to do with a few things...

 

1. I found that the sample data from the sql import did not actually populate correctly. I ran the sql commands manually and found that it created an additional 20 or so tables. Populating them, was also prob a good idea, also from the sql text.

 

2. I reran the setup without the database setup option checked. After tweaking the settings I found the program worked correctly. One of the options that HAD to be changed was the storing of user data in the tables instead of in files. so...

 

Switch session storage to files and not in database for shared servers....

 

I also had to adgjust the cookies location to be the default location. Both of these things together corrected the problem. There are other issues which arise but those are not necessary to cover here....

 

Short answer:

do not change the templates or manually adjust any php files. They are satisfactory as is. Just alter the setup until it runs.

 

Artisan

Link to comment
Share on other sites

I got the same problem:

Warning: main(includes/languages/.php) [function.main] ....

as jasonfb2 posted.

 

<Artisan> Unfortunately your solution didn't help really.

Maybe anyone will just instruct in detail please, like "1,2,3 do this - replace this with that... "

A lot of people getting the same error

thanks

Link to comment
Share on other sites

One of the options that HAD to be changed was the storing of user data in the tables instead of in files. so...

 

Switch session storage to files and not in database for shared servers....

THis is the only time that I have ever seen someone having problems with storing sessions in MySQL. In general, you want to avoid storing sessions in files on shared servers because they are generally accessible. I.e. while it may have worked for you, I don't think that this is good advice in general.

 

For the others, does godaddy have a control panel with something like phpMyAdmin? There are a number of posts with detailed instructions for uploading a .sql file with phpMyAdmin.

 

Hth,

Matt

Link to comment
Share on other sites

Database is imported, no need to import it again wit PHPMyAdmn

and I don't think that's really for storing sessions in database.

anyway, it doesn't help as well

 

can any proff reply with detailed problem fix please

we're getting it over 5 day, noone just tries to help :rolleyes:

 

thanks

Link to comment
Share on other sites

please suggest what to do really

 

Fatal error: Failed opening required 'includes/languages/.php' (include_path='') in /home/www/mysite/catalog/admin/includes/application_top.php on line 130

 

that message appear every time I refresh.

session is stored in mysql

tried in temp folder but I guess I have no access to it.

 

what do you think is the problem

 

that Fatar error only appears if refresh or click somewhere.

the first page from several computers load sucesfully.

I'm on godaddy hosting

thanks

Link to comment
Share on other sites

I called the guys at godaddy they said the database needs to be debug!!!

 

besides really friendly service that was all I got out of it!

 

 

Mario

_______________________________

Node Networks - Technology Solutions

Edmonton, AB

Canada

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...