Part of the EllisLab Network
   
 
CI 1.5.2 breaks form helper in PHP4
Posted: 16 March 2007 08:17 PM   [ Ignore ]  
Summer Student
Total Posts:  7
Joined  03-11-2007

I get this in my app after updating from 1.5.1
Fatal error: Cannot unset string offsets in W:\www\system\helpers\form_helper.php on line 201

Looking into it I found that Gallery had the same problem:
http://gallery.menalto.com/node/28992

I do not understand the nature of the change as I am not fluent in PHP5. Can anyone look into it?

Also, do look into my fix for the HTML Tables class in another thread below ^^

Profile
 
 
Posted: 18 March 2007 06:51 AM   [ Ignore ]   [ # 1 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  735
Joined  10-18-2006

It happens when the first param is a string. I think it also happens in PHP5
Solution is replacing that line for

if (is_array($data) && isset($data['value'])) unset ($data['value']); // textareas don't use the value attribute

 Signature 

Once in a while I remember I use Twitter

Profile
 
 
Posted: 18 March 2007 03:12 PM   [ Ignore ]   [ # 2 ]  
Summer Student
Total Posts:  7
Joined  03-11-2007

Yeah, forgot to mention that this error happens in PHP5 (and seemingly PHP5 only).

the fix works, thanks =)

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: 66414 Total Logged-in Users: 35
Total Topics: 84753 Total Anonymous Users: 1
Total Replies: 454835 Total Guests: 244
Total Posts: 539588    
Members ( View Memberlist )
Newest Members:  paulevansbyrooNirCalexmuellerkizerdrixcaptainredmuffquinodligtharttechsivamDjordje