XenForo
Administrative
		- Thread starter
 - Admin
 - #1
 
I've the following code in my addon's controller
PHP:
	
	
	
		
Though the chances...
Read more
ادامه مطلب...
				
			PHP:
		Code:
	
	$finder = \XF::finder('Asprin\FB:Foo')->where('sys_id', 123); // can return multiple rows
$foos = $finder->fetch();
if($finder->total() > 0)
{
    foreach($foos as $foo)
    {
        $foo->delete();
    }
}
$finder2 = \XF::finder('Asprin\FB:Bar')->where('sys_id', 456); // can return multiple rows
$bars = $finder2->fetch();
if($finder2->total() > 0)
{
    foreach($bars as $bar)
    {
        $bar->delete();
    }
}
	Though the chances...
Read more
ادامه مطلب...