Page 1 of 1

Permanently Disable Mobile View

Posted: Tue Apr 13, 2021 12:25 am
by safuanmansor
Hi Support Team,

Recently we have upgrade the nagios from v5.4 to 5.7 and one of the new features discover was mobile view.
Unfortunately the client dashboard application is running android base operating system. The way it work is just by supplying the credential and full path of the dashboard that need to be display. "http://IPADDRESS/nagiosxi/includes/comp ... screen.php" No cursor, no touch screen, no scrolling to click any button/checkbox.

Disable redirection from the below link is not an option for this particular case.
https://support.nagios.com/kb/article/n ... e-873.html

Is there other way for us to stop the mobile redirection/ force it to go to normal desktop view instead.


Thanks,
Safuan

Re: Permanently Disable Mobile View

Posted: Tue Apr 13, 2021 1:28 pm
by dchurch
There isn't currently a way to disable redirection to the mobile interface for everyone, but there are some workarounds you could try:

Option 0
On your mobile browser, open the hamburger and select "Request Desktop Site"
Option 1
Open /usr/local/nagiosxi/html/includes/pageparts.inc.php and around line 144, replace

Code: Select all

        <?php } else { ?>
        var mobile_redirects_disabled = 0;
        <?php } ?>
with

Code: Select all

        <?php } else { ?>
        var mobile_redirects_disabled = 1;
        <?php } ?>
That should disable it from redirecting to mobile until the file is modified. The downside to this option is that you'll have to re-apply the patch whenever you upgrade Nagios XI.

Re: Permanently Disable Mobile View

Posted: Mon Apr 19, 2021 8:41 pm
by safuanmansor
Hi dchurch,

Gladly update that the workaround is working now.

Thank you.

Re: Permanently Disable Mobile View

Posted: Tue Apr 20, 2021 11:27 am
by dchurch
Glad to hear you resolved it! Locking thread.

If you have any additional issues, feel free to make a new thread.