• Hi,

    I’ve developped my plugin, but I have this message on activation :
    The plugin generated 3 characters of unexpected output during activation. If you notice “headers already sent” messages, problems with syndication feeds or other issues, try deactivating or removing this plugin.

    On my website it works fine, but on another site it throws the Header alread sent error on login.

    My code is here : https://pastebin.com/m0PuY2iw
    I’ve DOUBLE and even TRIPLE checked that I don’t have caracters before or after <?php and ?>

    Can someone see my mistake ?

    I am also pleased to have any comment on my code’s quality (related to wordpress specific).

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • I’m guessing the issue is here
    add_action('admin_init', 'force_html_edit_add_custom_box');

    Comment out that line and see if you still get the message. If you don’t, then re-engineer.

    I don’t really understand what this plugin is accomplishing, so I can’t offer more advice on how you would re-engineer.

    Thread Starter magnetik

    (@magnetik)

    Thanks for your answer

    Hum, it was a UTF8 related issue. I converted it with Notepad++ in UTF8 but I had to conert it in “UTF8 (without BOM)”.
    Now I don’t have any notice.

    The aim of my plugin is to add a checkbox to disable WYSIWYG editing on every screen where you can edit a page or post.
    Indeed, I had to edit a page in HTML but other users keeps editing it with the WYSIWYG module and it was destroying my HTML.

    My code is working now, but I’m pleased to get any comments or common mistake of my code.

    Thanks for following up with the note about it being a UTF-8 issue. I had the same problem in my own plugin and was completely baffled. “UTF-8 (without BOM)” in Notepad++ was all it took.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘The plugin generated 3 characters of unexpected output & general question’ is closed to new replies.