Superlinks Problem

General discussion about Plugins for Cacti

Moderators: Developers, Moderators

User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Superlinks Problem

Post by Howie »

I'll take a look this weekend. Time and motivation have been low recently.
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
User avatar
mpdsville1
Cacti User
Posts: 71
Joined: Wed Mar 16, 2005 12:11 pm
Location: Albany , NY , USA

Re: Superlinks Problem

Post by mpdsville1 »

I understand
Mike Donnelly , Albany , NY
| Cacti 0.8.7g | Spine 0.8.7g | MySQL 5.0.77 | Net-SNMP 5.3.2.2 | Apache 2.2.3 | PHP 5.3.3 | RRDtool 1.2.27 | Rhel6 | Dual Xeon E5410@2.33ghz | Sunfire x4150
bodazyphir
Posts: 14
Joined: Fri May 16, 2008 4:43 am

Re: Superlinks Problem

Post by bodazyphir »

I have also tried the 2 fixes with no joy :( Not sure how to apply the CSS declaration

I am in exactly the same boat as mpdsville ......

Will monitor thread for an update .... :)
iDen
Posts: 16
Joined: Fri Nov 26, 2010 1:50 pm
Location: Tbilisi, Georgia

Re: Superlinks Problem

Post by iDen »

The second patch helped me. Both for chrome and IE
Before that IE9 showed broken iframe, and google chrome showed nothing at all (like in safari in post above)

Link to patch in this thread : http://forums.cacti.net/viewtopic.php?p=192416#p192416
Cacti/Spine 0.8.7h + Plugin Arch 3.0
Plugins: Monitor 1.3; Mactrack 2.9; Errorimage 0.2; Settings 0.71; Hmib 1.2; Boost 5.1; Discovery 1.3;
Weathermap 0.97a; Realtime 0.43; Rrdclean 0.41; Superlinks 1.3; Thold 0.4.7
Rig: CentOS 6.0 i386 2.6.32-131.12.1.el6.i686
php-5.3.3; net-snmp-5.5-31 ; rrdtool-1.3.8-6.el6.i686; httpd-2.2.15-9; mysql-5.1.52; php-gd/freetype enabled
bodazyphir
Posts: 14
Joined: Fri May 16, 2008 4:43 am

Re: Superlinks Problem

Post by bodazyphir »

Found the fix to this issue ...

For some reason it does not honour the 100% declaration here in superlinks.php

print '<iframe src="' . $page['contentfile'] . '" width="100%" height="100%" frameborder="0"></iframe>';

But works just fine if you specify pixels instead ......

print '<iframe src="' . $page['contentfile'] . '" width="100%" height="600px" frameborder="0"></iframe>';
User avatar
danno
Posts: 34
Joined: Wed Feb 16, 2005 2:35 pm
Location: Boca Raton, FL
Contact:

Re:

Post by danno »

venter wrote:I got the same problem with superlinks 0.8 and cacti 0.8.7g beta2.

I fixed that by adding following trick, just change
print '<iframe src="' . $page['contentfile'] . '" width="100%" height="100%" frameborder="0"></iframe>';
to
print '<iframe id="frame" src="' . $page['contentfile'] .'" width="100%" height="100%" frameborder="0"></iframe>';
print "<script type='text/javascript'>
function resizeIframe() {
var height=window.innerWidth;//Firefox
if (document.documentElement.clientHeight) {
height=document.documentElement.clientHeight;//IE
};
document.getElementById('frame').style.height=parseInt(height-document.getElementById('frame').offsetTop-72)+'px';
};
document.getElementById('frame').onload = resizeIframe;
window.onresize = resizeIframe;
</script>";
in superlinks.php
This worked for me for my issue with Chrome (virtually not showing at all) and IE9 (showing only a portion). This works for me on both whether configured as a tab or a console menu selection option.


So Thanks man! :)
User avatar
kramsay
Posts: 35
Joined: Fri Jan 21, 2005 1:42 pm

Re: Superlinks Problem

Post by kramsay »

PIA 2.9 & 0.87g Cacti

As stated modifying the height value fixed my issues on IE9, Firefox 4, and Google Chrome
print '<iframe src="' . $page['contentfile'] . '" width="100%" height="800px" frameborder="0"></iframe>';

I have however one more issue. All superlinks defined as a Console Menu work fine. However if I change the style of them to a Tab , then I get no Tab gif rendered , just the text in Firefox (not Chrome). However the link/broken graphic works fine and gives the target with no need to access or display the console menu which is what I want. (All other plugins render the Tabs fine ). Screenshots below

Console Menu works fine
Capture.JPG
Capture.JPG (85.96 KiB) Viewed 5260 times
Firefox 4 No Tab only text which works OK
Capture.JPG
Capture.JPG (25.62 KiB) Viewed 5260 times
Chrome No Text or Tab but hot spot still works
Capture.JPG
Capture.JPG (39.86 KiB) Viewed 5260 times
Appreciate some help.
=(8-0-)
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Re: Superlinks Problem

Post by phalek »

Hm,that either may be a permission issue as the apache user needs to be able to create these dynamically created images ( check the path of the tab image and check if your webserver can write there )

Or you're missing a php module (e.g. php-gd ) so it's not even trying to generate the images.
Greetings,
Phalek
---
Need more help ? Read the Cacti documentation or my new Cacti 1.x Book
Need on-site support ? Look here Cacti Workshop
Need professional Cacti support ? Look here CereusService
---
Plugins : CereusReporting
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Superlinks Problem

Post by Howie »

You should get a warning for both of those issues in the Superlinks management page, but it does sound like the files aren't being created... (look in plugins/superlinks/tab_images)
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
User avatar
kramsay
Posts: 35
Joined: Fri Jan 21, 2005 1:42 pm

Re: Superlinks Problem

Post by kramsay »

Wow! you guys are quick ! I also agree with your responses but haven't figured out yet what I am missing. Here's more info.

OK re
Hm,that either may be a permission issue as the apache user needs to be able to create these dynamically created images ( check the path of the tab image and check if your webserver can write there )

I have chmod'd -R 777 the complete plugins directory structure and chown -R cactiuser:apache but the httpd log is STILL complaining about non-existent gif files when I click a tab
error.JPG
error.JPG (74.15 KiB) Viewed 5253 times
Here's the content details of the target directory
dirlist.JPG
dirlist.JPG (106.85 KiB) Viewed 5253 times
For completness
Or you're missing a php module (e.g. php-gd ) so it's not even trying to generate the images.
rpms.JPG
rpms.JPG (35.99 KiB) Viewed 5253 times
=(8-0-)
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Re: Superlinks Problem

Post by phalek »

now that permissions and modules aren't the problem any more, you will need to re-create that "superlink" or change the name of it so the image gets re-created.

I don't think Howie made it create the images/tabs every time, but only when you create/update a link
Greetings,
Phalek
---
Need more help ? Read the Cacti documentation or my new Cacti 1.x Book
Need on-site support ? Look here Cacti Workshop
Need professional Cacti support ? Look here CereusService
---
Plugins : CereusReporting
User avatar
kramsay
Posts: 35
Joined: Fri Jan 21, 2005 1:42 pm

Re: Superlinks Problem

Post by kramsay »

Thank you phalek . That was the final issue. I recreated the link and all is now well. Thanks for the quick reply !
=(8-0-)
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Superlinks Problem

Post by Howie »

Yeah, some kind of 'regenerate all' button might be handy, eh?

Or at least something that tries to create the image if it doesn't exist, until it does exist.
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
User avatar
zoemu
Cacti User
Posts: 287
Joined: Fri Jul 10, 2009 1:38 pm
Location: Toronto, Canada

Re: Superlinks Problem

Post by zoemu »

bodazyphir wrote:Found the fix to this issue ...

For some reason it does not honour the 100% declaration here in superlinks.php

print '<iframe src="' . $page['contentfile'] . '" width="100%" height="100%" frameborder="0"></iframe>';

But works just fine if you specify pixels instead ......

print '<iframe src="' . $page['contentfile'] . '" width="100%" height="600px" frameborder="0"></iframe>';
this fixed it for me !!!!


Thanks
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Re: Superlinks Problem

Post by TheWitness »

The fix to this is located in:

svn://svn.cacti.net/cacti_plugins/superlinks/trunk

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests