Index
[[Topic]] or [[Topic][label]] (do not use WikiWord links)
{RequirePublishVariable} configure flag is set, and if the topic has no %STARTPUBLISH% and/or %STOPPUBLISH% variable.
{RequirePublishVariable} configure flag is set, the publish area of a topic is indicated by a green dotted line at the left page margin (as with this bullet list).
Index to index.html, AboutUs to aboutus.html, and Customer_Support to customer_support.html.
%STARTPUBLISH% and %STOPPUBLISH% is used (the whole text if missing).
publish_topic context can be used for this. This example shows how to include ClassHeader for normal topic view, and include ClassHeaderPublish instead when publishing the topic: %IF{ "context 'publish_topic'" then="$percntINCLUDE{ClassHeader}$percnt" else="$percntINCLUDE{ClassHeaderPublish}$percnt" }%
%STARTPUBLISH% - place in topic text where to start publishing %STOPPUBLISH% - place in topic text where to stop publishing %PUBLISHWEB{"nicetopic"}% - nice topic name Customer_Support turns into Customer Support
%PUBLISHWEB{"breadcrumb"}% - nice breadcrumb %PUBLISHWEB{"nicetopic"}% to get the complete breadcrumb
%PUBLISHWEB{"breadcrumb"}% variable to show the breadcrumb
You are here: Home > Customer Support >
%PUBLISHWEB{"publish" topic="Name"}% - re-publish topic(s) without edit/save cycle topic="all" publishes all topics in the Publish web except for the excluded ones
topic="Any_Topic" publishes a specific topics
PUBLISHWEBPLUGIN_PUBLISHSKIN setting, add a * Set PUBLISHWEBPLUGIN_PUBLISHSKIN = mypublish bullet in the preferences topic.
{Plugins}{PublishWebPlugin}{PublishPath} to publish content to: %PUBLISHWEB{"breadcrumb"}%: %PUBLISHWEB{"breadcrumb"}%: PublishWebPlugin.zip in your twiki installation directory. Content: | File: | Description: |
|---|---|
data/TWiki/PublishWebPlugin.txt | Plugin topic |
data/DemoWebsite/*.txt | Demo web for website publishing (topics) |
pub/DemoWebsite/WebPreferences/ | Demo web for website publishing (attachments) |
lib/TWiki/Plugins/PublishWebPlugin.pm | Plugin Perl module |
templates/view.demo_website.tmpl | Demo publish skin |
{Plugins}{PublishWebPlugin}{TemplatePath}: Template path where skin files are located. twiki/templates directory is assumed; normal TWikiTemplates search path applies, e.g. for a PUBLISHSKIN = website setting, a twiki/templates/view.website.tmpl template file is assumed
PUBLISHSKIN = website setting, a $TWiki::cfg{Plugins}{PublishWebPlugin}{TemplatePath}/website.html file is referenced
{Plugins}{PublishWebPlugin}{PublishPath}: Path where the plugin places the generated html files. twiki/pub, such as '../../html'
'/var/www/vhosts/%LCWEB%/html'
{Plugins}{PublishWebPlugin}{AttachPath}: Path where the plugin places images and other topic attachments. $TWiki::cfg{Plugins}{PublishWebPlugin}{PublishPath}, default is '_publish'
{Plugins}{PublishWebPlugin}{PublishUrlPath}: URL path that corresponds to {PublishPath} directory. Leave empty if it is the HTML document root.
%WEB% - name of the publish web
%LCWEB% - lower case name of the publish web (preferred over mixed case)
%SKIN% - name of the publish skin
twiki/lib/LocalSite.cfg settings: $TWiki::cfg{Plugins}{PublishWebPlugin}{Enabled} = 1; $TWiki::cfg{Plugins}{PublishWebPlugin}{TemplatePath} = ''; $TWiki::cfg{Plugins}{PublishWebPlugin}{PublishPath} = '/path/to/apache/html'; $TWiki::cfg{Plugins}{PublishWebPlugin}{AttachPath} = '_publish'; $TWiki::cfg{Plugins}{PublishWebPlugin}{PublishUrlPath} = ''; $TWiki::cfg{Plugins}{PublishWebPlugin}{RequirePublishVariable} = 1; $TWiki::cfg{Plugins}{PublishWebPlugin}{PublishAreaStyle} = 'border-left: 4px #1b1 dotted; margin-left: -14px; padding-left: 10px;'; $TWiki::cfg{Plugins}{PublishWebPlugin}{Debug} = 0;
{PublishPath} setting if needed
{AttachPath} setting (relative to {PublishPath})
{PublishPath} and {AttachPath} to be writable by the webserver user (such as user nobody or apache on RedHat Linux)
$TWiki::cfg{Plugins}{PublishWebPlugin}{PublishPath} has an index.html
index.html file
NOAUTOLINK setting to on, and set the PUBLISHWEBPLUGIN_* settings as in the WebPreferences of the DemoWebsite web
twiki/templates/view.*.tmpl skin file, or can be created from scratch. This plugin contains a bare bone unstyled demo skin called demo_website located at twiki/templates/view.demo_website.tmpl
%PUBLISHWEB{"breadcrumb"}% and %PUBLISHWEB{"nicetopic"}%
%PUBLISH_SITE%, %PUBLISH_LOGO%, etc.
* Set PUBLISHWEBPLUGIN_PUBLISHSKIN = mypublish
| Plugin Author: | TWiki:Main.PeterThoeny |
| Copyright: | © 2006-2016 Peter Thoeny, TWiki.org © 2008-2016 TWiki:TWiki.TWikiContributor © 2013 Wave Systems Corp. |
| Sponsor: | Wave Systems Corp. |
| License: | GPL (GNU General Public License |
| Plugin Version: | 2016-03-27 |
| 2016-03-27: | TWikibug:Item7738 |
| 2016-01-17: | TWikibug:Item7708 |
| 2014-12-04: | TWikibug:Item7593 |
| 2014-10-26: | TWikibug:Item6968 |
| 2014-05-22: | TWikibug:Item7368 |
| 2013-08-08: | TWikibug:Item7313 |
| 2013-05-14: | TWikibug:Item7154 |
| 2013-04-25: | TWikibug:Item7244 |
| 2013-02-15: | TWikibug:Item7091 |
| 2013-02-07: | TWikibug:Item7091 |
| 2013-02-05: | TWikibug:Item7123 |
| 2013-02-05: | TWikibug:Item7091 |
| 2012-10-21: | TWikibug:Item6818 |
| 2012-06-12: | TWikibug:Item6837 |
| 2012-03-06: | TWikibug:Item6857 |
| 2012-03-05: | TWikibug:Item6856 |
| 2012-02-28: | TWikibug:Item6853 |
| 2012-02-25: | TWikibug:Item6851 |
| 2011-07-23: | TWikibug:Item6808 |
| 2011-07-23: | TWikibug:Item6773LocalSite.cfg; support multiple skins; support template path outside TWiki file path; add view.website.tmpl as a publish skin for demo; possible to publish into sub-directory of html doc root indicated by {PublishUrlPath} setting; change global package variables from "use vars" to "our"; remove URL parameters in links of published page to make TOC and other TWiki internal links work |
| 2006-02-15: | Added %PUBLISHWEB{"publish" topic="Name"}% |
| 2006-02-13: | Initial version |
| TWiki Dependency: | $TWiki::Plugins::VERSION 1.1 |
| CPAN Dependencies: | none |
| Other Dependencies: | none |
| Perl Version: | 5.005 |
| Benchmarks |
GoodStyle 100%, FormattedSearch 100%, PublishWebPlugin 99% |
| Plugin Home: | http://TWiki.org/cgi-bin/view/Plugins/PublishWebPlugin |
| Feedback: | http://TWiki.org/cgi-bin/view/Plugins/PublishWebPluginDev |
| Appraisal: | http://TWiki.org/cgi-bin/view/Plugins/PublishWebPluginAppraisal |
| PackageForm | |
|---|---|
| TopicClassification | PluginPackage |
| TestedOnTWiki | 6.1, 6.0, 5.1, 5.0, 4.3, 4.2, 4.1, 4.0.0 |
| TestedOnOS | OsLinux |
| ShouldRunOnOS | AnyOS |
| InstalledOnTWikiOrg | No |
| DemoUrl | |
| DevelopedInSVN | Yes |
| ModificationPolicy | PleaseFeelFreeToModify |
| RelatedTopics | CategoryImportExport, PublishContrib |
| I | Attachment | History | Action | Size | Date | Who | Comment |
|---|---|---|---|---|---|---|---|
| |
PublishWebPlugin.md5 | r32 r31 r30 r29 r28 | manage | 0.2 K | 2016-03-28 - 06:53 | PeterThoeny | |
| |
PublishWebPlugin.tgz | r32 r31 r30 r29 r28 | manage | 20.4 K | 2016-03-28 - 06:53 | PeterThoeny | |
| |
PublishWebPlugin.zip | r35 r34 r33 r32 r31 | manage | 32.4 K | 2016-03-28 - 06:53 | PeterThoeny | |
| |
PublishWebPlugin_installer | r7 r6 r5 r4 r3 | manage | 4.4 K | 2016-03-28 - 06:53 | PeterThoeny |