forked from modxcms/evolution
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsysalert.display.inc.php
More file actions
executable file
·46 lines (41 loc) · 1.12 KB
/
Copy pathsysalert.display.inc.php
File metadata and controls
executable file
·46 lines (41 loc) · 1.12 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<?php
/**
* System Alert Message Queue Display file
* Written By Raymond Irving, April, 2005
*
* Used to display system alert messages inside the browser
*
*/
require_once(dirname(__FILE__).'/protect.inc.php');
$sysMsgs = "";
$limit = count($SystemAlertMsgQueque);
for($i=0;$i<$limit;$i++) {
$sysMsgs .= $SystemAlertMsgQueque[$i]."<hr sys/>";
}
// reset message queque
unset($_SESSION['SystemAlertMsgQueque']);
$_SESSION['SystemAlertMsgQueque'] = array();
$SystemAlertMsgQueque = &$_SESSION['SystemAlertMsgQueque'];
if($sysMsgs!="") {
?>
<?php // fetch the styles
echo '<link rel="stylesheet" type="text/css" href="'.$modx->config['base_url'].'manager/media/style/'.$manager_theme.'/style.css'.'" />';
?>
<script type="text/javascript">
// <![CDATA[
window.addEvent('domready', function() {
var sysAlert = new Element('div').setProperties({
'class': 'sysAlert'
});
sysAlert.innerHTML = '<?php echo $modx->db->escape($sysMsgs);?>';
var boxHtml = new MooPrompt('<?php echo $_lang['sys_alert']; ?>', sysAlert, {
buttons: 1,
button1: 'Ok',
width: 500
});
});
// ]]>
</script>
<?php
}
?>