Jump to content

[SOLVED] Please help! Strange Error- Variable passed to each() is not an array or object


Recommended Posts

Hi guys

 

My site has been running fine for ages and recently I upgraded to php 5.2.5 from 5.?

All seemed well however I had been getting some weird bugs with the httpd process previously as I had not properly updated to the new v5 php.ini so I changed over totally to using the new style php.ini as well.

 

Now, the errors from my logs have gone and i have instead new ones!!

 

PHP Warning:  Variable passed to each() is not an array or object in /mysite/forms/login_form.php http://www.mysite/index.php?auth_sess=agsdvonjbeuhferan8n1floef1&ref=b62d88222bcf557c311850a84

 

Basically I cannot login to my site using any of the login forms (either client backend or admin backend)

 

Can anyone please give me any assistance as to what the heck might be wrong?

 

Thanks  :)

You would need to post your code for anyone in a Forum to be able to help you with what it might be doing. There are several possible configuration settings and seeing your code would allow someone to determine what the problem is without it taking a lot of time and several guesses to find which setting your code is dependent on.

You would need to post your code for anyone in a Forum to be able to help you with what it might be doing. There are several possible configuration settings and seeing your code would allow someone to determine what the problem is without it taking a lot of time and several guesses to find which setting your code is dependent on.

 

Thanks for the input.

I have just managed found the problem and found it very weird because I thought this variable was already set in my php.ini as I had a similiar issue in the past, I compared my last config with the rpm.saved one and they were identical so Im not sure what happened to this setting?!!

 

For reference it was the "register_long_arrays" variable that was turned off....and unfortunately my sites base PHP code is a little archaic and doesnt use superglobals!! so that was the source of the problem..

 

Im currently having an all new site built from the ground up though, which naturally will use superglobals so then this setting will be back to Off!!

 

thanks again chaps.

I will put this particular thread to solved.

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.