【发布时间】:2013-04-09 05:49:30
【问题描述】:
我正在使用 codeigniter,在其中一个视图中,当数据库中不存在员工代码时,我触发了以下函数(使用 jquery ajax - 工作正常)。当输入的代码无效但确认结果为真时显示确认弹出窗口,以下代码不会触发弹出窗口!
function popup(){
if(confirm("Employee_code not available! \nSave the code as new employee?")){
//var new_emp_window = "<?php echo base_url().'index.php/it_inventory/new_employee'; ?>";
widnow.open('www.google.com', 'width=500, height=500');
}else{
alert("ohh!");
$('#employee_code').val('').focus();
}
}
【问题讨论】:
标签: javascript codeigniter confirm popupwindow