Part of the EllisLab Network
   
 
CodeIgniter & GoDaddy
Posted: 10 May 2008 12:13 PM   [ Ignore ]  
Grad Student
Rank
Total Posts:  61
Joined  10-04-2007

So I’m just setting up my new hosting I got through GoDaddy a few weeks, and just got done installing CodeIgniter 1.6.1 on there. When I go to the usual CI welcome page it displays just fine, but there is an error about it saying “fclose(): supplied argument is not a valid stream resource” found in CI’s Common.php file.

I didn’t get any issue like this when using CI 1.6.1 locally, so is this some a GoDaddy induced error? Any else experienced an issue like this with GoDaddy?

Cheers.

Profile
 
 
Posted: 10 May 2008 12:19 PM   [ Ignore ]   [ # 1 ]  
Grad Student
Rank
Total Posts:  61
Joined  10-04-2007

A quick update: Just had a little browse in the Common.php file, and above the line with the error is makes note that the problem is probably related to my hosting being on a Windows server.

Anyone know how to fix the error on a Windows box? Or is it easier to ask GoDaddy about changing my hosting from Windows to Linux?

Profile
 
 
Posted: 10 May 2008 01:00 PM   [ Ignore ]   [ # 2 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  562
Joined  01-13-2008

Is your local server windows or nix?

 Signature 

Yonti - Hosting Now Available - Site On it’s Way - CI Powered
Babblemap - Moved, Please Update RSS links. - Still using inkType

Profile
 
 
Posted: 10 May 2008 01:39 PM   [ Ignore ]   [ # 3 ]  
Grad Student
Rank
Total Posts:  61
Joined  10-04-2007

It’s Windows, running here off my laptop.

Profile
 
 
Posted: 10 May 2008 01:41 PM   [ Ignore ]   [ # 4 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  562
Joined  01-13-2008

PHP, Apache, MySQL versions on local and remote?

 Signature 

Yonti - Hosting Now Available - Site On it’s Way - CI Powered
Babblemap - Moved, Please Update RSS links. - Still using inkType

Profile
 
 
Posted: 10 May 2008 02:01 PM   [ Ignore ]   [ # 5 ]  
Grad Student
Rank
Total Posts:  61
Joined  10-04-2007

Local: PHP 5.2.5, Apache 2.0.59, MySQL 5.0.41.

Remote: PHP 5.2.5, MySQL 5.0.41.

Had a look on GoDaddy, and it seems it’s running IIS and not Apache. The version of IIS is 6.0.

Profile
 
 
Posted: 10 May 2008 02:03 PM   [ Ignore ]   [ # 6 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  562
Joined  01-13-2008

IIS may be your problem.

 Signature 

Yonti - Hosting Now Available - Site On it’s Way - CI Powered
Babblemap - Moved, Please Update RSS links. - Still using inkType

Profile
 
 
Posted: 10 May 2008 02:07 PM   [ Ignore ]   [ # 7 ]  
Grad Student
Rank
Total Posts:  61
Joined  10-04-2007

D’oh! Was afraid of that. You recommend getting in touch with GoDaddy and asking for a switch over to Linux?

Profile
 
 
Posted: 10 May 2008 06:29 PM   [ Ignore ]   [ # 8 ]  
Administrator
Avatar
RankRankRankRankRankRankRank
Total Posts:  14905
Joined  06-03-2002

GoDaddy’s not exactly a high quality host, so that in itself may be the problem.  CI should still work fine on IIS, and it shouldn’t be making to fclose() unless a valid resource was created.  Try removing the @ symbols from in front of the fopen() commands in is_really_writable() in Common.php, so any related errors aren’t being suppressed.  It sounds like fopen() is failing, but is not returning FALSE.  Maybe add a var_dump($fp) just after the fopen() too, so you can see exactly what was returned.

 Signature 
Profile
 
 
Posted: 11 May 2008 04:34 AM   [ Ignore ]   [ # 9 ]  
Grad Student
Rank
Total Posts:  61
Joined  10-04-2007

Thanks for the tip Derek, it’s certainly shown that there is more problems. After removing the @ symbols, these errors also appeared:

fopen() has been disabled for security reasons - codeigniter/Common.php (line 49)

fclose(): supplied argument is not a valid stream resource - codeigniter/Common.php (line 54)

chmod(): Unable to access d:\hosting\robbiedlaw\uploadr/system/cache/d645920e395fedad7bbbed0eca3fe2e0 - codeigniter/Common.php (line 55)

chmod(): No such file or directory - codeigniter/Common.php (line 55)

unlink(d:\hosting\robbiedlaw\uploadr/system/cache/d645920e395fedad7bbbed0eca3fe2e0): No such file or directory - codeigniter/Common.php (line 56)

Looks like GoDaddy block the use of fopen. What are the chances of them lifting that block for my hosting? I imagine unlikely. Does anyone have any recommendations on a new host I could move over to?

Profile
 
 
Posted: 11 May 2008 07:01 AM   [ Ignore ]   [ # 10 ]  
Grad Student
Rank
Total Posts:  61
Joined  10-04-2007

Another little update: GoDaddy just got back to me. They claim that 99% of PHP is disabled on their Windows hosting. No idea why. But they gave me instructions to switching my hosting over to Linux/Apache were there aren’t the daft PHP restrictions.

It apparently takes 24hrs for the switch to happen, so will let you know how it goes.

Profile
 
 
Posted: 11 May 2008 10:02 AM   [ Ignore ]   [ # 11 ]  
Administrator
Avatar
RankRankRankRankRankRankRank
Total Posts:  14905
Joined  06-03-2002

Heh, weird.  I’m not sure that I would even bother with a host that behaves like that, but obviously that’s personal opinion.  There are a number of people using CI on GoDaddy, though; I guess they are just using their Linux hosting.

 Signature 
Profile
 
 
Posted: 12 May 2008 03:02 AM   [ Ignore ]   [ # 12 ]  
Grad Student
Rank
Total Posts:  61
Joined  10-04-2007

Just got an email through that my hosting was switched to Linux, and everything seems to be working fine now. A few problems, like PATH_INFO not working but sticking a ? at the end of index.php fixed that.

Ridiculous situation GoDaddy have going over there, but at least it’s fixed for the time being. Thanks everyone for the help, really appreciate.

Profile
 
 
Posted: 19 July 2008 09:34 PM   [ Ignore ]   [ # 13 ]  
Summer Student
Total Posts:  13
Joined  04-03-2008

@RobbieL: Can you help me! I use CI 1.6.1 on Linux Godaddy hosting. But my website don’t works (see detail: http://codeigniter.com/forums/viewthread/85559/ ). Can you provide your php.ini configuration on hosting? Thanks very much!

Profile
 
 
   
 
 
Post Marker Legend
New Topic New posts Hot Topic Hot Topic with new posts New Poll New Poll Moved Topic Moved Topic Sticky Topic Sticky topic
Old Topic No new posts Hot Old Topic Hot Topic with no new posts Old Poll Old Poll Closed Topic Closed Topic Announcement Announcements
Theme
Change Theme
Visitor Statistics
The most visitors ever was 719, on June 06, 2008 10:16 AM
Total Registered Members: 60651 Total Logged-in Users: 37
Total Topics: 73045 Total Anonymous Users: 3
Total Replies: 393858 Total Guests: 410
Total Posts: 466903    
Members ( View Memberlist )