Invalid argument supplied in wpadverts-mal.php 471
-
My server is running php7.0 with the latest version of the Divi theme, and I’ve disabled most plugins except ithemes security and w3 Total Cache (and the ones used by wpadverts).
I’ve recently installed wpadverts and I’m still new to it, but I have created a number of categories and two locations (previous solution I saw said there was a problem when there were no categories/locations).
I’m trying to create my first ad on the site, but when I do so I’m seeing the following error:
Warning: Invalid argument supplied for foreach() in /<path to wordpress>/wp-content/plugins/wpadverts-mal/wpadverts-mal.php on line 471
===Snippet from that file===
function wpadverts_mal_form_load( $form ) {if( $form[“name”] != “advert” ) {
return $form;
}==> foreach($form[“field”] as $i => $field) {
=======Call Stack==========
# Time Memory Function Location
1 0.0002 366152 {main}( ) …/index.php:0
2 0.0003 366440 require( ‘/var/www/dailyadsonline.com/wordpress/wp-blog-header.php’ ) …/index.php:17
3 0.9927 13308848 require_once( ‘/var/www/dailyadsonline.com/wordpress/wp-includes/template-loader.php’ ) …/wp-blog-header.php:19
4 1.0343 13349936 include( ‘/var/www/dailyadsonline.com/wordpress/wp-content/themes/Divi/page.php’ ) …/template-loader.php:74
5 1.3251 13629040 the_content( ) …/page.php:45
6 1.3257 13629288 apply_filters( ) …/post-template.php:240
7 1.3257 13629688 WP_Hook->apply_filters( ) …/plugin.php:203
8 1.3267 13632416 do_shortcode( ) …/class-wp-hook.php:298
9 1.3268 13646984 preg_replace_callback ( ) …/shortcodes.php:223
10 1.3269 13647960 do_shortcode_tag( ) …/shortcodes.php:223
11 1.3269 13648432 ET_Builder_Element->_shortcode_callback( ) …/shortcodes.php:345
12 1.3277 13657104 ET_Builder_Section->shortcode_callback( ) …/class-et-builder-element.php:439
13 1.3278 13657904 do_shortcode( ) …/main-structure-elements.php:913
14 1.3279 13672296 preg_replace_callback ( ) …/shortcodes.php:223
15 1.3279 13673176 do_shortcode_tag( ) …/shortcodes.php:223
16 1.3279 13673648 ET_Builder_Element->_shortcode_callback( ) …/shortcodes.php:345
17 1.3289 13681928 ET_Builder_Row->shortcode_callback( ) …/class-et-builder-element.php:439
18 1.3290 13696312 do_shortcode( ) …/main-structure-elements.php:1954
19 1.3291 13710560 preg_replace_callback ( ) …/shortcodes.php:223
20 1.3291 13711336 do_shortcode_tag( ) …/shortcodes.php:223
21 1.3292 13711800 ET_Builder_Element->_shortcode_callback( ) …/shortcodes.php:345
22 1.3294 13713136 ET_Builder_Column->shortcode_callback( ) …/class-et-builder-element.php:439
23 1.3294 13713624 do_shortcode( ) …/main-structure-elements.php:2835
24 1.3300 13727760 preg_replace_callback ( ) …/shortcodes.php:223
25 1.3300 13728456 do_shortcode_tag( ) …/shortcodes.php:223
26 1.3300 13728928 ET_Builder_Element->_shortcode_callback( ) …/shortcodes.php:345
27 1.3304 13730312 do_shortcode( ) …/class-et-builder-element.php:423
28 1.3305 13744200 preg_replace_callback ( ) …/shortcodes.php:223
29 1.3305 13744816 do_shortcode_tag( ) …/shortcodes.php:223
30 1.3305 13744816 shortcode_adverts_add( ) …/shortcodes.php:345
31 1.3392 13748272 Adverts_Form->__construct( ) …/shortcodes.php:194
32 1.3392 13748272 Adverts_Form->load( ) …/class-form.php:28
33 1.3392 13748272 apply_filters( ) …/class-form.php:70
34 1.3392 13748672 WP_Hook->apply_filters( ) …/plugin.php:203
35 1.3392 13750576 wpadverts_mal_form_load( ) …/class-wp-hook.php:298============================
- The topic ‘Invalid argument supplied in wpadverts-mal.php 471’ is closed to new replies.