0

I am having following errors on my website; I am very new to WordPress not able to track issue.

Warning: Illegal string offset 'type' in /home/content/p3pnexwpnas03_data02/52/2259652/html/wp-content/themes/softwarefails/lib/php/extra.class.php on line 32

Warning: Illegal string offset 'type' in /home/content/p3pnexwpnas03_data02/52/2259652/html/wp-content/themes/softwarefails/lib/php/extra.class.php on line 32

extra.class.php

Code in fiddle

Error is all over the website, I am not able to upload any images it gives following error.

An error occurred in the upload. Please try again later.
Jeff Lambert
  • 24,395
  • 4
  • 69
  • 96
  • 2
    you can't run php at jsfiddle, you could use an alternative that supports php, like ideone.com – JimL Oct 05 '14 at 15:33
  • @JimL I know that I have added code as it was too lengthy to add here. it was exceeding 30k stack limit. –  Oct 05 '14 at 15:37

2 Answers2

0

$inputs['type'] probably doesn't exist test first if it exist before doing a string compare

karthikr
  • 97,368
  • 26
  • 197
  • 188
Jelle Keizer
  • 723
  • 5
  • 9
0

This error is cause when you are trating the string as a full array. For eg

$fruit_counts = array('apples'=>2, 'oranges'=>5, 'pears'=>0);
echo $fruit_counts['oranges']; // echoes 5
$fruit_counts = "an unexpected string assignment";


echo $fruit_counts['oranges']; // causes illegal string offset error

Have a look here too

Community
  • 1
  • 1
Avinash Babu
  • 6,171
  • 3
  • 21
  • 26