WordPress.org

Ready to get started?Download WordPress

Forums

Price Table
Receiving foreach () error (4 posts)

  1. webgirl
    Member
    Posted 3 years ago #

    Warning: Invalid argument supplied for foreach() in /plugins/pricetable/pricetable.phtml on line 12

    http://wordpress.org/extend/plugins/pricetable/

  2. webgirl
    Member
    Posted 3 years ago #

    Fixed myself. Changed line 12 from

    foreach($column['features'] as $j => $feature) :
    
    to
    foreach ( (array)$column['features'] as $j => $feature) :
  3. Greg Priday
    Member
    Plugin Author

    Posted 3 years ago #

    Your way of fixing this issue is much neater than mine. I'll push the update now. Thanks!

  4. mrplan5
    Member
    Posted 3 years ago #

    I just migrated over a site from one URL to another. No issues except with your plugin. here is the foreach() error. I tried using the above fix but it will only fix the "warning" and not the "fatal error:"

    Warning: Invalid argument supplied for foreach() in /plugins/pricetable/pricetable.php on line 214

    Fatal error: Cannot use string offset as an array in /plugins/pricetable/pricetable.php on line 222

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags