Get XOOPS XOOPS FAQ Forums News Themes Modules
News World of XOOPS Developers Hacks Modules Themes YAXS Archive Submit News

XOOPS vs. Herko Coomans

Local Support

Make a donation

Please select an amount to donate


Do you want your username revealed with your donation?
Yes - List me as a Generous Donor
No - List my donation as from an Anonymous Donor


Search

Twitter News

Cumulus Tag Cloud

admin Arabic banner block Christmas comments cumulus DayDawn dhsoft e-Commerce E-Learning Google GUI hacks instant-zero jQuery module news Nordic Olédrion oxygen PageRank security SEO simple-XOOPS sport tag Theme wiki xoops

New Users

Registering user

# 117251

gerd69

Welcome to XOOPS!

Archives

Advertisement

XOOPS Code hosted on SourceForge

xNews v1.67 BETA - News Module goes Clonable

Posted by dnprossi on 2010/3/7 11:00:00 (2726 reads) | Posted on Modules
xNews v1.67 BETA - Clonable & UTF-8 compliant

I needed a cloanable news module and one that worked correctly with xlanguage and UTF-8 so I decided to start a new news branch.

I had to decide on two ways to face the problem. One was that i could write a cloner file with a long list of files to be parsed and renamed in every needed spot and the other to use an automatic parser of files that only changes prefixes and a few file names like the clone file in Oledrion. The first was disregarded only because at every code modification one has to keep track of every single change and update the cloner file by hand, in the second case nothing has to be done all prefixes are parsed removing conflicts between cloned modules. Its fast and reliable. Below are some of the changes I made.

Called module xNews to keep original News module as is. No overwriting.

!!!! IMPORTANT !!!! Please upgrade your News module to 1.64-5-6 before installing xNews if you have intention to import data from original - it has not been tested on previous versions.

!!!! IMPORTANT !!!! Importing original News module 1.64-5-6 data - On install xNews activates import button only if xNews stories table is empty therefore if you want to import data you should do this right after install and before doing anything else - Import will not work from clones. You can still work creating and adding news to clones without touching xNews data until you decide to import original news data.

I have tested the module on linux - Apache 2 - php 5 -mysql 5 - xoops 2.4.x - 2.5.x working fine.
Has to be tested on Windows.

Download here.

- New News clonable, UTF-8 only branch
- Complete 2.4.x and 2.5.0 alpha 2 compatability
- Modified all files and code for multiple news module install and easy cloning
- Fixed all language prefixes to:
- _AM_NW_ for admin
- _MA_NW_ for main
- _MI_NW_ for modinfo
- _MB_NW_ for blocks
- Other languages can be added after canging incomplete prefixes on standard news modules and adding the last added lines language defines using notepad++, geany - search/replace functions.
- Removed all &xxx html encoding characters from languages
- italian
- Removed FPDF (no good for utf-8)
- Repositioned tcpdf (pdf directory) to xoopsroot/Frameworks/tcpdf
- Updated tcpdf to tcpdf 4.8.026
- Fixed tcpdf_config $k_path_url that was trunkated (even though not giving any errors)
- Fixed pdf makepdf.php to work with UTF-8 and x-language
- Added Cloner Menu Item in Admin
- Used clone.php code in oledrion as base source
- Changed news_ function prefix to nw_
- Cloner will:
- change all _NW_ language prefix's to New Prefix
- change all function nw_ prefix's to New Prefix
- create new directory
- Reused unused header.php for news directory, news url and module dir name defines
- Substituted all /module/news/ dir and url references with header.php defines
- Added permission setting on install
- Added data importer from normal news module automatic on install
- Changed Upgrade functionality so that also cloned news modules can be easily upraded
- Added a clonerdata table for original and cloned modules to read and write from.
- Needed for new install and upgrade control.
- Table will only be deleted when Original xNews module will
be uninstalled and only after all other clones have been uninstalled first.
- Added Install-Uninstall from cloner admin. Only from Original xNews module.
- Cloner Admin
menu from clones will be redirected to xNews module Admin
- Added News 1.64-5-6 module import function on xNews Clone Manager
- Added Latest News Block.


Printer Friendly Page Send this Story to a Friend Create a PDF from the article


Bookmark this article at these sites

                   

The comments are owned by the poster. We aren't responsible for their content.

Bravo
Posted: 2010/3/7 12:35 • Updated: 2010/3/7 12:35
Fantastic! I am very glad to see the further development of News.

I hope, the best features of all the News "clones" will get merged into the AMS/News combined module in near future, and that we'll have a team of people working together on that module.
Posted: 2010/3/7 13:23 • Updated: 2010/3/7 13:23
I prefer news module against AMS.
Glad to see there is someone that will continue support for news module. Such great and simple module!
Posted: 2010/3/7 13:28 • Updated: 2010/3/7 13:28
great
Posted: 2010/3/7 13:44 • Updated: 2010/3/7 13:44
Anonymous
This is great!

Would you like any feature list from users? O:)
Posted: 2010/3/7 13:45 • Updated: 2010/3/7 13:45
Quote:
Would you like any feature list from users? O:)

More than list of features from users, probably list of users who would help with new features
Posted: 2010/3/7 13:57 • Updated: 2010/3/7 13:57
Quote:
I prefer news module against AMS.

Any specific reasons?

From the overall XOOPS perspective, I think it's better to have one strong "news" module, instead of 20 different variations, as this is confusing to the users, and makes harder to maintain.

Plus it's better to have 10 developers working on one module, instead of on 10 different modules.

So I hope that we could create a team of several developers that would focus on creating one very strong "news" modules, that would be the envy of all other CMS systems
Posted: 2010/3/7 14:07 • Updated: 2010/3/7 14:07
Considering the fact that I'm not a coder I could help with templates and ideas :)
Posted: 2010/3/7 17:00 • Updated: 2010/3/7 17:00
Awesome! Import as well as cloning the module works fine. Great!

You can find german translation for 1.67 beta on myxoops.org

http://www.myxoops.org/news/article.php?storyid=1215
(directlink: http://www.myxoops.org/news/visit.php?fileid=1)
Posted: 2010/3/10 8:38 • Updated: 2010/3/10 8:40
Thank you all for your very positive comments.

I did find some issues that are being fixed and will update as soon as possible and will let every one know in the news....

If any one finds other issues please report them here! or in "Xoops Module Troubleshooting"
Posted: 2010/3/11 4:56 • Updated: 2010/3/11 4:56
Nice

You should add SmartSection importation feature.
Posted: 2010/3/16 13:44 • Updated: 2010/3/16 13:47
Excellent! Now, there are a few News module out there which ONE is the official one to use?
Posted: 2010/3/16 21:04 • Updated: 2010/3/16 21:04
thank you for your work :D

I hope we have dev team for news module as soon as possible.


I want change admin index page design father that send codes for you :D !
Posted: 2010/3/17 3:01 • Updated: 2010/3/17 3:03
Just want to say thank you

so far so good

now i have

1. news
2. blog


thanks again...

hope someday news can have seo url
Posted: 2010/3/20 9:19 • Updated: 2010/3/20 9:19
dnsprossi


here is seo hack for news module

http://www.xoops.org/modules/news/article.php?storyid=4571


can this be integrate in the future in xnews

TQ
Posted: 2010/3/20 10:55 • Updated: 2010/3/20 10:55
you can find persian translation at here :
http://xoops.svn.sourceforge.net/view ... es/persian/modules/xnews/
Posted: 2010/3/22 4:56 • Updated: 2010/3/22 4:56
Hi friends
There is a bug in v1.6.8beta, i think in the most block files. I cannot open as an example the file block/news_latestnews.php, i have more or less a blank_page. I think the error comes from line 232 and 233 in this file, the module path is not correct:

include_once NW_MODULE_PATH '/include/functions.php';
include_once 
NW_MODULE_PATH '/class/class.newstopic.php';


Debugger means:
Warnung: include_once(NW_MODULE_PATH/include/functions.php) [function.include-once]: failed to open stream: No such file or directory in Datei /modules/xnews/blocks/news_latestnews.php Zeile 232

I try it ith the old command:

include_once XOOPS_ROOT_PATH.'/modules/xnews/include/functions.php';
include_once 
XOOPS_ROOT_PATH.'/modules/xnews/class/class.newstopic.php';


and that will work.

Greets Andy
Posted: 2010/5/19 12:04 • Updated: 2010/5/19 12:04
Quote:
Fatal error: Class 'nw_sFiles' not found in /home/sait/public_html/sait.com/modules/xnews/blocks/news_latestnews.php on line 35


????????????????????????
Posted: 2010/5/24 10:23 • Updated: 2010/5/24 10:23