Adding a Weathermaps Editor Link to the Console

Support questions about the Network Weather Map plugin

Moderators: Developers, Moderators

Post Reply
warnesj
Cacti User
Posts: 173
Joined: Sun May 29, 2005 7:34 pm

Adding a Weathermaps Editor Link to the Console

Post by warnesj »

Hi all. I spent just a few minutes and added a bit of code to add a Weathermaps Editor link to the Weathermaps section of the Console. Thought other's might find it useful.

Open ./plugins/weathermap/weathermap-cacti-plugin-mgmt.php, find

Code: Select all

    if($i==0)
    {
        print "<tr><td><em>No Weathermaps Configured</em></td></tr>\n";
    }

    html_end_box();
And add this bit of code after that,

Code: Select all

    print '<br />';
    html_start_box("<center><strong><a class=\"linkOverDark\" href=\"editor.php\" target=\"_blank\">Weathermaps Editor</a></strong></center>", "78%", $colors["header"], "2", "center");
    html_end_box();
Once that's done you should have a new link in your Weathermaps section of the Console that says Weathermaps Editor and when it's clicked your editor should launch.
Image
Mika2006
Cacti User
Posts: 178
Joined: Thu May 03, 2007 2:25 am

Post by Mika2006 »

i will try
|Cacti Version - 0.8.6j||Plugin Architecture - 1.1||Poller Type - CMD.php|
|os - Red hat 4es | |Web Server - Apache/2.0.52 (Red Hat)|
|PHP - 4.3.9| |MySQL - 4.1.20| |RRDTool - 1.2.13||SNMP - 5.1.2|
|Plugins| Host Info (hostinfo - v0.1)
cksrealm
Cacti User
Posts: 140
Joined: Sun May 08, 2005 5:45 pm
Location: Sydney,Australia
Contact:

Post by cksrealm »

Added the code and its seems to work great , thanks very much
p2im0
Posts: 1
Joined: Tue Jul 31, 2007 9:40 am

Post by p2im0 »

I just tried this out and received the error noted in the screenshot.

I then edited the above line to contain an empty variable 6. Here's what it looks like after, the only change is the added: , ""
Just in case anyone else has the issue.

Code: Select all

####
####  Code to add WEATHERMAP EDITOR TO PAGE!
####

print '<br />';
    html_start_box("<center><strong><a class=\"linkOverDark\" href=\"editor.php\" target=\"_blank\">Weathermaps Editor</a></strong></center>", "78%", $colors["header"], "2", "center", "");
    html_end_box();

####
####  END WEATHERMAP EDITOR Code
####
Attachments
error.jpg
error.jpg (47.74 KiB) Viewed 4977 times
User avatar
streaker69
Cacti Pro User
Posts: 712
Joined: Mon Mar 27, 2006 10:35 am
Location: Psychic Amish Network Administrator

Post by streaker69 »

If you upgrade to the lastest version of Weathermap, Howie has integrated the editor in a different way. You can select each map directly from the menu and go directly to the editor with that map loading right away.
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Post by Howie »

streaker69 wrote:If you upgrade to the lastest version of Weathermap, Howie has integrated the editor in a different way. You can select each map directly from the menu and go directly to the editor with that map loading right away.
That's the SVN version, rather than a release. I wouldn't recommend just using the whole of the SVN version because the RRD datasource is brand-new untested code :o . The editor parts (editor*) are OK though.

I'll also being adding a link to the editor too, so you can create new maps from there too, as suggested, before 0.93. I'd like to think that 0.93 will be out in a week or two - I'm hoping to work on it a little during linuxworld next week.
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
streaker69
Cacti Pro User
Posts: 712
Joined: Mon Mar 27, 2006 10:35 am
Location: Psychic Amish Network Administrator

Post by streaker69 »

Howie wrote:
streaker69 wrote:If you upgrade to the lastest version of Weathermap, Howie has integrated the editor in a different way. You can select each map directly from the menu and go directly to the editor with that map loading right away.
That's the SVN version, rather than a release. I wouldn't recommend just using the whole of the SVN version because the RRD datasource is brand-new untested code :o . The editor parts (editor*) are OK though.

I'll also being adding a link to the editor too, so you can create new maps from there too, as suggested, before 0.93. I'd like to think that 0.93 will be out in a week or two - I'm hoping to work on it a little during linuxworld next week.
Oh, I've been testing the SVN for you then. So far, I haven't seen any issues.
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests