• Login
Community
  • Login

Plugin to let you preview BBcode?

Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
2 Posts 2 Posters 6.8k Views
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A
    Andrew Gregg
    last edited by Nov 20, 2016, 9:28 PM

    Long story short I need to do a lot of editing in bbcode for a site, the site though is notorious for breaking your post when you try to code.

    I’ve been trying to find a place to edit my code on a local program/app on my machine to prevent losing work on the forum, so I was wondering if there was any kinda plugin for notepad++ to preview inputed BBcode I was trying to use this http://fenixproductions.dcmembers.com/bbc/

    But its proven to be a pain in my ass and wont properly launch currently.

    1 Reply Last reply Reply Quote 0
    • P
      PeterJones
      last edited by Nov 21, 2016, 2:42 PM

      If it were me wanting to preview BBCode, I would use the Preview HTML plugin, which by default renders HTML… But it allows you to define a filter to run an external converter to convert from language “X” to HTML. Thus, I’ve got mine set up to convert Markdown and Perl’s POD documentation-markup to HTML.

      ; Content of Filters.ini file
      [Markdown]
      Extension=.md .markdown
      Language=Markdown
      Command=c:\perl\site\bin\multimarkdown.bat "%1"
      [PerlPOD]
      Extension=.pm .pod .pl
      Language=Perl
      Command=c:\perl\bin\pod2html_clean.bat -css=c:\perl\bin\pod2html.css "%1"
      

      If you can find a BBCode to HTML converter (I did a quick google, and saw some promising links, but I know nothing about it, so cannot evaluate the converters themselves). On my computer, I would probably grab a Perl module that does the conversion, like HTML::BBCode or Parse::BBCode , write a quick script to use the perl module to convert a BBCode file to HTML, and use that converter script up as the Command in a PreviewHTML Filter Definition:

      [BBCode]
      Extension=.bbcode .bbc
      Language=BBCode
      Command=c:\batch\bbcode2html.bat "%1"
      

      (One caveat on the Preview HTML plugin: the Notepad++ Installer seems to think it’s an “unstable” plugin, and disables it every time NPP upgrades. However, I have never seen Preview HTML crash NPP, so I don’t know why the installer claims that it is unstable. It might be one of those situations, discovered recently, where an earlier plugin in your plugin list gets incorrectly blamed for a later plugin’s crash, but I have no way of proving that. I just move the PreviewHTML.dll back into the main plugins directory from plugins\disabled after every upgrade.)

      1 Reply Last reply Reply Quote 0
      2 out of 2
      • First post
        2/2
        Last post
      The Community of users of the Notepad++ text editor.
      Powered by NodeBB | Contributors