Letter case question, pure cosmetical: "Ntpd"



  • Hi.

    I enabled the NTP graphing feature on a fresh 2.2 install (now running 2.2.1). I just checked the graph for the first time and see the following:

    Is there some way I can fix this to have the correct letter casing, "ntpd" or "NTP"? It's just a bit annoying. :o





  • I have never used any of the stuff in the post linked above and had no clue about doing it. Folks here talked me through the process and I got the change I wanted to a working but ugly state and a kind soul cleaned it up a bit and now it is part of the project.

    It isn't rocket science and you can probably figure it out and get it done in a few hours.



  • That is caused by calls to ucword() in /usr/local/www/status_rrd_graph.php
    The various options in the various tabs are mostly derived from the file names of RRD files, like "system-processor". A bit of replacing "-" with " :: " and then ucwords() results in "System :: Processor"

    But it also results in stuff like "Ntpd" and "Ovpns1".

    So the code could be made a bit smarter if you care enough. It needs to understand what are "ordinary words" that should be capitalized, and what are special strings that need special treatment.



  • Thanks for clearing that up, phil.davis. That answers my question just fine as I didn't find anything when doing case-sensitive searches. :)


Log in to reply