Jump to Main Content
Content > XOOPS > WF-Channel Content Module
WF-Channel Content Module

WF-Channel is an excellent but simple, basic content module for XOOPS — great for managing those miscellaneous pages like your privacy policy, terms of service, about us, contact us, or as a content module for a very simple business-card site.

Latest Version: 2.05beta | 2.03 (Release Notes)

Features:

  • Blocks: Menu, Recent
  • Image/File Upload
  • HTML URL/file Wrapper
  • Special Pages: Link to Us, Refer Us (with usage stats)
  • Social Bookmarks / AddThis
  • WYSIWYG Editors
  • Comments
  • Notifications

Requirements: WF-Resource (Special resource module for the Xoosla/WF-Projects modules, Note that the current WF-Resource 1.04beta download is set as 1.05 in the module and is required by WF-Channel 2.05beta to update/install the module); XOOPS of course

I've used this module off-and-on for awhile, and it does what it does very well. The module is perfect for the few misc pages that don't really go anywhere else on a site, and for simple sites as a content module. I know that future development is going to include categories, in spite of the author's previous promise to not do that. There are other good content modules, too, depending upon your needs. The module also has a Link to Us and Refer page, but I find them limiting and instead put those in content somewhere.

Installation / Upgrade

Either way, you need to download and install/upgrade the WF-Resource module.

Fresh Install

Very easy — install per standard XOOPS module installation/upgrade instructions (copy files to module area, install via the modules administration page).

Upgrade

Pretty easy overall — install per standard XOOPS module installation/upgrade instructions (copy files to module area, update module via the system modules administration page). I'll note that when upgrading from 2.00 to 2.03, I got a less-than-favorable (mostly blank) page. So, while I showed the right version in the module administration page, I updated it again and got better output. If upgrading from 1.x to 2.x, you will need to update the database in the module administration area. New in 2.05: you must also re-save the page access permissions (visit the permissions page in the module administration and re-save it). I also read something about clearing your cache files. You'll have some orphaned (old-style) permissions in your database that can be removed using the instructions below.

If you get a blank page when you visit the module admin page, likely you haven't installed WF-Resource module.

Configuration

You can turn off the Link to Us and Refer pages in the module preferences for each page. Or update them to your liking. I also recommend moving your file upload area to your uploads directory or some other appropriate location to make upgrades easier.

Templates

I of course modified all the templates to my liking. 2.03 included a number of templates that weren't used, presumably for 2.05. However, they were changed extensively in 2.05 along with the language files, which normalized them per standard module conventions (at least much better).

Notes

While it's a nice extra, I don't like the module-based social bookmarking, and even more so in 2.05 because of the lack of control in the HTML (done in the code)(, so I turned it off in the configuration for sites I run. I opt for either the Social Bookmarking module (even with the few misgivings I have about it) or just use AddThis. I find it easier to manage in a single place rather than in each module. In 2.05, this module introduced the ability to use the AddThis function instead of their bookmarks. Great idea, although, again, I suggest adding your own into your theme instead so it's available across your site.

Defects / Enhancement Requests

I ran across a few issues, unfortunately.

FCKeditor

I use FCKeditor, but it didn't work upon selection, defaulting back to the standard textarea. This release expects an older release of FCKeditor. I fixed it to work with XOOPS 2.3.3 -- really easy. In the module's xoops_version.php, you need to edit line 226 (line 173 in 2.03) (configuration 'use_wysiwyg'), and change 'FCK Editor' => 'FCKeditor' to 'FCK Editor' => 'fckeditor'. You will have to update the module and then reselect FCKeditor in the preferences (you may have to change it to another selection, save it, then change it back to FCK Editor).

Refer/Link Pages Don't Display

In 2.05beta, the problem is a name-case issue (unix v windows) in WF-Resource, not WF-Channel — per this noted bug. There is also an issue with the Furl bookmark icon. Change the case of filenames to all lower case:

  • wfresource/class/filters/sanitize_textbox.php
  • wfresource/images/icon/bookmark/furl.png

Refer Page Admin Update Fails

Introduced in 2.03, and continuing in 2.05beta, there is a problem with the Refer page save function. The problem rests with a restructuring of the database in 2.03 (done in good faith to be aligned with XOOPS conventions), but the code doesn't match. The field in question is wfcr_ublurb in the wfcrefer table. The code uses both wfsr_ublurb and wfcr_ublurb with the latter more aligned with the rest of the table field names, so I went with that. To fix it, make changes in (2.05beta version):

  • class/class.refer.php - wfsr: lines 33, 67
  • class/classforms/form_wfc_refer.php: lines 116-118 (no changes)
  • class/classforms/form_wfc_refer.php: line 29
  • include/upgrade.php: line 94
  • sql/wfchannel.sql: lines 103, 124

Refer Page Form Fields

The Message element title incorrectly displays the correct. Changes to class/class.refer.php (lines 67-72) and class/classforms/form_wfc_referpage.php (lines 29-34) from:

if ( $this->getVar( 'wfsr_ublurb' ) ) {
    $form->addElement( new XoopsFormTextArea( _MD_WFC_CAPTACHA, 'message', $this->getVar( 'wfcr_dblurb' ) ), true );
} else {
    $form->addElement( new XoopsFormHidden( 'message', $this->getVar( 'wfcr_dblurb' ) ) );
}
$form->addElement( new XoopsFormCaptcha( _MD_WFC_CAPTACHA ), true );

to:

if ( $this->getVar( 'wfcr_ublurb' ) ) {
    $form->addElement( new XoopsFormTextArea( _MD_WFC_WRITEBLURB, 'message', $this->getVar( 'wfcr_dblurb' ) ), true );
} else {
    $form->addElement( new XoopsFormHidden( 'message', $this->getVar( 'wfcr_dblurb' ) ) );
}

$form->addElement( new XoopsFormCaptcha( _MD_WFC_CAPTACHA, 'wfc_captcha', false ), true );

Refer Page Doesn't Show Privacy Statement

The privacy statement for the refer page got lost and doesn't even show up in the code. I fixed this in index.php adding line 67 (part of the 'refer' array definition):

'privacytext' => ($refer_obj->getVar( 'wfcr_privacy' )) ? $refer_obj->getVar( 'wfcr_privacytext' ) : ''

And then used this in the template:

<{if $refer.privacytext}><{$refer.privacytext}><{/if}>

Refer Page Required-Field Markation

Every field came out as required. This is because the logic in the template wasn't working correctly. Removed this from the template. I fixed the logic.

Admin Duplicate Doesn't Work

In the Admin control panel, on the main index page listing the pages, the duplicate item link gives an error. Luckily you can selected it and use the selected action to get around this, but it would be nice if it worked as it's supposed to.

Real Name vs Username

Secured sites use a display name (XOOPS real name) instead of the username to help prevent login theft. This module doesn't allow the usage of the real name. I had to code it manually.

Notifications

In 2.05, this module includes notifications. Excellent!!! Unfortunately, for the main page, the block doesn't show the page notifications, but the inline does. Why? Something to do with what is passed to the block vs the inline one. Hmmmm.

New Pages Don't Display in Recent Block

New problem in 2.05beta. New pages aren't showing in Recent Block. There is a new mismatch in the permissions and the query for this module. I'm assuming that the issue is the block code since the permissions name changed since 2.03. Change blocks/wfc_block.menu.php (line 29) from:

. "\n WHERE ( l.gperm_name = 'wfc_page'"

to

. "\n WHERE ( l.gperm_name = 'page_read'"

Unfortunately, there are some old permissions rows left in the database that aren't cleaned up. You can find and remove them with this query: SELECT * FROM xoops_group_permission WHERE gperm_name = 'wfc_page';

Paging Doesn't Work

Pagination of menu items doesn't work. I had 7 pages, one set to default, and set max pages to 5 and couldn't get it to paginate. Maybe I don't understand how that's suppose to work, but....

Menu Block Uses Publish Date Order

One would think that a menu would be arrangeable, but this block orders by the publish date instead of the sort order defined in the administrative area. As such, this block is more of a "new" or "latest" style block, but there is already a new/latest block. So I "fixed" this by changing the sort order in the block code. In /blocks/wfc_block.menu.php, line 32, change ORDER BY c.wfc_publish DESC to ORDER BY c.wfc_weight ASC. Now you can sort them by page order.


Other Pages
Previous Page XOOPS 2.3.x Overview, Installation, and Upgrade (from 2.0.x) xoRewriteModule Next Page
 
Comments are solely the opionion of the author and not to be construed as the opinion of anyone else.
Login
 

 

 

(c) 2006-2007 - Mark Boyden
Privacy - Legal Stuff - Contacts