Notepad widget - keep the line-breaks!

In the dashboard, Notepad widget, why is it that when I enter this poetry-like beauty…


it transforms into this garbled mess?


Jokes aside - I think this prevents using the widget for the basic Documentation of an installation, which is a serious limitation - and totally unnecessary.

I do some work on FreePBX installations that get visits by other people doing configuration. It’s really important that I can leave them messages on the first page, with warnings and basic orientation.

Can this be fixed, please? I would really appreciate that work, and I hope it is not a lot.

What browser are you using ?

Just for laughs, I tried Chrome, Firefox, and Edge; all failed to preserve line breaks.

sounds like a php thing then, bug report?

Assuming a bug report is different from a Feature request, would this be the correct place to file it?

it seems pretty dead… 0 issues created in the past 60 days? :thinking:

This feature was a community contribution from @miken32, maybe he has a suggestion on how to support this.

PR submitted featuring the ancient PHP function nl2br.

It caused my dashboard to start displaying 1960s TV program lyrics:



Thank you Bill! This is the beauty of open-source communities.

I tested it and it works. I get a security warning saying I tampered with my file (nice police work!). Is there any way to turn it off, to tell FreePBX “don’t worry, I know about the tampered file”?

Once the PR from @billsimon (thanks!) is accepted and you update the module, the warning will go away. You can’t turn it off on a per-file basis, so best practice (if you want the feature without waiting for an update) is to put up with the warning, ensuring periodically that it only applies to that one file.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.