“Warning: Invalid argument….”
-
Suddenly getting this error on some pages of client’s site:
Warning: Invalid argument supplied for foreach() in /home/65/91/2909165/web/wp-content/themes/make/inc/builder/setup.php on line 95Here is the code in that area:
public function read_layout( $sections, $post_id ) { $layout = get_post_meta( $post_id, '_ttfmake_layout', true ); if ( ! empty( $layout ) ) { $layout = maybe_unserialize( $layout ); $sections = array(); foreach ( $layout as $section_id ) { $section = get_post_meta( $post_id, "_ttfmake_section_{$section_id}", true ); $section = maybe_unserialize( $section ); $sections[] = $section; } } return $sections; }
This is what is on line 95:
foreach ( $layout as $section_id ) {
Thanks in advance
The page I need help with: [log in to see the link]
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘“Warning: Invalid argument….”’ is closed to new replies.