Tags:
create new tag
, view all tags

CommonHeaderFooterPluginDev Discussion: Page for developer collaboration, enhancement requests, patches and improved versions on CommonHeaderFooterPlugin contributed by the TWikiCommunity.
• Please let us know what you think of this extension.
• For support, check the existing questions, or ask a new support question in the Support web!
• Please report bugs below

CommonHeaderFooterPlugin Development Discussion

I've just uploaded first version. Comments and suggestions welcome!

I've noticed one problem that I'm not sure how to solve. When a topic INCLUDE's another topic, this plugin gives the INCLUDE'd topic a header and footer, resulting in multiple headers and footers in the final document. I can think of several approaches, none completely satisfying:

  1. Use the allow and deny preferences to prevent headers & footers for the included file.
  2. , If defining a SECTION to be INCLUDE'd, use COMMONHEADERSKIP inside the section (to prevent the extra header) and COMMONHEADER outside the section (to explicitly add the header when not INCLUDE'ing).

-- ClifKussmaul - 16 Jun 2006

Thanks Clif for contributing this Plugin!

I made a small change to the SHORTDESCRIPTION, please feel free to take this into the next release.

Wondering if it might be easier to add the header/footer conditionally in the skin, depending on preferences settings. That way you do not have multiple headers/footers in INCLUDEs, and users are less likely to remove them by accident.

-- PeterThoeny - 16 Jun 2006

I have create a header topic in the TWiki web. When I try to include the header content in a topic by using the %COMMONHEADER% variable, the header content is not inserted. I'm using the latest TWiki version - Jun 25, 2006. What is the problem?

-- AlokNarula - 29 Jun 2006

Have you enabled the plugin in bin/configure?

-- JasonHill - 29 Jun 2006

Peter, Thanks for your encouragement.

I don't know much about skins yet. Would I have to modify each skin? I was trying to make this work with any skin.

-- ClifKussmaul - 05 Jul 2006

Alok, Are you still having trouble? Does the plugin appear in TWiki/InstalledPlugins? I'd be happy to take a quick look at your twiki to see if I can figure out the problem.

-- ClifKussmaul - 05 Jul 2006

Oh, if you intend this for any skin than the Plugin might be a an easier way to go.

-- PeterThoeny - 05 Jul 2006

Clif, I couldn't get this plugin to work. I enabled it via configure and created a header and footer topic. Then I used the %COMMONHEADER% and %COMMONFOOTER% variables in a topic in Sandbox, expecting to see the content of the header and footer topics. But the content wasn't there.

-- AlokNarula - 06 Jul 2006

Here's a working example, which might help you figure out what is going on. This is the configuration page:

http://melchior.muhlenberg.edu/twiki/bin/view/TWiki/CommonHeaderFooterPlugin

The is the WebHome for a wiki that uses the plugin:

http://melchior.muhlenberg.edu/twiki/bin/view/PUIeship/WebHome

-- ClifKussmaul - 06 Jul 2006

I've been able to configure this plugin. However I notice one bug. When I edit a topic in Wysiwyg mode, the content from the CommonFooter topic is copied into the topic being edited. Everytime I edit the topic in Wysiwyg mode, the content is copied. Thus if I edit a topic n times in Wysiwyg mode, the footer content appears, n+1 times.

-- AlokNarula - 12 Jul 2006

Alok, please give me a bit more information. I assume you're using WysiwygPlugin (which I haven't used much) which has known issues with "non-standard syntax".

Are you using %COMMONHEADER% and %COMMONFOOTER%, or setting the headers via settings? Do you see the problem for footers but not headers?

(Sorry for the delay in responding; WebNotify isn't working for me, so I didn't see your question right away.)

-- ClifKussmaul - 24 Jul 2006

I just enabled WysiwygPlugin, and when I have headers & footers in settings, both are expanded by WysiwygPlugin.

I tried putting WysiwygPlugin before CommonHeaderFooterPlugin, by adding the former to the list in configure, but that didn't help.

Can anyone suggest possible solutions to this problem?

-- ClifKussmaul - 24 Jul 2006

FYI - I just upgraded to TWiki 4.1.2, and CommonHeaderFooterPlugin seems pretty badly broken.

-- ClifKussmaul - 13 Aug 2007

Too bad! :cry: I was hoping to use it together with CacheAddOn to add a [cached at

I only use the footer. The footer is also inserted after each unknown WikiWord. (using Twiki 4.1.2). Too bad, I liked the concept!

-- ArnoldAtMallos - 22 Dec 2007

AliasPlugin seems to insert fixed text by modifying the view template. This seems like a way to avoid most of the problems described above. I'm still figuring out how it works, though...

-- ClifKussmaul - 08 Apr 2008

Didn't see the update for this extension for the newer version, what happened?

-- DanielDWang - 2012-07-01

Daniel, TWiki is an open source project, people come and go. Anyone can pick up and continue work on a plugin that needs TLC. I invite you to get involved with the TWiki community. As a contributor you can actively make a difference and help shape the product. It is also more likely you get help by the community when you have questions. Learn how to get involved, and see some cool projects you could implement.

-- PeterThoeny - 2012-07-01

Edit | Attach | Watch | Print version | History: r16 < r15 < r14 < r13 < r12 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r16 - 2012-07-01 - PeterThoeny
 
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2017 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.