Do return true; continue the script till end in the same function?
<p>My function goes something like this</p>

<pre><code>function multiple_delete($checkbox, $table, $url, $picture1 = 0, $picture2 = 0, $picture3 = 0){
    $count = count($checkbox);
for($j=0;$j&lt;$count;$j++)
    {
    $delete_id = $checkbox[$j];
    $query = "SELECT * FROM $table WHERE id = '$delete_id'";
    $result = mysql_query($query);
    $row = mysql_fetch_array($result);
    return true;

if( $picture1 !== 0 &amp;&amp; $picture2 !== 0 &amp;&amp; $picture3 !== 0) 
    {
    $pic_1 = $picture1;
    $pic_2 = $picture2;
    $pic_3 = $picture3;
    unlink($pic_1);
    unlink($pic_2);
    unlink($pic_3);
    return true;
    }
if( $picture1 !== 0 &amp;&amp; $picture2 !== 0 &amp;&amp; $picture3 == 0 ) 
    {
    $pic_1 = $picture1;
    $pic_2 = $picture2;
    unlink($pic_1);
    unlink($pic_2); 
    return true;  
    }
    }

    for($i=0;$i&lt;$count;$i++)   {
    $del_id = $checkbox[$i];
    $sql = "DELETE FROM $table WHERE id='$del_id'";
    $result_delete_data = mysql_query($sql);
    }
    alert('Deleted Successfully');
    redirect_url($url);
    return true;
    }
</code></pre>

<p>In the above function if the first or second condition returns true, then will it continue over the for loop below or it will simply halt the script ? </p>

<p>If return true will halt the script then</p>

<p>EDIT: Is it ok if I remove the return statement from the if conditions? And is it necessary for us to define the return statement in a user defined function? </p>
