예제 #1
0
                        @unlink("../media/tmp/" . $filename);
                    }
        }
        
        ?>
        <script type="text/javascript">
        window.open("./in_action_list.php","_self");
        </script>
        <?
    }
}else if(isset($_GET['delete'])&&isset($_GET['id'])){
    $action=$m_action->get_action_by_id($_GET['id'])->result;
    $photo=$m_action->get_all_action_photo($action[0]['id'])->result;
    foreach ($photo as $key => $value) {
       @unlink("../media/action/" . $value['filename']);
       $m_action->delete_action_photo($value['id']);
    }
    
    $m_action->delete_action($action[0]['id']);
    ?>
        <script type="text/javascript">
        window.open("./in_action_list.php","_self");
        </script>
        <?
}
?>
<style type="text/css">
.row-fluid .no-margin-left {
    margin-left: 0px;
}
.img_hold{
예제 #2
0
<?
require_once("../model/m_action.php");
$m_action = new M_action;
$edit=false;
$advisor=null;
$count=0;
if (isset($_POST['type'])&&$_POST['type']=="temp") {
	unlink("../media/tmp/".$_POST['file']);
}
if (isset($_POST['type'])&&$_POST['type']=="real") {
	unlink("../media/action/".$_POST['filename']);
	$m_action->delete_action_photo($_POST['id']);
}
require_once("../model/m_partner.php");
$m_partner = new M_partner;
if (isset($_POST['type'])&&$_POST['type']=="partner") {
	unlink("../media/partner/".$_POST['filename']);
	$m_partner->delete_partner($_POST['id']);
}
?>