Cacti (home)ForumsRepositoryDocumentation
Cacti: offical forums and support  

 FAQFAQ   SearchSearch   MemberlistMemberlist    RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in    


SuperLinks 0.3 released
Goto page 1, 2  Next
 
Post new topic   Reply to topic    Cacti Forum Index -> Plugin Announcements
Author Message
Howie
Cacti Guru User


Joined: 16 Sep 2004
Posts: 2248
Location: United Kingdom

PostPosted: Sat Sep 08, 2007 12:46 pm    Post subject: SuperLinks 0.3 released Reply with quote

This plugin is an extension of my Links plugin with some important new features:
* It supports ANY number of extra tabs
* It will dynamically create the Tab graphics as pages are created
* It has the same user-based access-control as Weathermap
* It allows you to add new links to the Console menu as well as tabs

http://wotsit.thingy.com/haj/cacti/superlinks-0.3.zip

(I'll sort out a proper webpage for it in the next few days)

0.2 adds one new feature (red tab for current page), and fixes one small glitch.

0.3 fixes a possible mysql, error messages in the console, and browser caching problems.

NOTE: You'll need to edit and then save each menu entry if you upgrade from 0.1 or 0.2 to 0.3, to force it to regenerate it's image files, because the filenames have changed.


Last edited by Howie on Mon Sep 17, 2007 5:45 pm; edited 3 times in total
Back to top
N3NCY
Cacti User


Joined: 22 Sep 2005
Posts: 242
Location: Landenberg, PA

PostPosted: Sat Sep 08, 2007 8:55 pm    Post subject: Reply with quote

Howie:
Awesome plugin, I intend to use it straight away!

I have two (2) bugs at this time:
<see attached image>

And one (1) feature request:
Autogenerate two (2) images please.
One in Blue like you have now.
and
One with a Red background that is used when I am on that tab.

Thank you!



SuperLinks-Bugs01.PNG
 Description:
 Filesize:  89.86 KB
 Viewed:  4071 Time(s)

SuperLinks-Bugs01.PNG


Back to top
Howie
Cacti Guru User


Joined: 16 Sep 2004
Posts: 2248
Location: United Kingdom

PostPosted: Sun Sep 09, 2007 4:41 am    Post subject: Reply with quote

N3NCY wrote:
Howie:
Awesome plugin, I intend to use it straight away!

I have two (2) bugs at this time:
<see attached image>

Hmm. The error message I thought I had fixed. It's an easy change though.

As for the image not updating - can you check if the tab_images/tab_4.png (or whichever page id it is - you can see in the URL) is being updated? and is owned by your www user? I found that I had to reload a couple of times sometimes before the new image was picked up. I guess this is just a browser caching issue.

N3NCY wrote:

And one (1) feature request:
Autogenerate two (2) images please.
One in Blue like you have now.
and
One with a Red background that is used when I am on that tab.


I actually have a red blank in the plugin already, but I didn't make this last step. I'll add it in.
Back to top
Howie
Cacti Guru User


Joined: 16 Sep 2004
Posts: 2248
Location: United Kingdom

PostPosted: Sun Sep 09, 2007 5:59 am    Post subject: Reply with quote

OK. Where else do you get overnight bugfixes on a sunday morning?

Link for 0.2 is in the top post which addresses both of your requests. I stil think the tab updating is just a caching issue.

You will need to click on edit, then save to generate the new red tabs for each page.
Back to top
N3NCY
Cacti User


Joined: 22 Sep 2005
Posts: 242
Location: Landenberg, PA

PostPosted: Sun Sep 09, 2007 9:58 am    Post subject: Reply with quote

This Sunday service rocks!



The image is being cached by my browser for some reason.
A simple CTRL+REFRESH of the page fixes the caching issue in IE7.
Bug #1 = Fixed with work around = CTRL+REFRESH or close / re-open browser.
Thank you Howie!


Feature Request #1 = Works great
The background of the selected tab is now red!
Thank you again Howie!


Bug #2 = Still persists
Follow these steps in IE7 to reproduce:
1.) Click "SuperLinks Pages" link from left side under the Console menu
2.) Click "Add" link from the uper right side of your screen
3.) Click "View" link on one of the possible choice under "Available SuperLinks Content Files"
4.) Error condition occurs = New tab in IE7 is opened and error message displayed
<see attached image>



SuperLinks-Bugs02.PNG
 Description:
 Filesize:  57.62 KB
 Viewed:  4034 Time(s)

SuperLinks-Bugs02.PNG


Back to top
Howie
Cacti Guru User


Joined: 16 Sep 2004
Posts: 2248
Location: United Kingdom

PostPosted: Sun Sep 09, 2007 10:24 am    Post subject: Reply with quote

That 'view' option shouldn't really be there - it's a hangover from the Weathermap code I used. It will go in the next version.

I'm going to try a new solution for the caching problem - if the filename changes each time there is an update, then caching won't be an issue. Just need to make sure it doesn't leave a trail of old images in the directory.
Back to top
browniebraun
Cacti User


Joined: 13 Jun 2006
Posts: 341
Location: Cologne, Germany

PostPosted: Sun Sep 09, 2007 3:13 pm    Post subject: Reply with quote

Hi Howie,

I've just taken a look to your new "superlinks" plugin (v0.2), but it doesn't work if MySQL strict mode is enabled. Therefore it's necessary to fix your table definition, so line 106 of setup.php should be changed from

Code:
imagecache varchar(60) NOT NULL,

to:

imagecache varchar(60) NOT NULL DEFAULT '',


Anyway, great work.

Best regards
-Andreas-


Last edited by browniebraun on Sun Sep 09, 2007 3:14 pm; edited 1 time in total
Back to top
browniebraun
Cacti User


Joined: 13 Jun 2006
Posts: 341
Location: Cologne, Germany

PostPosted: Sun Sep 09, 2007 3:13 pm    Post subject: Reply with quote

Back to top
browniebraun
Cacti User


Joined: 13 Jun 2006
Posts: 341
Location: Cologne, Germany

PostPosted: Sun Sep 09, 2007 3:15 pm    Post subject: Reply with quote

Ups, duplicate posting

The issue with caching should be circumnavigated by using auto generated names for the png files with every change of the name instead of tab_1, tab_2 ....

e.g.
tab_name = 'tab' . session_id() . rand() . '.png';

Best regards
-Andreas-
Back to top
Howie
Cacti Guru User


Joined: 16 Sep 2004
Posts: 2248
Location: United Kingdom

PostPosted: Sun Sep 09, 2007 3:47 pm    Post subject: Reply with quote

browniebraun wrote:
Ups, duplicate posting

The issue with caching should be circumnavigated by using auto generated names for the png files with every change of the name instead of tab_1, tab_2 ....

e.g.
tab_name = 'tab' . session_id() . rand() . '.png';

Best regards
-Andreas-


Yep - that's my plan.

I guess there'll be a 0.3 sometime soon too
Back to top
munozm



Joined: 08 Jul 2007
Posts: 11

PostPosted: Fri Sep 14, 2007 9:50 pm    Post subject: Reply with quote

I'm looking forward to using this. Oddly, when I enable this plugin through config.php I see the following error at the top of the web page:
Warning: reset() [function.reset]: Passed variable is not an array or object in /var/www/cacti/lib/functions.php on line 116

Warning: Variable passed to each() is not an array or object in /var/www/cacti/lib/functions.php on line 117

Any thoughts? Thanks.
Back to top
Howie
Cacti Guru User


Joined: 16 Sep 2004
Posts: 2248
Location: United Kingdom

PostPosted: Mon Sep 17, 2007 5:21 pm    Post subject: Reply with quote

munozm wrote:
I'm looking forward to using this. Oddly, when I enable this plugin through config.php I see the following error at the top of the web page:
Warning: reset() [function.reset]: Passed variable is not an array or object in /var/www/cacti/lib/functions.php on line 116

Warning: Variable passed to each() is not an array or object in /var/www/cacti/lib/functions.php on line 117

Any thoughts? Thanks.


I've fixed this in my dev copy now - not sure why it didn't happen on my test FreeBSD install before, but I've just reinstalled windows on my desktop, and then a fresh Cacti, and now I see it. As soon as I get the unique filename stuff done, I'll make that 0.3.
Back to top
Howie
Cacti Guru User


Joined: 16 Sep 2004
Posts: 2248
Location: United Kingdom

PostPosted: Mon Sep 17, 2007 5:46 pm    Post subject: Reply with quote

There.

0.3 is now available from the link in the original message.
Back to top
munozm



Joined: 08 Jul 2007
Posts: 11

PostPosted: Mon Sep 17, 2007 10:02 pm    Post subject: Reply with quote

Thanks for the update. I don't receive the original error messages anymore when working with this plugin. It seems to work except when I click add on one of the default content files, I get the following error message:

Fatal error: Call to undefined function imagecreatefrompng() in /var/www/cacti/plugins/superlinks/superlinks-mgmt.php on line 523

It creates text where the new tab icon would go and directs me to the proper page when I click on it.
I thought maybe it was related to permissions on the folders but I changed content/images/tab_images to 777 and tried the root user/group, cacti user/group, and the apache user/group all with the same error.
Back to top
apperrault
Cacti User


Joined: 16 Feb 2007
Posts: 359
Location: Emeryville, CA

PostPosted: Mon Sep 17, 2007 11:36 pm    Post subject: Reply with quote

This is great Howie. I already have some great ideas on how to use this.

Thanks much

app
Back to top
Display posts from previous:   
Post new topic   Reply to topic    Cacti Forum Index -> Plugin Announcements All times are GMT - 5 Hours
Goto page 1, 2  Next
Page 1 of 2

 



Powered by phpBB © 2001, 2005 phpBB Group