Customization of CSS & add logo

The forum for help and support with FreeNATS as well as any useful hints and tips
Post Reply
Posts: 5
Joined: Wed Dec 15, 2010 10:30 pm

Customization of CSS & add logo

Post by duckdive99 » Wed Dec 15, 2010 10:58 pm

First, let me say that FreeNATS is very cool. I like that it is simple and web based.

I'm currently using the VM to test. I've looked at the main.css and some .php files because I'd like customize the layout a little.

I find that the Live Monitor page doesn't show the name with enough detail (really only about 3-6 characters with a couple of trailing ..). This doesn't help much when the names are similar. I was looking at the css to determine how to change that text, but I'm not the best with css. Anyone have a line number to the correct tag to change to get that to show the entire name.

Also, I think it would be nice to be able to add a name/logo the FreeNATS system (maybe even add a NOC contact info area). I do not want to remove any FreeNATS/PurplePixie info. Rather, I'd like the users to know who manages the system in case they are viewing and an escalation is required.


Site Admin
Posts: 260
Joined: Fri May 30, 2008 9:09 pm
Location: UK

Re: Customization of CSS & add logo

Post by dave » Thu Dec 16, 2010 10:14 am

Hi John,

I'm glad you're finding the system useful.

Unfortunately the live monitor length/description is in PHP code. You can easily change it but it will get overwritten should you ever update the software.

The exact line number depends on your version but the function you are looking for is called np_tiny and is in the file server/base/

In version 1.09.2b (current stable) it starts at 412 (CX for in 1.09.2b) and in 1.10.2a (current alpha) starts at line 491 (CX for in 1.10.2a).

The specific lines you're looking for are:
  • max_on_line=X (#429 in 1.09.2b or #509 in 1.10.2a) - this is the number of letters appearing on each line of the name
    max_lines=Y (#430 in 1.09.2b or #510 in 1.10.2a) - this is the number of lines
If you just up max_on_line it should display what you're after.

For this though and for branding you may want to just consider a view (view documentation). Views can be embedded into web pages so you can easily put your own branding around a live monitor with full node names shown. An example view of active nodes in 3 columns with their icons shown (not embedded into a page just in the FreeNATS setup) with a NOC strap line would be like:


(here is an example of a view embedded into a branded page)

With regard to your branding question - are you talking just about the monitor or the entire system? If it's just the monitor then I can easily do you a little plug-in that would be very easy to customise. Unfortunately as the system kind of sprawled from a simple beginning there is no native skin/branding system that can be used.

If it's the entire system though I may be able to put something in place to allow you to configure a specific skin but it would be quite limited just to the header/footer/CSS of the system.

Oh and of course FreeNATS is entirely free so you never need to worry about keeping any sort of FreeNATS branding visible - you are free to do what you want (the only restrictions apply if you then provide the system to someone else).

Hope that helps.

So just let me know if you want either a customisable monitor page or me to look into the ability to add change the general look+feel.



Post Reply