howardjones / network-weathermap

Network Weathermap draws diagrams from data
http://www.network-weathermap.com/
MIT License
426 stars 94 forks source link

^M characters on conf files @web-editor #50

Closed jpobeda closed 7 years ago

jpobeda commented 7 years ago

Sometimes when I edit hosts from the web editor and have a look at the conf file from the linux shell I see that the host I've just edited got all this ^M characters. The directive I've added to the original conf on this case was the "LABELFONT 99". I waited for a polling interval to see if weathermap fixes it after updating the map but It doesn't.

BTW I noticed this on 0.98 as well as the database-refactor branch.

NODE timelabel_London^M TEMPLATE tz^M LABEL {node:this:time_time24}^M TARGET time:Europe/London^M LABELFONT 99^M POSITION 270 118^M ^M

howardjones commented 7 years ago

Weathermap doesn't rewrite the configuration file during a polling cycle.

Which browser/OS are you using the editor on? And which OS is the software installed on? Seems like it's something that the browser is doing conversions when it shouldn't...

jpobeda commented 7 years ago

I normally use Google Chrome, and the server is a Centos 6. I'll try ff as well and let you know.

howardjones commented 7 years ago

Chrome on Windows, or something else? (^M is usually a sign of DOS-ish stuff somewhere)

jpobeda commented 7 years ago

Yes, Chrome@Windows 10. FireFox@Windows 10 does the same and even worst because when I edit the host it shows me the config dialog box on a single line.

jpobeda commented 7 years ago

firefox_w10_weditor

howardjones commented 7 years ago

I think yesterday's commit has fixed this now.

jpobeda commented 7 years ago

Just tested it. It works.