MAIL ERROR: Warning: Invalid argument supplied for foreach()

The place to talk about things that are related to CMS Made simple, but don't fit anywhere else.
Post Reply
placeshifter
New Member
New Member
Posts: 4
Joined: Sun Oct 28, 2012 11:24 am

MAIL ERROR: Warning: Invalid argument supplied for foreach()

Post by placeshifter »

After migrating my web site to a new server using a flex image, I'm getting the following error on submission of a contact form:

Warning: Invalid argument supplied for foreach() in /home/website/public_html/lib/classes/class.Events.php on line 174

Can you tell me what the problem might be and how I can resolve this?

I changed my CMS Mail settings from SMTP to Sendmail and it has resolved it for now.

Just wondering why the SMTP submission was causing the error and how to correct it.
catchlight
Forum Members
Forum Members
Posts: 20
Joined: Wed Jan 28, 2009 1:12 am

Re: MAIL ERROR: Warning: Invalid argument supplied for forea

Post by catchlight »

I got this message all over my site after upgrading to 1.10 from 1.11.8 changing stuff in the CMS mailer settings didn't correct anything for me, so I'm not sure if your issue has anything to do with CMS Mailer.
User avatar
Rolf
Power Poster
Power Poster
Posts: 7825
Joined: Wed Apr 23, 2008 7:53 am
Contact:

Re: MAIL ERROR: Warning: Invalid argument supplied for forea

Post by Rolf »

System information?
- + - + - + - + - + - + -
LATEST TUTORIAL AT CMS CAN BE SIMPLE:
Migrating Company Directory module to LISE
- + - + - + - + - + - + -
Image
catchlight
Forum Members
Forum Members
Posts: 20
Joined: Wed Jan 28, 2009 1:12 am

Re: MAIL ERROR: Warning: Invalid argument supplied for forea

Post by catchlight »

If I can hi-jack this post - hopefully this might help us all anyway.

Cms Version: 1.11.8
Installed Modules:
FCKeditorX: 1.0.1
MenuManager: 1.8.6
Printing: 1.1.1
TinyMCE: 2.8.0
Search: 1.7.10
News: 2.13
FileManager: 1.4.3

Config Information:
php_memory_limit:
process_whole_template:
max_upload_size: 2000000
url_rewriting: internal
page_extension:
query_var: page
image_manipulation_prog: GD
auto_alias_content: true
locale:
default_encoding: utf-8
admin_encoding: utf-8
set_names: false

Php Information:
phpversion: 5.3.27
md5_function: On (True)
gd_version: 2
tempnam_function: On (True)
magic_quotes_runtime: Off (False)
E_STRICT: 0
E_DEPRECATED: 0
memory_limit: 32M
max_execution_time: 30
output_buffering: On
safe_mode: Off (False)
file_uploads: On (True)
post_max_size: 8M
upload_max_filesize: 2M
session_save_path: /tmp (1777)
session_use_cookies: On (True)
xml_function: On (True)
xmlreader_class: On (True)

Server Information:
Server Api: cgi-fcgi
Server Db Type: MySQL (mysql)
Server Db Version: 5.5.32
Server Db Grants: Found a "GRANT ALL" statement that appears to be suitable
Server Time Diff: No filesystem time difference found
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm

Re: MAIL ERROR: Warning: Invalid argument supplied for forea

Post by calguy1000 »

this error is caused by a query that returns no results. meaning you have no event handlers anywhere, for anything.

Adding an event handler for something will make the notice go away.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Post Reply

Return to “The Lounge”