Need help PLEASE


Posted on 16th Feb 2014 07:03 pm by admin

ok i have this warning showing up

Warning: in_array() [function.in-array]: Wrong datatype for second argument in /home/lalala/public_html/attack.php on line 72

the code i use
Code: [Select]//same ip resrictions
$result = mysql_query("SELECT ip FROM ip_history WHERE user_id='$target[id]'");


while($row = mysql_fetch_array($result))
{
$sendtouser[]=$row['ip'];
}


$result = mysql_query("SELECT ip FROM ip_history WHERE user_id='$logged[id]'");

reconnect();

while($row = mysql_fetch_array($result))
{
if(in_array($row['ip'], $sendtouser))
{
show_error("You cannot attack a user with the same IP.");
break;
}
}
basically what i can gather is there is no ip for the user being attacked
i want to know how to stop this error tomming up if the $target[id] user has no ip in ip history any solution or fix to this would be greatly appreciated

No comments posted yet

Your Answer:

Login to answer
266 Like 45 Dislike
Previous forums Next forums
Other forums

socket communication between c++/java and sending image
hi,

i have a class in c++ called win32_sockserver which creates socket to java. i am trying

Setting condidtions for an input box
Hi all,

I would like to set a condition in a txt box that says the number a user enters has t

Why doesn't this work? (SSH2)
This is my script:

Code: <?php
$connection = ssh2_connect('213.251.167.109', 22);

Loop Through Date Range
Hi guys,
I have date range as parameter like 01/JAN/2009 TO 16/JAN/2009 now i want to loop thro

Slashes
Have a small problem and I'm not able to understand why I'm getting the results I'm getting... and i

PHP referral database. I would like this form to email the referrer.
Okay, Hello I've been trolling for years. This the first time I've ever asked for php help. Normally

Please help - should be a simple fix.. driving me nuts
Everything seemed to be working fine. I have a table, it alphabetically lists a bunch of cities and

Need some ideas as to how to go about sorting this array...
Here's how the array's are created..

Code: <?php
while ($x = readdir($dp)) {

how to easy edit text, with box? Help.
Hi.
I have a little problem. I'm doing a webpage for my aunt and I would like to make it as easy

Passing vars to the DB
I have 3 small testing tables:

ID TYPE
1 pepperoni
2 C. bacon
3 taco

ID TY

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash