Jump to content

Template Notes


Soma
 Share

Recommended Posts

Template Notes

Adds a "Help" tab to pages for notes and instructions on the current template used.
 
You can add content by simply putting a html or markdown file in /site/templates/notes/ the module will automatically load that file if it finds one and adds a "Help" tab to the page edit form.
 
post-100-0-09431500-1385408350_thumb.png
 
Name the files using the template name. You can use html or markdown to write the help text.
 
- /site/templates/notes/[tplname].html
- /site/templates/notes/[tplname].md
 
To style the content you can specify a custom css file url you add to the module settings.
 
This module was quickly written after seeing a wish-list request by Joss http://processwire.com/talk/topic/5016-help-tab-for-template/
  • Like 22
Link to comment
Share on other sites

Nice one Soma.

I was thinking of a more complicated solution earlier, so +1 for keeping it simple and effective as these notes only need to be written once per template by the person building the site really :)

  • Like 1
Link to comment
Share on other sites

  • 4 weeks later...
  • 4 months later...
  • 4 months later...
  • 1 year later...
  • 1 month later...
On 22.09.2016 at 7:33 PM, Lance O. said:

Is this module compatible with PW 3.x? I just installed it but the Help tab isn't displaying for the designated template.

I changed 2 lines in site/modules/TemplateNotes/TemplateNotes.module (starts at line 98)

        if(ProcessWire::versionMajor == 2 && ProcessWire::versionMinor <= 4)
            $form->append($tab);

        if(ProcessWire::versionMajor >= 2 && ProcessWire::versionMinor >= 5)
            $form->prepend($tab);

to

        if(ProcessWire::versionMajor == 3 && ProcessWire::versionMinor <= 4)
            $form->append($tab);

        if(ProcessWire::versionMajor >= 3 && ProcessWire::versionMinor >= 5)
            $form->prepend($tab);

Seems to be working on 3.0.40. Only glitch is the bottom Save button jumps above notes content.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...