Welcome Guest, Not a member yet? Register   Sign In
Help with variable
#2

[eluser]pbreit[/eluser]
Possibly $query->result() is empty? I not sure what you are trying to do. If you want the insert() to run for each cidade, you need to put it in the foreach loop. I suspect what is happening is that the result is empty so "$cidade = utf8_decode($rowcidade->id);" never happens and thus $cidade is not declared resulting in the NULL value in the insert().

To make your code easier to read on the forum, use the [ code ] [/ code ] tags.


Messages In This Thread
Help with variable - by El Forum - 11-28-2010, 08:18 PM
Help with variable - by El Forum - 11-28-2010, 10:44 PM



Theme © iAndrew 2016 - Forum software by © MyBB