CMSMode-Talk

Summary: Talk page for CMSMode.
Maintainer: Hagan Fox
Users: (View? / Edit)

This space is for User-contributed commentary and notes. Please include your name and a date along with your comment.

Comments

  • 13-Nov-2006 RussFink - has this work been superceded by CMSBundle? Are you maintaining this package anymore?
    • Not necessarily and yes. -- Hagan

2014-05-14 - This page now refers to the same script that's on the CMSBundle recipe's page.

  • 2017-03-28 Iome? - Couldn't get this working. Fresh install of latest pmwiki (2.2.95) and latest cmsmode (2016-09-28). Set edit password for the site "$DefaultPasswords['edit'] = pmcrypt('secret');" and included cmsmode at the end of the config.php. Menu disappears for visitor users but pages do not work, all return to main page. Did I do something wrong? Thanks!
    • Iome? Well, quickwikicms.com worked. Don't know why pmwiki + cmsmode didn't...

TL;DR: I think it's probably working as intended. The wiki-related links in the SideBar menu are disabled intentionally because they wouldn't be part of a CMS website.

In a CMS site the PmWiki-related pages would not be part of your website -- unless you're logged in, of course.

A freshly-installed "CMS site" only has one page (Main.HomePage). The PmWiki, Site, and Test groups are "redirect groups". If a visitor tries to visit them, they're redirected to the the site's HomePage. Similar for any page named WikiSandbox. This makes links in the default SideBar menu appear to be broken. They're not broken, they're disabled intentionally because they wouldn't be part of a CMS website.

FWIW, pages in the Temp group are retrievable, but aren't searchable unless you're an author.

I did a test installation:

  1. Ran this script: http://www.quickwikicms.com/testcmsmode/install-cms.txt
  2. Added this index.php: <?php include('pmwiki.php');
  3. Copied sample-config.php to config.php .
  4. Added edit and admin passwords.
  5. Added these lines to the end of config.php:
##  CMS Mode -- http://www.pmwiki.org/wiki/Cookbook/CMSMode
##  Makes the wiki look and act like a normal website for non-authors.
#
 $pagename = ResolvePageName($pagename);
 if (file_exists("$FarmD/cookbook/cmsmode.php"))
   include_once("$FarmD/cookbook/cmsmode.php");

This created a plain-vanilla copy of PmWiki with only the recipe installed.

The side-menu was still there, but had inaccessible (for non-authors) links in it. Solve this by adding an (:if auth edit:) directive as the second line in the Site.SideBar.

You end up with a fresh PmWiki CMS site using the default skin.

 http://www.quickwikicms.com/testcmsmode/site/

The site has only one page (Main.HomePage) because no pages have been added. :-)

 http://www.quickwikicms.com/testcmsmode/site/?action=search&q=.

...except there is another page.

  http://www.quickwikicms.com/testcmsmode/site/?n=Temp.TestTheTempGroup

HaganFox 2017-03-28

Talk page for the CMSMode recipe (users?).