Skip to content

Commit 4017be7

Browse files
committed
Resolving Issue #27
Deprecated functions and legacy path causing issues with schedules
1 parent 738768e commit 4017be7

4 files changed

Lines changed: 5 additions & 4 deletions

File tree

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ Got any ideas or complaints, please see the Cacti forums or GitHub for a resolut
4444

4545
--- develop ---
4646

47+
* issue#27: Deprecated functions and legacy path causing issues with schedules
4748
* issue#28: Flowview filters not searchable using some international characters
4849

4950
--- 2.1 ---

flowview_devices.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,7 @@ function actions_devices () {
219219
$i = 0;
220220

221221
/* loop through each of the devices selected on the previous page and get more info about them */
222-
while (list($var,$val) = each($_POST)) {
222+
foreach($_POST as $var => $val) {
223223
if (preg_match('/^chk_([0-9]+)$/', $var, $matches)) {
224224
/* ================= input validation ================= */
225225
input_validate_input_number($matches[1]);

flowview_schedules.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ function actions_schedules () {
163163
$schedule_list = '';
164164

165165
/* loop through each of the devices selected on the previous page and get more info about them */
166-
while (list($var,$val) = each($_POST)) {
166+
foreach($_POST as $var => $val) {
167167
if (preg_match('/^chk_([0-9]+)$/', $var, $matches)) {
168168
/* ================= input validation ================= */
169169
input_validate_input_number($matches[1]);

functions.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ function flowview_display_report() {
247247
is: function(s) {
248248
return false;
249249
},
250-
250+
251251
format: function(s) {
252252
if (s.indexOf('MB') > 0) {
253253
loc=s.indexOf('MB');
@@ -361,7 +361,7 @@ function plugin_flowview_run_schedule($id) {
361361

362362
$message = "<body style='margin:10px;'>";
363363
$message .= "<style type='text/css'>\n";
364-
$message .= file_get_contents($config['base_path'] . '/include/main.css');
364+
$message .= file_get_contents($config['base_path'] . '/include/themes/modern/main.css');
365365
$message .= '</style>';
366366
$sessionid = -1;
367367
$message .= createfilter($sessionid);

0 commit comments

Comments
 (0)