mirror of
https://github.com/rsyslog/loganalyzer.git
synced 2025-09-26 03:09:21 +02:00
Implemented custom google search button into sub-menus
This commit is contained in:
parent
3624d3e651
commit
7d4010b45d
@ -434,6 +434,8 @@ function InitFrontEndVariables()
|
||||
$content['MENU_BULLET_RED'] = $content['BASEPATH'] . "images/icons/bullet_ball_glass_red.png";
|
||||
$content['MENU_BULLET_YELLOW'] = $content['BASEPATH'] . "images/icons/bullet_ball_glass_yellow.png";
|
||||
$content['MENU_BULLET_GREY'] = $content['BASEPATH'] . "images/icons/bullet_ball_glass_grey.png";
|
||||
|
||||
$content['MENU_ICON_GOOGLE'] = $content['BASEPATH'] . "images/icons/googleicon.png";
|
||||
}
|
||||
|
||||
// Lang Helper for Strings with ONE variable
|
||||
|
@ -350,6 +350,11 @@ if ( isset($content['Sources'][$currentSourceID]) ) // && $content['Sources'][$c
|
||||
'DisplayName' => $content['LN_VIEW_SEARCHFOR'] . " " . $content['LN_FIELDS_FACILITY'] . " '" . GetFacilityDisplayName($logArray[$mycolkey]) . "'",
|
||||
'IconSource' => $content['MENU_NETWORK']
|
||||
);
|
||||
$content['syslogmessages'][$counter]['values'][$mycolkey]['buttons'][] = array(
|
||||
'ButtonUrl' => 'http://kb.monitorware.com/googlesearch.php?sa=Search&q=' . PrepareStringForSearch($content['LN_FIELDS_FACILITY']) . '+' . GetFacilityDisplayName($logArray[$mycolkey]),
|
||||
'DisplayName' => $content['LN_VIEW_SEARCHFORGOOGLE'] . " " . $content['LN_FIELDS_FACILITY'] . " '" . GetFacilityDisplayName($logArray[$mycolkey]) . "'",
|
||||
'IconSource' => $content['MENU_ICON_GOOGLE']
|
||||
);
|
||||
}
|
||||
else if ( $mycolkey == SYSLOG_SEVERITY )
|
||||
{
|
||||
@ -379,7 +384,11 @@ if ( isset($content['Sources'][$currentSourceID]) ) // && $content['Sources'][$c
|
||||
'DisplayName' => $content['LN_VIEW_SEARCHFOR'] . " " . $content['LN_FIELDS_SEVERITY'] . " '" . GetSeverityDisplayName($logArray[$mycolkey]) . "'",
|
||||
'IconSource' => $content['MENU_NETWORK']
|
||||
);
|
||||
|
||||
$content['syslogmessages'][$counter]['values'][$mycolkey]['buttons'][] = array(
|
||||
'ButtonUrl' => 'http://kb.monitorware.com/googlesearch.php?sa=Search&q=' . PrepareStringForSearch($content['LN_FIELDS_SEVERITY']) . '+' . GetSeverityDisplayName($logArray[$mycolkey]),
|
||||
'DisplayName' => $content['LN_VIEW_SEARCHFORGOOGLE'] . " " . $content['LN_FIELDS_SEVERITY'] . " '" . GetSeverityDisplayName($logArray[$mycolkey]) . "'",
|
||||
'IconSource' => $content['MENU_ICON_GOOGLE']
|
||||
);
|
||||
}
|
||||
else if ( $mycolkey == SYSLOG_MESSAGETYPE )
|
||||
{
|
||||
@ -420,6 +429,11 @@ if ( isset($content['Sources'][$currentSourceID]) ) // && $content['Sources'][$c
|
||||
'DisplayName' => $content['LN_VIEW_SEARCHFOR'] . " " . $content['LN_FIELDS_EVENTID'] . " '" . $logArray[$mycolkey] . "'",
|
||||
'IconSource' => $content['MENU_NETWORK']
|
||||
);
|
||||
$content['syslogmessages'][$counter]['values'][$mycolkey]['buttons'][] = array(
|
||||
'ButtonUrl' => 'http://kb.monitorware.com/googlesearch.php?sa=Search&q=' . PrepareStringForSearch($content['LN_FIELDS_EVENTID']) . '+' . $logArray[$mycolkey],
|
||||
'DisplayName' => $content['LN_VIEW_SEARCHFORGOOGLE'] . " " . $content['LN_FIELDS_EVENTID'] . " '" . $logArray[$mycolkey] . "'",
|
||||
'IconSource' => $content['MENU_ICON_GOOGLE']
|
||||
);
|
||||
}
|
||||
}
|
||||
else if ( $content['fields'][$mycolkey]['FieldType'] == FILTER_TYPE_STRING )
|
||||
@ -510,6 +524,11 @@ if ( isset($content['Sources'][$currentSourceID]) ) // && $content['Sources'][$c
|
||||
'DisplayName' => $content['LN_VIEW_SEARCHFOR'] . " " . $content['LN_FIELDS_SYSLOGTAG'] . " '" . $logArray[$mycolkey] . "'",
|
||||
'IconSource' => $content['MENU_NETWORK']
|
||||
);
|
||||
$content['syslogmessages'][$counter]['values'][$mycolkey]['buttons'][] = array(
|
||||
'ButtonUrl' => 'http://kb.monitorware.com/googlesearch.php?sa=Search&q=' . PrepareStringForSearch($content['LN_FIELDS_SYSLOGTAG']) . '+' . $logArray[$mycolkey],
|
||||
'DisplayName' => $content['LN_VIEW_SEARCHFORGOOGLE'] . " " . $content['LN_FIELDS_SYSLOGTAG'] . " '" . $logArray[$mycolkey] . "'",
|
||||
'IconSource' => $content['MENU_ICON_GOOGLE']
|
||||
);
|
||||
}
|
||||
else if ( $mycolkey == SYSLOG_HOST )
|
||||
{
|
||||
@ -536,6 +555,11 @@ if ( isset($content['Sources'][$currentSourceID]) ) // && $content['Sources'][$c
|
||||
'DisplayName' => $content['LN_VIEW_SEARCHFOR'] . " " . $content['LN_FIELDS_EVENTLOGTYPE'] . " '" . $logArray[$mycolkey] . "'",
|
||||
'IconSource' => $content['MENU_NETWORK']
|
||||
);
|
||||
$content['syslogmessages'][$counter]['values'][$mycolkey]['buttons'][] = array(
|
||||
'ButtonUrl' => 'http://kb.monitorware.com/googlesearch.php?sa=Search&q=' . PrepareStringForSearch($content['LN_FIELDS_EVENTLOGTYPE']) . '+' . $logArray[$mycolkey],
|
||||
'DisplayName' => $content['LN_VIEW_SEARCHFORGOOGLE'] . " " . $content['LN_FIELDS_EVENTLOGTYPE'] . " '" . $logArray[$mycolkey] . "'",
|
||||
'IconSource' => $content['MENU_ICON_GOOGLE']
|
||||
);
|
||||
}
|
||||
else if ( $mycolkey == SYSLOG_EVENT_SOURCE )
|
||||
{
|
||||
@ -551,6 +575,11 @@ if ( isset($content['Sources'][$currentSourceID]) ) // && $content['Sources'][$c
|
||||
'DisplayName' => $content['LN_VIEW_SEARCHFOR'] . " " . $content['LN_FIELDS_EVENTSOURCE'] . " '" . $logArray[$mycolkey] . "'",
|
||||
'IconSource' => $content['MENU_NETWORK']
|
||||
);
|
||||
$content['syslogmessages'][$counter]['values'][$mycolkey]['buttons'][] = array(
|
||||
'ButtonUrl' => 'http://kb.monitorware.com/googlesearch.php?sa=Search&q=' . PrepareStringForSearch($content['LN_FIELDS_EVENTSOURCE']) . '+' . $logArray[$mycolkey],
|
||||
'DisplayName' => $content['LN_VIEW_SEARCHFORGOOGLE'] . " " . $content['LN_FIELDS_EVENTSOURCE'] . " '" . $logArray[$mycolkey] . "'",
|
||||
'IconSource' => $content['MENU_ICON_GOOGLE']
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -63,6 +63,7 @@ $content['LN_SEARCH_PERFORMADVANCED'] = "Erweiterte Suche starten";
|
||||
$content['LN_VIEW_RELATEDMSG'] = "View related syslog messages";
|
||||
$content['LN_VIEW_FILTERFOR'] = "Filter message for ";
|
||||
$content['LN_VIEW_SEARCHFOR'] = "Search online for ";
|
||||
$content['LN_VIEW_SEARCHFORGOOGLE'] = "Search Google for ";
|
||||
|
||||
$content['LN_HIGHLIGHT'] = "Hightlight >>";
|
||||
$content['LN_HIGHLIGHT_OFF'] = "Hightlight <<";
|
||||
|
@ -64,6 +64,7 @@ $content['LN_VIEW_MESSAGECENTERED'] = "Back to unfiltered view with this message
|
||||
$content['LN_VIEW_RELATEDMSG'] = "View related syslog messages";
|
||||
$content['LN_VIEW_FILTERFOR'] = "Filter message for ";
|
||||
$content['LN_VIEW_SEARCHFOR'] = "Search online for ";
|
||||
$content['LN_VIEW_SEARCHFORGOOGLE'] = "Search Google for ";
|
||||
|
||||
$content['LN_HIGHLIGHT'] = "Hightlight >>";
|
||||
$content['LN_HIGHLIGHT_OFF'] = "Hightlight <<";
|
||||
|
Loading…
x
Reference in New Issue
Block a user