|
From: <txm...@us...> - 2012-01-31 18:04:25
|
Revision: 8847
http://xoops.svn.sourceforge.net/xoops/?rev=8847&view=rev
Author: txmodxoops
Date: 2012-01-31 18:04:15 +0000 (Tue, 31 Jan 2012)
Log Message:
-----------
Added Paths:
-----------
XoopsModules/xnews/trunk/timgno/xnews/
XoopsModules/xnews/trunk/timgno/xnews/.htaccess
XoopsModules/xnews/trunk/timgno/xnews/admin/
XoopsModules/xnews/trunk/timgno/xnews/admin/Copia di index.php
XoopsModules/xnews/trunk/timgno/xnews/admin/about.php
XoopsModules/xnews/trunk/timgno/xnews/admin/admin_footer.php
XoopsModules/xnews/trunk/timgno/xnews/admin/admin_header.php
XoopsModules/xnews/trunk/timgno/xnews/admin/admin_header.php~
XoopsModules/xnews/trunk/timgno/xnews/admin/clonate.php
XoopsModules/xnews/trunk/timgno/xnews/admin/clonate.php~
XoopsModules/xnews/trunk/timgno/xnews/admin/cloner.php
XoopsModules/xnews/trunk/timgno/xnews/admin/export.php
XoopsModules/xnews/trunk/timgno/xnews/admin/export.php~
XoopsModules/xnews/trunk/timgno/xnews/admin/functions.php
XoopsModules/xnews/trunk/timgno/xnews/admin/header.php
XoopsModules/xnews/trunk/timgno/xnews/admin/import.php
XoopsModules/xnews/trunk/timgno/xnews/admin/import.php~
XoopsModules/xnews/trunk/timgno/xnews/admin/import_ams.php
XoopsModules/xnews/trunk/timgno/xnews/admin/import_news.php
XoopsModules/xnews/trunk/timgno/xnews/admin/import_publisher.php
XoopsModules/xnews/trunk/timgno/xnews/admin/import_smartsection.php
XoopsModules/xnews/trunk/timgno/xnews/admin/import_wfsection.php
XoopsModules/xnews/trunk/timgno/xnews/admin/importer.php
XoopsModules/xnews/trunk/timgno/xnews/admin/importer.php~
XoopsModules/xnews/trunk/timgno/xnews/admin/index.html
XoopsModules/xnews/trunk/timgno/xnews/admin/index.php
XoopsModules/xnews/trunk/timgno/xnews/admin/index.php~
XoopsModules/xnews/trunk/timgno/xnews/admin/menu.php
XoopsModules/xnews/trunk/timgno/xnews/admin/menu.php~
XoopsModules/xnews/trunk/timgno/xnews/admin/metas.php
XoopsModules/xnews/trunk/timgno/xnews/admin/newsletter.php
XoopsModules/xnews/trunk/timgno/xnews/admin/newsletter.php~
XoopsModules/xnews/trunk/timgno/xnews/admin/permissions.php
XoopsModules/xnews/trunk/timgno/xnews/admin/permissions.php~
XoopsModules/xnews/trunk/timgno/xnews/admin/statistics.php
XoopsModules/xnews/trunk/timgno/xnews/admin/stories.php
XoopsModules/xnews/trunk/timgno/xnews/admin/stories.php~
XoopsModules/xnews/trunk/timgno/xnews/admin/stories_files.php
XoopsModules/xnews/trunk/timgno/xnews/admin/stories_votedata.php
XoopsModules/xnews/trunk/timgno/xnews/admin/topics.php
XoopsModules/xnews/trunk/timgno/xnews/admin/topics.php~
XoopsModules/xnews/trunk/timgno/xnews/archive.php
XoopsModules/xnews/trunk/timgno/xnews/article.php
XoopsModules/xnews/trunk/timgno/xnews/backendt.php
XoopsModules/xnews/trunk/timgno/xnews/blocks/
XoopsModules/xnews/trunk/timgno/xnews/blocks/index.html
XoopsModules/xnews/trunk/timgno/xnews/cgi-bin/
XoopsModules/xnews/trunk/timgno/xnews/class/
XoopsModules/xnews/trunk/timgno/xnews/class/blacklist.php
XoopsModules/xnews/trunk/timgno/xnews/class/class.latestnews.php
XoopsModules/xnews/trunk/timgno/xnews/class/class.mimetype.php
XoopsModules/xnews/trunk/timgno/xnews/class/class.newsstory.php
XoopsModules/xnews/trunk/timgno/xnews/class/class.newsstory.php~
XoopsModules/xnews/trunk/timgno/xnews/class/class.newstopic.php
XoopsModules/xnews/trunk/timgno/xnews/class/class.newstopic.php~
XoopsModules/xnews/trunk/timgno/xnews/class/class.objecthandler.php
XoopsModules/xnews/trunk/timgno/xnews/class/class.sfiles.php
XoopsModules/xnews/trunk/timgno/xnews/class/class.sfiles.php~
XoopsModules/xnews/trunk/timgno/xnews/class/class.xnewsimport.php
XoopsModules/xnews/trunk/timgno/xnews/class/class.xnewsstory.php
XoopsModules/xnews/trunk/timgno/xnews/class/class.xnewstopic.php
XoopsModules/xnews/trunk/timgno/xnews/class/class.xnewstopic.php~
XoopsModules/xnews/trunk/timgno/xnews/class/index.html
XoopsModules/xnews/trunk/timgno/xnews/class/keyhighlighter.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/menu.php
XoopsModules/xnews/trunk/timgno/xnews/class/object.php
XoopsModules/xnews/trunk/timgno/xnews/class/registryfile.php
XoopsModules/xnews/trunk/timgno/xnews/class/stories.php~
XoopsModules/xnews/trunk/timgno/xnews/class/stories_files.php~
XoopsModules/xnews/trunk/timgno/xnews/class/topics.php~
XoopsModules/xnews/trunk/timgno/xnews/class/tree.php
XoopsModules/xnews/trunk/timgno/xnews/class/tree.php~
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/Canvas.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/Dimension.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/Exception.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/FileMapperFactory.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/Image.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/OpFactory.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/PaletteImage.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/TrueColorImage.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/WideImage.inc.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/fonts/
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/fonts/Font_GDF.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/fonts/Font_TTF.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/mappers/
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/mappers/ImageFileMapper_GD.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/mappers/ImageFileMapper_GD2.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/mappers/ImageFileMapper_GIF.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/mappers/ImageFileMapper_JPEG.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/mappers/ImageFileMapper_PNG.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/ApplyConvolution.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/ApplyFilter.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/ApplyMask.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/AsGrayscale.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/CopyChannelsPalette.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/CopyChannelsTrueColor.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/CorrectGamma.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/Crop.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/Flip.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/GetMask.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/Merge.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/Mirror.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/Resize.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/Rotate.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/wideimage/operations/Unsharp.class.php
XoopsModules/xnews/trunk/timgno/xnews/class/xnews_stories.php
XoopsModules/xnews/trunk/timgno/xnews/class/xnews_stories.php~
XoopsModules/xnews/trunk/timgno/xnews/class/xnews_stories_files.php
XoopsModules/xnews/trunk/timgno/xnews/class/xnews_stories_votedata.php
XoopsModules/xnews/trunk/timgno/xnews/class/xnews_topics.php
XoopsModules/xnews/trunk/timgno/xnews/comment_delete.php
XoopsModules/xnews/trunk/timgno/xnews/comment_edit.php
XoopsModules/xnews/trunk/timgno/xnews/comment_new.php
XoopsModules/xnews/trunk/timgno/xnews/comment_post.php
XoopsModules/xnews/trunk/timgno/xnews/comment_reply.php
XoopsModules/xnews/trunk/timgno/xnews/config.php
XoopsModules/xnews/trunk/timgno/xnews/css/
XoopsModules/xnews/trunk/timgno/xnews/css/index.html
XoopsModules/xnews/trunk/timgno/xnews/docs/
XoopsModules/xnews/trunk/timgno/xnews/docs/changelog.txt
XoopsModules/xnews/trunk/timgno/xnews/docs/credits.txt
XoopsModules/xnews/trunk/timgno/xnews/docs/index.html
XoopsModules/xnews/trunk/timgno/xnews/docs/install.txt
XoopsModules/xnews/trunk/timgno/xnews/docs/lang_diff.txt
XoopsModules/xnews/trunk/timgno/xnews/docs/licence.txt
XoopsModules/xnews/trunk/timgno/xnews/docs/readme.txt
XoopsModules/xnews/trunk/timgno/xnews/docs/root.htaccess
XoopsModules/xnews/trunk/timgno/xnews/docs/xnews_stories.php
XoopsModules/xnews/trunk/timgno/xnews/docs/xnews_stories_files.php
XoopsModules/xnews/trunk/timgno/xnews/docs/xnews_stories_votedata.php
XoopsModules/xnews/trunk/timgno/xnews/docs/xnews_topics.php
XoopsModules/xnews/trunk/timgno/xnews/header.php
XoopsModules/xnews/trunk/timgno/xnews/images/
XoopsModules/xnews/trunk/timgno/xnews/images/deco/
XoopsModules/xnews/trunk/timgno/xnews/images/deco/about.png
XoopsModules/xnews/trunk/timgno/xnews/images/deco/arrow.gif
XoopsModules/xnews/trunk/timgno/xnews/images/deco/blank.gif
XoopsModules/xnews/trunk/timgno/xnews/images/deco/delete.gif
XoopsModules/xnews/trunk/timgno/xnews/images/deco/edit.gif
XoopsModules/xnews/trunk/timgno/xnews/images/deco/index.html
XoopsModules/xnews/trunk/timgno/xnews/images/deco/index.png
XoopsModules/xnews/trunk/timgno/xnews/images/deco/off.gif
XoopsModules/xnews/trunk/timgno/xnews/images/deco/on.gif
XoopsModules/xnews/trunk/timgno/xnews/images/deco/permissions.png
XoopsModules/xnews/trunk/timgno/xnews/images/deco/pref.png
XoopsModules/xnews/trunk/timgno/xnews/images/deco/stories.png
XoopsModules/xnews/trunk/timgno/xnews/images/deco/stories_search.png
XoopsModules/xnews/trunk/timgno/xnews/images/deco/stories_votedata.png
XoopsModules/xnews/trunk/timgno/xnews/images/deco/topics.png
XoopsModules/xnews/trunk/timgno/xnews/images/deco/update.png
XoopsModules/xnews/trunk/timgno/xnews/images/index.html
XoopsModules/xnews/trunk/timgno/xnews/images/menu/
XoopsModules/xnews/trunk/timgno/xnews/images/menu/bg.png
XoopsModules/xnews/trunk/timgno/xnews/images/menu/index.html
XoopsModules/xnews/trunk/timgno/xnews/images/menu/left_both.png
XoopsModules/xnews/trunk/timgno/xnews/images/menu/right_both.png
XoopsModules/xnews/trunk/timgno/xnews/images/xnews_slogo.png
XoopsModules/xnews/trunk/timgno/xnews/include/
XoopsModules/xnews/trunk/timgno/xnews/include/functions.php
XoopsModules/xnews/trunk/timgno/xnews/include/index.html
XoopsModules/xnews/trunk/timgno/xnews/include/install.php
XoopsModules/xnews/trunk/timgno/xnews/include/search.inc.php
XoopsModules/xnews/trunk/timgno/xnews/include/static_var.php
XoopsModules/xnews/trunk/timgno/xnews/include/storyform.inc.php
XoopsModules/xnews/trunk/timgno/xnews/include/storyform.original.php
XoopsModules/xnews/trunk/timgno/xnews/index.php
XoopsModules/xnews/trunk/timgno/xnews/js/
XoopsModules/xnews/trunk/timgno/xnews/js/funcs.js
XoopsModules/xnews/trunk/timgno/xnews/js/index.html
XoopsModules/xnews/trunk/timgno/xnews/language/
XoopsModules/xnews/trunk/timgno/xnews/language/english/
XoopsModules/xnews/trunk/timgno/xnews/language/english/admin.php
XoopsModules/xnews/trunk/timgno/xnews/language/english/blocks.php
XoopsModules/xnews/trunk/timgno/xnews/language/english/help/
XoopsModules/xnews/trunk/timgno/xnews/language/english/help/help.html
XoopsModules/xnews/trunk/timgno/xnews/language/english/help/index.html
XoopsModules/xnews/trunk/timgno/xnews/language/english/index.html
XoopsModules/xnews/trunk/timgno/xnews/language/english/mail_template/
XoopsModules/xnews/trunk/timgno/xnews/language/english/mail_template/category_newstory_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/english/mail_template/global_newcategory_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/english/mail_template/global_newstory_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/english/mail_template/global_storysubmit_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/english/mail_template/index.html
XoopsModules/xnews/trunk/timgno/xnews/language/english/mail_template/story_approve_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/english/mail_template/topic_newstory_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/english/main.php
XoopsModules/xnews/trunk/timgno/xnews/language/english/modinfo.php
XoopsModules/xnews/trunk/timgno/xnews/language/french/
XoopsModules/xnews/trunk/timgno/xnews/language/french/admin.php
XoopsModules/xnews/trunk/timgno/xnews/language/french/blocks.php
XoopsModules/xnews/trunk/timgno/xnews/language/french/help/
XoopsModules/xnews/trunk/timgno/xnews/language/french/help/help.html
XoopsModules/xnews/trunk/timgno/xnews/language/french/help/index.html
XoopsModules/xnews/trunk/timgno/xnews/language/french/index.html
XoopsModules/xnews/trunk/timgno/xnews/language/french/mail_template/
XoopsModules/xnews/trunk/timgno/xnews/language/french/mail_template/category_newstory_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/french/mail_template/global_newcategory_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/french/mail_template/global_newstory_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/french/mail_template/global_storysubmit_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/french/mail_template/index.html
XoopsModules/xnews/trunk/timgno/xnews/language/french/mail_template/story_approve_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/french/mail_template/topic_newstory_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/french/main.php
XoopsModules/xnews/trunk/timgno/xnews/language/french/modinfo.php
XoopsModules/xnews/trunk/timgno/xnews/language/index.html
XoopsModules/xnews/trunk/timgno/xnews/language/italian/
XoopsModules/xnews/trunk/timgno/xnews/language/italian/admin.php
XoopsModules/xnews/trunk/timgno/xnews/language/italian/admin.php~
XoopsModules/xnews/trunk/timgno/xnews/language/italian/blocks.php
XoopsModules/xnews/trunk/timgno/xnews/language/italian/help/
XoopsModules/xnews/trunk/timgno/xnews/language/italian/help/help.html
XoopsModules/xnews/trunk/timgno/xnews/language/italian/help/index.html
XoopsModules/xnews/trunk/timgno/xnews/language/italian/index.html
XoopsModules/xnews/trunk/timgno/xnews/language/italian/mail_template/
XoopsModules/xnews/trunk/timgno/xnews/language/italian/mail_template/category_newstory_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/italian/mail_template/global_newcategory_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/italian/mail_template/global_newstory_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/italian/mail_template/global_storysubmit_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/italian/mail_template/index.html
XoopsModules/xnews/trunk/timgno/xnews/language/italian/mail_template/story_approve_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/italian/mail_template/topic_newstory_notify.tpl
XoopsModules/xnews/trunk/timgno/xnews/language/italian/main.php
XoopsModules/xnews/trunk/timgno/xnews/language/italian/modinfo.php
XoopsModules/xnews/trunk/timgno/xnews/language/italian/modinfo.php~
XoopsModules/xnews/trunk/timgno/xnews/list.tag.php
XoopsModules/xnews/trunk/timgno/xnews/makepdf.php
XoopsModules/xnews/trunk/timgno/xnews/micro_summary.php
XoopsModules/xnews/trunk/timgno/xnews/newsbythisauthor.php
XoopsModules/xnews/trunk/timgno/xnews/notification_update.php
XoopsModules/xnews/trunk/timgno/xnews/print.php
XoopsModules/xnews/trunk/timgno/xnews/ratenews.php
XoopsModules/xnews/trunk/timgno/xnews/seo.php
XoopsModules/xnews/trunk/timgno/xnews/sql/
XoopsModules/xnews/trunk/timgno/xnews/sql/index.html
XoopsModules/xnews/trunk/timgno/xnews/sql/mysql.sql
XoopsModules/xnews/trunk/timgno/xnews/sql/x_mysql.sql
XoopsModules/xnews/trunk/timgno/xnews/submit.php
XoopsModules/xnews/trunk/timgno/xnews/templates/
XoopsModules/xnews/trunk/timgno/xnews/templates/blocks/
XoopsModules/xnews/trunk/timgno/xnews/templates/blocks/index.html
XoopsModules/xnews/trunk/timgno/xnews/templates/blocks/xnews_block_archives.html
XoopsModules/xnews/trunk/timgno/xnews/templates/blocks/xnews_block_bigstory.html
XoopsModules/xnews/trunk/timgno/xnews/templates/blocks/xnews_block_latestnews.html
XoopsModules/xnews/trunk/timgno/xnews/templates/blocks/xnews_block_moderate.html
XoopsModules/xnews/trunk/timgno/xnews/templates/blocks/xnews_block_randomnews.html
XoopsModules/xnews/trunk/timgno/xnews/templates/blocks/xnews_block_top.html
XoopsModules/xnews/trunk/timgno/xnews/templates/blocks/xnews_block_topicnav.html
XoopsModules/xnews/trunk/timgno/xnews/templates/blocks/xnews_block_topics.html
XoopsModules/xnews/trunk/timgno/xnews/templates/blocks/xnews_tag_block_cloud.html
XoopsModules/xnews/trunk/timgno/xnews/templates/blocks/xnews_tag_block_top.html
XoopsModules/xnews/trunk/timgno/xnews/templates/index.html
XoopsModules/xnews/trunk/timgno/xnews/templates/xnews_archive.html
XoopsModules/xnews/trunk/timgno/xnews/templates/xnews_article.html
XoopsModules/xnews/trunk/timgno/xnews/templates/xnews_article_pdf.html
XoopsModules/xnews/trunk/timgno/xnews/templates/xnews_by_this_author.html
XoopsModules/xnews/trunk/timgno/xnews/templates/xnews_by_topic.html
XoopsModules/xnews/trunk/timgno/xnews/templates/xnews_index.html
XoopsModules/xnews/trunk/timgno/xnews/templates/xnews_item.html
XoopsModules/xnews/trunk/timgno/xnews/templates/xnews_item_pdf.html
XoopsModules/xnews/trunk/timgno/xnews/templates/xnews_ratenews.html
XoopsModules/xnews/trunk/timgno/xnews/templates/xnews_rss.html
XoopsModules/xnews/trunk/timgno/xnews/templates/xnews_topics_directory.html
XoopsModules/xnews/trunk/timgno/xnews/templates/xnews_whos_who.html
XoopsModules/xnews/trunk/timgno/xnews/topics_directory.php
XoopsModules/xnews/trunk/timgno/xnews/view.tag.php
XoopsModules/xnews/trunk/timgno/xnews/visit.php
XoopsModules/xnews/trunk/timgno/xnews/whoswho.php
XoopsModules/xnews/trunk/timgno/xnews/xoops_version.php
Added: XoopsModules/xnews/trunk/timgno/xnews/.htaccess
===================================================================
--- XoopsModules/xnews/trunk/timgno/xnews/.htaccess (rev 0)
+++ XoopsModules/xnews/trunk/timgno/xnews/.htaccess 2012-01-31 18:04:15 UTC (rev 8847)
@@ -0,0 +1,10 @@
+## Copy htaccess file to your module root dir and rename to .htaccess
+
+RewriteEngine On
+## xnews - begin ##
+RewriteCond %{request_uri} !^/xnews/([a-z\x2D]+)\.([a-z]+)\.([0-9.]+)
+RewriteRule ^([a-z\x2D]+)\.([a-z]+)\.([0-9.]+)/ ?seoOp=$2&seoArg=$3 [L,NC,QSA]
+
+RewriteCond %{request_uri} !^/xnews/([a-z]+)\.([0-9.]+)
+RewriteRule ^([a-z]+)\.([0-9.]+)/ ?seoOp=$1&seoArg=$2 [L,NC,QSA]
+## xnews - endRewriteCond %{HTTP_REFERER} !^$
\ No newline at end of file
Added: XoopsModules/xnews/trunk/timgno/xnews/admin/Copia di index.php
===================================================================
--- XoopsModules/xnews/trunk/timgno/xnews/admin/Copia di index.php (rev 0)
+++ XoopsModules/xnews/trunk/timgno/xnews/admin/Copia di index.php 2012-01-31 18:04:15 UTC (rev 8847)
@@ -0,0 +1,394 @@
+<?php
+/**
+* Module: xNews Import
+* Author: DNPROSSI
+* Licence: GNU
+*/
+
+include_once dirname(__FILE__) . "/header.php";
+include_once '../../../include/cp_header.php';
+include_once XNI_MODULE_PATH . '/include/functions.php';
+include_once XNI_MODULE_PATH . '/admin/functions.php';
+include_once XNI_MODULE_PATH . '/class/class.newstopic.php';
+include_once XNI_MODULE_PATH . '/class/class.newsstory.php';
+include_once XNI_MODULE_PATH . '/class/class.xnewsimport.php';
+
+function NewsImport()
+{
+ global $xoopsDB;
+ xoops_cp_header();
+ $importfrom = 'none';
+ $importto = 'none';
+
+ adminMenu(0, _AM_XNI_IMPORT);
+
+ echo "<h1>" . _AM_XNI_IMPORT_TITLE . "</h1>";
+ echo _AM_XNI_IMPORT_INFO . "<br /><br />";
+
+ xoops_load('XoopsFormLoader');
+
+ // Iterate through installed modules tables for articles, items, category,
+ // topics and add them to selectlist
+ // This will also find clones
+ $news_fieldsearch_array = array(
+ 'topic_id',
+ 'topic_pid',
+ 'banner'
+ );
+
+ $other_fieldsearch_array = array(
+ 'categoryid',
+ 'parentid',
+ 'moderator'
+ );
+
+ //Get From Module Data
+ $module_handler =& xoops_gethandler('module');
+ $installed_mods = $module_handler->getObjects();
+ $listed_mods = array();
+ $count = 0;
+ foreach ( $installed_mods as $module ) {
+ if ( $module->getVar('dirname') != 'system' && $module->getVar('isactive') == 1 ) {
+ $module->loadInfo($module->getVar('dirname'));
+ $modtables = $module->getInfo('tables');
+ if ( $modtables != false && is_array($modtables) ) {
+ foreach ( $modtables as $table ) {
+ $newscount = 0;
+ foreach ($news_fieldsearch_array as $field ) {
+ if ( xni_fieldexists($field, $xoopsDB->prefix($table)) ) {
+ $newscount++;
+ }
+ }
+ if ( $newscount == 2 ) {
+ $from_module_version = round($module->getVar('version') / 100, 2);
+ if (($from_module_version >= 1.64)) {
+ $importfrom_array["news/" . $module->getVar('dirname')] = $module->getVar('dirname') . " " . $from_module_version;
+ }
+ }
+ /*} elseif ($newscount == 3) {
+ $from_module_version = round($module->getVar('version') / 100, 2);
+ if (($from_module_version >= 2.0)) {
+ $importfrom_array["ams/" . $module->getVar('dirname')] = $module->getVar('dirname') . " " . $from_module_version;
+ }
+ }
+ $smartcount = 0;
+ foreach ( $other_fieldsearch_array as $field ) {
+ if ( xni_fieldexists($field, $xoopsDB->prefix($table)) ) {
+ $smartcount++;
+ }
+ }
+ if ( $smartcount == 2 ) {
+ $from_module_version = round($module->getVar('version') / 100, 2);
+ if (($from_module_version >= 2.0)) {
+ $importfrom_array["smartsection/" . $module->getVar('dirname')] = $module->getVar('dirname') . " " . $from_module_version;
+ }
+ } elseif ($smartcount == 3) {
+ $from_module_version = round($module->getVar('version') / 100, 2);
+ if (($from_module_version >= 1.0)) {
+ $importfrom_array["publisher/" . $module->getVar('dirname')] = $module->getVar('dirname') . " " . $from_module_version;
+ }
+ }*/
+ }
+ }
+ }
+ }
+
+ $result = $xoopsDB->query("SELECT * FROM " . $xoopsDB->prefix('news_clonerdata') . " WHERE clone_installed = 1");
+ $ix = 0;
+ while ( $clone = $xoopsDB->fetchArray($result) ) {
+ $importto_array[$ix] = $clone['clone_dir'];
+ $ix++;
+ }
+
+ if (isset($importfrom_array) && count($importfrom_array) > 0 && isset($importto_array) && count($importto_array) > 0) {
+
+ $sform = new XoopsThemeForm(_AM_XNI_IMPORT_SELECTION, "op", xoops_getenv('PHP_SELF'));
+ $sform->setExtra('enctype="multipart/form-data"');
+
+ // Partners to import from
+ $importfrom = new XoopsFormSelect('', 'importfrom', $importfrom);
+ $importfrom->addOptionArray($importfrom_array);
+ $importfrom_tray = new XoopsFormElementTray(_AM_XNI_IMPORT_FROM , ' ');
+ $importfrom_tray->addElement($importfrom);
+ $importfrom_tray->setDescription(_AM_XNI_IMPORT_FROM_DSC);
+ $sform->addElement($importfrom_tray);
+
+ // xNews & clones to import to
+ $importto = new XoopsFormSelect('', 'importto', $importto);
+ $importto->addOptionArray($importto_array);
+ $importto_tray = new XoopsFormElementTray(_AM_XNI_IMPORT_TO , ' ');
+ $importto_tray->addElement($importto);
+ $importto_tray->setDescription(_AM_XNI_IMPORT_TO_DSC);
+ $sform->addElement($importto_tray);
+
+ // Buttons
+ $button_tray = new XoopsFormElementTray('', '');
+ $hidden = new XoopsFormHidden('op', 'topicselect');
+ $button_tray->addElement($hidden);
+
+ $butt_import = new XoopsFormButton('', '', _AM_XNI_IMPORT, 'submit');
+ $butt_import->setExtra('onclick="this.form.elements.op.value=\'topicselect\'"');
+ $button_tray->addElement($butt_import);
+
+ $butt_cancel = new XoopsFormButton('', '', _AM_XNI_CANCEL, 'button');
+ $butt_cancel->setExtra('onclick="history.go(-1)"');
+ $button_tray->addElement($butt_cancel);
+ $sform->addElement($button_tray);
+ $sform->display();
+ unset($hidden);
+ } else {
+ echo "<span style=\"color: #567; margin: 3px 0 12px 0; font-weight: bold; font-size: small; display: block; \">" . _AM_XNI_IMPORT_NO_MODULE . "</span>";
+ }
+}
+
+function TopicSelect()
+{
+ xoops_cp_header();
+ echo '<script type="text/javascript" src="' . XNI_MODULE_URL . '/js/funcs.js"></script>';
+ xoops_load('XoopsFormLoader');
+
+ adminMenu(0, _AM_XNI_IMPORT);
+ global $xoopsDB;
+
+ $begin = isset($_GET['begin']) ? intval($_GET['begin']) : 0;
+ include_once XOOPS_ROOT_PATH . '/class/xoopstree.php';
+ include_once XOOPS_ROOT_PATH . '/class/xoopstopic.php';
+ include_once XOOPS_ROOT_PATH . '/class/xoopslists.php';
+ include_once XOOPS_ROOT_PATH . '/class/pagenav.php';
+ include_once XOOPS_ROOT_PATH . '/class/tree.php';
+ $myts =& MyTextSanitizer::getInstance();
+
+ //Detect in out modules and prepare form
+ $from_import = (isset($_POST['importfrom'])) ? $_POST['importfrom'] : 'nonselected';
+ $to_import_clone_id = (isset($_POST['importto'])) ? $_POST['importto'] : 'nonselected';
+
+ $options = explode('/', $from_import);
+
+ $from_import_type = $options[0];
+ $from_import_dirname = $options[1];
+
+ //Get selected xNews module or clone to import to
+ $result = $xoopsDB->query("SELECT * FROM " . $xoopsDB->prefix('news_clonerdata') . " WHERE clone_installed = 1");
+ $ix = 0;
+ while ( $clone = $xoopsDB->fetchArray($result) ) {
+ $clone_arr[$ix] = $clone;
+ $ix++;
+ }
+
+ $to_import_dirname = $clone_arr[$to_import_clone_id]['clone_dir'];
+ $to_subprefix = $clone_arr[$to_import_clone_id]['clone_subprefix'] . "_";
+
+ if ($from_import_dirname == $to_import_dirname)
+ {
+ //REDIRECT IF SAME
+ redirect_header('index.php?op=import', 2, "It's not possible to import the same ".$options[1]." module!");
+ }
+
+ $from_import_type = $options[0];
+ $from_import_dirname = $options[1];
+
+ $from_topic_id_type = '';
+ $from_topic_pid_type = '';
+ $from_topic_title_type = '';
+ $from_table_name = '';
+
+ //GET ALL MODULE-FROM DATA
+ $module_handler = &xoops_gethandler('module');
+ $from_module = &$module_handler->getByDirname($from_import_dirname);
+ $from_module->loadInfo($from_module->getVar('dirname'));
+
+ $from_modtables = $from_module->getInfo('tables');
+ if ( $from_modtables != false && is_array($from_modtables) ) {
+ foreach ( $from_modtables as $from_table ) {
+ $from_table_arr = explode('_', $from_table);
+ if ( count($from_table_arr) > 0 ) { //&& $from_import_dirname != 'news') {
+ if ($from_import_dirname != 'news') {
+ $subprefix = $from_table_arr[0] . "_";
+ } else {
+ $subprefix = '';
+ }
+ //trigger_error($subprefix . " NEWS ".$from_table_arr[0], E_USER_WARNING);
+ switch ($from_import_type) {
+ case 'news':
+ $from_subprefix = $subprefix;
+ $from_topics_arr = xni_gettopics($from_subprefix);
+ $from_topic_id = 'topic_id';
+ $from_topic_pid = 'topic_pid';
+ $from_topic_title = 'topic_title';
+ $from_topic_table = $from_subprefix . 'topics';
+ $from_story_table = $from_subprefix . 'stories';
+ break;
+ /*case 'ams':
+ $from_subprefix = $subprefix;
+ $from_topics_arr = xni_gettopics($from_subprefix);
+ $from_topic_id = 'topic_id';
+ $from_topic_pid = 'topic_pid';
+ $from_topic_title = 'topic_title';
+ $from_topic_table = $from_subprefix . 'topics';
+ $from_story_table = $from_subprefix . 'stories';
+ break;
+ case 'smartsection':
+ $from_subprefix = $subprefix;
+ $from_topics_arr = xni_getcategories($from_subprefix);
+ $from_topic_id = 'categoryid';
+ $from_topic_pid = 'parentid';
+ $from_topic_title = 'name';
+ $from_topic_table = $from_subprefix . 'categories';
+ $from_story_table = $from_subprefix . 'items';
+ break;
+ case 'publisher':
+ $from_subprefix = $subprefix;
+ $from_topics_arr = xni_getcategories($from_subprefix);
+ $from_topic_id = 'categoryid';
+ $from_topic_pid = 'parentid';
+ $from_topic_title = 'name';
+ $from_topic_table = $from_subprefix . 'categories';
+ $from_story_table = $from_subprefix . 'items';
+ break;*/
+ }
+
+ //trigger_error($from_table_arr[0], E_USER_WARNING);
+ }
+ }
+ }
+
+ //------------------------------------------------------------------
+
+ $result = $xoopsDB->query("SELECT COUNT(*) FROM " . $xoopsDB->prefix($from_topic_table));
+ list ($totalCat) = $xoopsDB->fetchRow($result);
+
+ if ($totalCat == 0) {
+ echo "<span style=\"color: #567; margin: 3px 0 12px 0; font-size: small; display: block; \">" . _AM_XNI_IMPORT_NO_CATEGORY . "</span>";
+ } else {
+
+ $result = $xoopsDB->query("SELECT COUNT(*) FROM " . $xoopsDB->prefix($from_story_table));
+ list ($totalArticles) = $xoopsDB->fetchRow($result);
+
+ if ($totalArticles == 0) {
+ echo "<span style=\"color: #567; margin: 3px 0 12px 0; font-size: small; display: block; \">" . sprintf(_AM_XNI_IMPORT_MODULE_FOUND_NO_ITEMS, $from_import_dirname, $totalArticles) . "</span>";
+ } else {
+ echo "<span style=\"color: #567; margin: 3px 0 12px 0; font-size: small; display: block; \">" . sprintf(_AM_XNI_IMPORT_MODULE_FOUND, $totalArticles, $totalCat, $from_import_dirname) . "</span>";
+
+ $form = new XoopsThemeForm(_AM_XNI_IMPORT_SETTINGS, 'import_form', XNI_MODULE_URL . "/admin/index.php");
+
+ $table_name = $from_topic_table;
+ $topiclist=new XoopsFormSelect(_AM_XNI_IMPORT_FROM_TOPICS, 'from_topics','',5,true);
+ $topics_arr=array();
+ $xt = new xni_NewsTopic();
+ $allTopics = $xt->getAllTopics($table_name, false); // The webmaster can see everything
+ $topic_tree = new XoopsObjectTree($allTopics, 'topic_id', 'topic_pid');
+ $topics_arr = $topic_tree->getAllChild(0);
+ if(count($topics_arr)) {
+ foreach ($topics_arr as $onetopic) {
+ $topiclist->addOption($onetopic->topic_id(),$onetopic->topic_title());
+ }
+ }
+ $topiclist->setDescription(_AM_XNI_IMPORT_FROM_TOPICS_DSC);
+ $form->addElement($topiclist, false);
+
+ /*$to_table_name = $to_subprefix . 'topics';
+ $to_topiclist=new XoopsFormSelect(_AM_XNI_IMPORT_TO_TOPICS, 'to_topic','',5,false);
+ $to_topics_arr=array();
+ $to_xt = new xni_NewsTopic();
+ $to_allTopics = $to_xt->getAllTopics($to_table_name, false); // The webmaster can see everything
+ $to_topic_tree = new XoopsObjectTree($to_allTopics, 'topic_id', 'topic_pid');
+ $to_topics_arr = $to_topic_tree->getAllChild(0);
+ if(count($to_topics_arr)) {
+ foreach ($to_topics_arr as $to_onetopic) {
+ $to_topiclist->addOption($to_onetopic->topic_id(),$to_onetopic->topic_title());
+ }
+ }
+ $to_topiclist->setDescription(_AM_XNI_IMPORT_TO_TOPICS_DSC);
+ $form->addElement($to_topiclist, false);
+ */
+ $form->addElement (new XoopsFormHidden('importfromdirname', $from_import_dirname));
+ $form->addElement (new XoopsFormHidden('importtodirname', $to_import_dirname));
+ $form->addElement (new XoopsFormHidden('importfromsubprefix', $from_subprefix));
+ $form->addElement (new XoopsFormHidden('importtosubprefix', $to_subprefix));
+
+ $form->addElement (new XoopsFormHidden('op', 'startimport'));
+ $form->addElement (new XoopsFormButton ('', 'import', _AM_XNI_IMPORT, 'submit'));
+
+ $form->display();
+ }
+ }
+ xoops_cp_footer();
+}
+
+function StartImport()
+{
+ global $xoopsDB, $xoopsConfig, $xoopsModule;
+
+ xoops_cp_header();
+
+ if (isset($_POST['importfromdirname']))
+ {
+ $from_module_dirname = $_POST['importfromdirname'];
+ $from_module_subprefix = $_POST['importfromsubprefix'];
+ $to_module_dirname = $_POST['importtodirname'];
+ $to_module_subprefix = $_POST['importtosubprefix'];
+ }
+
+ $module_handler =& xoops_gethandler('module');
+ $moduleObj = $module_handler->getByDirname($from_module_dirname);
+ $news_module_id = $moduleObj->getVar('mid');
+
+ $gperm_handler =& xoops_gethandler('groupperm');
+
+ $cnt_imported_cat = 0;
+ $cnt_imported_articles = 0;
+ $cnt_imported_comments = 0;
+ $cnt_imported_files = 0;
+
+ // If none selected then import all topics
+ if (!isset($_POST['from_topics']))
+ {
+ $resultCat = $xoopsDB->query("SELECT * FROM " . $xoopsDB->prefix($from_module_subprefix . "topics"));
+ include_once('import.php');
+ }
+ // Import selected topics
+ else
+ {
+ $ftpcs = $_POST['from_topics'];
+ $ftpcs = implode("', '", $ftpcs);
+ $resultCat = $xoopsDB->query("SELECT * FROM " . $xoopsDB->prefix($from_module_subprefix . "topics") . " WHERE topic_id IN ('".$ftpcs."')");
+ include_once('import.php');
+ }
+
+ xoops_cp_footer();
+}
+
+$op = 'none';
+
+if (isset($_GET['op'])) $op = $_GET['op'];
+if (isset($_POST['op'])) $op = $_POST['op'];
+
+switch ($op) {
+ case "startimport":
+ StartImport();
+ break;
+ case "topicselect":
+ TopicSelect();
+ break;
+
+ case "import":
+ NewsImport();
+ break;
+
+ case "default":
+ default:
+ xoops_cp_header();
+ adminmenu(-1);
+ echo '<h4>' . _AM_XNI_CONFIG . '</h4>';
+ echo"<table width='100%' border='0' cellspacing='1' class='outer'><tr><td width='59%' class=\"odd\" id=\"xo-newsicons\" >";
+ echo "<b><a href='index.php?op=import'><img src='" . XNI_MODULE_URL . "/images/import32.png' alt='' /><br/>" . _AM_XNI_IMPORT_TITLE . "</a></b>";
+ echo "<b><a href='" . XOOPS_URL . "/modules/system/admin.php?fct=preferences&op=showmod&mod=" . $xoopsModule -> getVar( 'mid' ) . "'><img src='" . NW_MODULE_URL . "/images/prefs32.png' alt='' /><br/>" . _AM_XNI_PREFERENCES . "</a></b>";
+ echo "<br /><br />\n";
+ echo"</td><td width='50%' class=\"even\" id=\"xo-newsicons\" >";
+ echo _AM_XNI_DESCRIPTION . "<br />";
+ echo "</td></tr></table>";
+ break;
+}
+
+xoops_cp_footer();
+?>
Added: XoopsModules/xnews/trunk/timgno/xnews/admin/about.php
===================================================================
--- XoopsModules/xnews/trunk/timgno/xnews/admin/about.php (rev 0)
+++ XoopsModules/xnews/trunk/timgno/xnews/admin/about.php 2012-01-31 18:04:15 UTC (rev 8847)
@@ -0,0 +1,44 @@
+<?php
+/**
+ * ****************************************************************************
+ * - Original Copyright (TDM)
+ * - TDMCreate By TDM - TEAM DEV MODULE FOR XOOPS
+ * - Licence GPL Copyright (c) (http://www.tdmxoops.net)
+ * - Developers TEAM TDMCreate Xoops - (http://www.xoops.org)
+ * ****************************************************************************
+ * XNEWS - MODULE FOR XOOPS
+ * Copyright (c) 2007 - 2011
+ * TXMod Xoops (http://www.txmodxoops.org)
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting
+ * source code which is considered copyrighted (c) material of the
+ * original comment or credit authors.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * ------------------------------------------------------------------------
+ *
+ * @copyright TXMod Xoops (http://www.txmodxoops.org)
+ * @license GPL see LICENSE
+ * @package xnews
+ * @author TXMod Xoops (in...@tx...)
+ *
+ * Version : 1.72 Tue 2011/12/13 22:29:37 : Timgno Exp $
+ * ****************************************************************************
+ */
+
+include "admin_header.php";
+xoops_cp_header();
+$aboutAdmin = new ModuleAdmin();
+echo $aboutAdmin->addNavigation("about.php");
+echo $aboutAdmin->renderabout('6KJ7RW5DR3VTJ', false);
+include "admin_footer.php";
\ No newline at end of file
Added: XoopsModules/xnews/trunk/timgno/xnews/admin/admin_footer.php
===================================================================
--- XoopsModules/xnews/trunk/timgno/xnews/admin/admin_footer.php (rev 0)
+++ XoopsModules/xnews/trunk/timgno/xnews/admin/admin_footer.php 2012-01-31 18:04:15 UTC (rev 8847)
@@ -0,0 +1,42 @@
+<?php
+/**
+ * ****************************************************************************
+ * - Original Copyright (TDM)
+ * - TDMCreate By TDM - TEAM DEV MODULE FOR XOOPS
+ * - Licence GPL Copyright (c) (http://www.tdmxoops.net)
+ * - Developers TEAM TDMCreate Xoops - (http://www.xoops.org)
+ * ****************************************************************************
+ * XNEWS - MODULE FOR XOOPS
+ * Copyright (c) 2007 - 2011
+ * TXMod Xoops (http://www.txmodxoops.org)
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting
+ * source code which is considered copyrighted (c) material of the
+ * original comment or credit authors.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * ------------------------------------------------------------------------
+ *
+ * @copyright TXMod Xoops (http://www.txmodxoops.org)
+ * @license GPL see LICENSE
+ * @package xnews
+ * @author TXMod Xoops (in...@tx...)
+ *
+ * Version : 1.72 Tue 2011/12/13 22:29:37 : Timgno Exp $
+ * ****************************************************************************
+ */
+ global $pathImageAdmin;
+
+echo "<div align=\"center\"><a href=\"http://www.xoops.org\" target=\"_blank\"><img src=" . $pathImageAdmin.'/xoopsmicrobutton.gif'.' '." alt='XOOPS' title='XOOPS'></a></div>";
+echo "<div class='center smallsmall italic pad5'><strong>" . $xoopsModule->getVar("name") . "</strong> is maintained by the <a class='tooltip' rel='external' href='http://www.xoops.org/' title='Visit XOOPS Community'>XOOPS Community</a></div>";
+ xoops_cp_footer();
\ No newline at end of file
Added: XoopsModules/xnews/trunk/timgno/xnews/admin/admin_header.php
===================================================================
--- XoopsModules/xnews/trunk/timgno/xnews/admin/admin_header.php (rev 0)
+++ XoopsModules/xnews/trunk/timgno/xnews/admin/admin_header.php 2012-01-31 18:04:15 UTC (rev 8847)
@@ -0,0 +1,130 @@
+<?php
+/**
+ * ****************************************************************************
+ * - Original Copyright (TDM)
+ * - TDMCreate By TDM - TEAM DEV MODULE FOR XOOPS
+ * - Licence GPL Copyright (c) (http://www.tdmxoops.net)
+ * - Developers TEAM TDMCreate Xoops - (http://www.xoops.org)
+ * ****************************************************************************
+ * XNEWS - MODULE FOR XOOPS
+ * Copyright (c) 2007 - 2011
+ * TXMod Xoops (http://www.txmodxoops.org)
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting
+ * source code which is considered copyrighted (c) material of the
+ * original comment or credit authors.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * ------------------------------------------------------------------------
+ *
+ * @copyright TXMod Xoops (http://www.txmodxoops.org)
+ * @license GPL see LICENSE
+ * @package xnews
+ * @author TXMod Xoops (in...@tx...)
+ *
+ * Version : 1.72 Tue 2011/12/13 22:29:37 : Timgno Exp $
+ * ****************************************************************************
+ */
+include_once dirname(dirname(dirname(dirname(__FILE__)))) . "/mainfile.php";
+include_once XOOPS_ROOT_PATH."/include/cp_functions.php";
+/*include_once(XOOPS_ROOT_PATH."/kernel/module.php");
+include_once XOOPS_ROOT_PATH."/class/xoopsformloader.php";
+include_once XOOPS_ROOT_PATH."/class/tree.php";
+include_once XOOPS_ROOT_PATH."/class/xoopslists.php";
+include_once "../include/static_var.php";
+include_once "../include/functions.php";*/
+
+define("NW_SUBPREFIX", "nw");
+define("NW_MODULE_DIR_NAME", "xnews");
+define("NW_MODULE_PATH", XOOPS_ROOT_PATH . "/modules/" . NW_MODULE_DIR_NAME);
+define("NW_MODULE_URL", XOOPS_URL . "/modules/" . NW_MODULE_DIR_NAME);
+define("NW_UPLOADS_NEWS_PATH", XOOPS_ROOT_PATH . "/uploads/" . NW_MODULE_DIR_NAME);
+define("NW_TOPICS_FILES_PATH", XOOPS_ROOT_PATH . "/uploads/" . NW_MODULE_DIR_NAME . "/topics");
+define("NW_ATTACHED_FILES_PATH", XOOPS_ROOT_PATH . "/uploads/" . NW_MODULE_DIR_NAME . "/attached");
+define("NW_TOPICS_FILES_URL", XOOPS_URL . "/uploads/" . NW_MODULE_DIR_NAME . "/topics");
+define("NW_ATTACHED_FILES_URL", XOOPS_URL . "/uploads/" . NW_MODULE_DIR_NAME . "/attached");
+
+include_once XOOPS_ROOT_PATH.'/class/xoopstopic.php';
+include_once XOOPS_ROOT_PATH.'/class/xoopslists.php';
+include_once NW_MODULE_PATH . '/config.php';
+include_once NW_MODULE_PATH . '/class/class.newsstory.php';
+include_once NW_MODULE_PATH . '/class/class.newstopic.php';
+include_once NW_MODULE_PATH . '/class/class.sfiles.php';
+include_once NW_MODULE_PATH . '/class/blacklist.php';
+include_once NW_MODULE_PATH . '/class/registryfile.php';
+include_once XOOPS_ROOT_PATH.'/class/uploader.php';
+include_once NW_MODULE_PATH . '/admin/functions.php';
+include_once NW_MODULE_PATH . '/include/functions.php';
+include_once XOOPS_ROOT_PATH.'/class/tree.php';
+$dateformat=xnews_getmoduleoption('dateformat', NW_MODULE_DIR_NAME);
+$myts =& MyTextSanitizer::getInstance();
+$topicscount=0;
+
+$storiesTableName = $xoopsDB->prefix('xnews_stories');
+/*if(!nw_FieldExists('picture', $storiesTableName)) {
+ nw_AddField('`picture` VARCHAR( 50 ) NOT NULL', $storiesTableName);
+}*/
+
+$pathDir = $GLOBALS['xoops']->path('/Frameworks/moduleclasses/moduleadmin');
+$globlang = $GLOBALS['xoopsConfig']['language'];
+
+if ( file_exists($pathDir.'/language/'.$globlang.'/main.php')){
+ include_once $pathDir.'/language/'.$globlang.'/main.php';
+ }else{
+ include_once $pathDir.'/language/english/main.php';
+ }
+
+if ( file_exists($pathDir.'/moduleadmin.php')){
+ include_once $pathDir.'/moduleadmin.php';
+ //return true;
+ }else{
+ xoops_cp_header();
+ echo xoops_error(_AM_ERROR_NOFRAMEWORKS);
+ xoops_cp_footer();
+ //return false;
+ }
+$dirname = basename( dirname( dirname( __FILE__ ) ) );
+$module_handler =& xoops_gethandler("module");
+$xoopsModule =& XoopsModule::getByDirname($dirname);
+$moduleInfo =& $module_handler->get($xoopsModule->getVar("mid"));
+$pathImageIcon = XOOPS_URL .'/'. $moduleInfo->getInfo('icons16');
+$pathImageAdmin = XOOPS_URL .'/'. $moduleInfo->getInfo('icons32');
+
+$topicsHandler=& xoops_getModuleHandler('xnews_topics','xnews');
+$storiesHandler=& xoops_getModuleHandler('xnews_stories','xnews');
+
+$myts =& MyTextSanitizer::getInstance();
+
+if ($xoopsUser) {
+ $moduleperm_handler =& xoops_gethandler('groupperm');
+ if (!$moduleperm_handler->checkRight('module_admin', $xoopsModule->getVar( 'mid' ), $xoopsUser->getGroups())) {
+ redirect_header(XOOPS_URL, 1, _NOPERM);
+ exit();
+ }
+} else {
+ redirect_header(XOOPS_URL . "/user.php", 1, _NOPERM);
+ exit();
+}
+
+if (!isset($xoopsTpl) || !is_object($xoopsTpl)) {
+ include_once(XOOPS_ROOT_PATH."/class/template.php");
+ $xoopsTpl = new XoopsTpl();
+}
+
+$xoopsTpl->assign('pathImageIcon', $pathImageIcon);
+$xoopsTpl->assign('pathImageAdmin', $pathImageAdmin);
+
+//Load languages
+xoops_loadLanguage('admin', $xoopsModule->getVar("dirname"));
+xoops_loadLanguage('modinfo', $xoopsModule->getVar("dirname"));
+xoops_loadLanguage('main', $xoopsModule->getVar("dirname"));
\ No newline at end of file
Added: XoopsModules/xnews/trunk/timgno/xnews/admin/admin_header.php~
===================================================================
--- XoopsModules/xnews/trunk/timgno/xnews/admin/admin_header.php~ (rev 0)
+++ XoopsModules/xnews/trunk/timgno/xnews/admin/admin_header.php~ 2012-01-31 18:04:15 UTC (rev 8847)
@@ -0,0 +1,133 @@
+<?php
+/**
+ * ****************************************************************************
+ * - Original Copyright (TDM)
+ * - TDMCreate By TDM - TEAM DEV MODULE FOR XOOPS
+ * - Licence GPL Copyright (c) (http://www.tdmxoops.net)
+ * - Developers TEAM TDMCreate Xoops - (http://www.xoops.org)
+ * ****************************************************************************
+ * XNEWS - MODULE FOR XOOPS
+ * Copyright (c) 2007 - 2011
+ * TXMod Xoops (http://www.txmodxoops.org)
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting
+ * source code which is considered copyrighted (c) material of the
+ * original comment or credit authors.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * ------------------------------------------------------------------------
+ *
+ * @copyright TXMod Xoops (http://www.txmodxoops.org)
+ * @license GPL see LICENSE
+ * @package xnews
+ * @author TXMod Xoops (in...@tx...)
+ *
+ * Version : 1.72 Tue 2011/12/13 22:29:37 : Timgno Exp $
+ * ****************************************************************************
+ */
+include_once dirname(dirname(dirname(dirname(__FILE__)))) . "/mainfile.php";
+/*include_once XOOPS_ROOT_PATH."/include/cp_functions.php";
+include_once(XOOPS_ROOT_PATH."/kernel/module.php");
+include_once XOOPS_ROOT_PATH."/class/xoopsformloader.php";
+include_once XOOPS_ROOT_PATH."/class/tree.php";
+include_once XOOPS_ROOT_PATH."/class/xoopslists.php";
+include_once XOOPS_ROOT_PATH.'/class/pagenav.php';
+include_once XOOPS_ROOT_PATH.'/class/xoopsform/grouppermform.php';
+include_once "../include/static_var.php";
+include_once "../include/functions.php";*/
+
+define("NW_SUBPREFIX", "nw");
+define("NW_MODULE_DIR_NAME", "xnews");
+define("NW_MODULE_PATH", XOOPS_ROOT_PATH . "/modules/" . NW_MODULE_DIR_NAME);
+define("NW_MODULE_URL", XOOPS_URL . "/modules/" . NW_MODULE_DIR_NAME);
+define("NW_UPLOADS_NEWS_PATH", XOOPS_ROOT_PATH . "/uploads/" . NW_MODULE_DIR_NAME);
+define("NW_TOPICS_FILES_PATH", XOOPS_ROOT_PATH . "/uploads/" . NW_MODULE_DIR_NAME . "/topics");
+define("NW_ATTACHED_FILES_PATH", XOOPS_ROOT_PATH . "/uploads/" . NW_MODULE_DIR_NAME . "/attached");
+define("NW_TOPICS_FILES_URL", XOOPS_URL . "/uploads/" . NW_MODULE_DIR_NAME . "/topics");
+define("NW_ATTACHED_FILES_URL", XOOPS_URL . "/uploads/" . NW_MODULE_DIR_NAME . "/attached");
+
+include_once XOOPS_ROOT_PATH.'/class/xoopstopic.php';
+include_once XOOPS_ROOT_PATH.'/class/xoopslists.php';
+include_once NW_MODULE_PATH . '/config.php';
+include_once NW_MODULE_PATH . '/class/class.newsstory.php';
+include_once NW_MODULE_PATH . '/class/class.newstopic.php';
+include_once NW_MODULE_PATH . '/class/class.sfiles.php';
+include_once NW_MODULE_PATH . '/class/blacklist.php';
+include_once NW_MODULE_PATH . '/class/registryfile.php';
+include_once XOOPS_ROOT_PATH.'/class/uploader.php';
+include_once XOOPS_ROOT_PATH.'/class/pagenav.php';
+include_once NW_MODULE_PATH . '/admin/functions.php';
+include_once NW_MODULE_PATH . '/include/functions.php';
+include_once XOOPS_ROOT_PATH.'/class/tree.php';
+$dateformat=nw_getmoduleoption('dateformat', NW_MODULE_DIR_NAME);
+$myts =& MyTextSanitizer::getInstance();
+$topicscount=0;
+
+$storiesTableName = $xoopsDB->prefix('nw_stories');
+if(!nw_FieldExists('picture', $storiesTableName)) {
+ nw_AddField('`picture` VARCHAR( 50 ) NOT NULL', $storiesTableName);
+}
+
+$pathDir = $GLOBALS['xoops']->path('/Frameworks/moduleclasses/moduleadmin');
+$globlang = $GLOBALS['xoopsConfig']['language'];
+
+if ( file_exists($pathDir.'/language/'.$globlang.'/main.php')){
+ include_once $pathDir.'/language/'.$globlang.'/main.php';
+ }else{
+ include_once $pathDir.'/language/english/main.php';
+ }
+
+if ( file_exists($pathDir.'/moduleadmin.php')){
+ include_once $pathDir.'/moduleadmin.php';
+ //return true;
+ }else{
+ xoops_cp_header();
+ echo xoops_error(_AM_ERROR_NOFRAMEWORKS);
+ xoops_cp_footer();
+ //return false;
+ }
+$dirname = basename( dirname( dirname( __FILE__ ) ) );
+$module_handler =& xoops_gethandler("module");
+$xoopsModule =& XoopsModule::getByDirname($dirname);
+$moduleInfo =& $module_handler->get($xoopsModule->getVar("mid"));
+$pathImageIcon = XOOPS_URL .'/'. $moduleInfo->getInfo('icons16');
+$pathImageAdmin = XOOPS_URL .'/'. $moduleInfo->getInfo('icons32');
+
+$topicsHandler=& xoops_getModuleHandler('xnews_topics','xnews');
+$storiesHandler=& xoops_getModuleHandler('xnews_stories','xnews');
+
+$myts =& MyTextSanitizer::getInstance();
+
+if ($xoopsUser) {
+ $moduleperm_handler =& xoops_gethandler('groupperm');
+ if (!$moduleperm_handler->checkRight('module_admin', $xoopsModule->getVar( 'mid' ), $xoopsUser->getGroups())) {
+ redirect_header(XOOPS_URL, 1, _NOPERM);
+ exit();
+ }
+} else {
+ redirect_header(XOOPS_URL . "/user.php", 1, _NOPERM);
+ exit();
+}
+
+if (!isset($xoopsTpl) || !is_object($xoopsTpl)) {
+ include_once(XOOPS_ROOT_PATH."/class/template.php");
+ $xoopsTpl = new XoopsTpl();
+}
+
+$xoopsTpl->assign('pathImageIcon', $pathImageIcon);
+$xoopsTpl->assign('pathImageAdmin', $pathImageAdmin);
+
+//Load languages
+xoops_loadLanguage('admin', $xoopsModule->getVar("dirname"));
+xoops_loadLanguage('modinfo', $xoopsModule->getVar("dirname"));
+xoops_loadLanguage('main', $xoopsModule->getVar("dirname"));
\ No newline at end of file
Added: XoopsModules/xnews/trunk/timgno/xnews/admin/clonate.php
===================================================================
--- XoopsModules/xnews/trunk/timgno/xnews/admin/clonate.php (rev 0)
+++ XoopsModules/xnews/trunk/timgno/xnews/admin/clonate.php 2012-01-31 18:04:15 UTC (rev 8847)
@@ -0,0 +1,394 @@
+<?php
+/**
+ * ****************************************************************************
+ * - Original Copyright (TDM)
+ * - TDMCreate By TDM - TEAM DEV MODULE FOR XOOPS
+ * - Licence GPL Copyright (c) (http://www.tdmxoops.net)
+ * - Developers TEAM TDMCreate Xoops - (http://www.xoops.org)
+ * ****************************************************************************
+ * XNEWS - MODULE FOR XOOPS
+ * Copyright (c) 2007 - 2011
+ * TXMod Xoops (http://www.txmodxoops.org)
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting
+ * source code which is considered copyrighted (c) material of the
+ * original comment or credit authors.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * ------------------------------------------------------------------------
+ *
+ * @copyright TXMod Xoops (http://www.txmodxoops.org)
+ * @license GPL see LICENSE
+ * @package xnews
+ * @author TXMod Xoops (in...@tx...)
+ *
+ * Version : 1.72 Tue 2011/12/13 22:29:36 : Timgno Exp $
+ * ****************************************************************************
+ */
+include "admin_header.php";
+xoops_cp_header();
+
+$op = xnews_CleanVars($_REQUEST, 'op', 'default', 'string');
+$clonerAdmin = new ModuleAdmin();
+switch ($op)
+{
+ case 'default':
+ default:
+ echo $clonerAdmin->addNavigation("clonate.php");
+ $clonerAdmin->addItemButton(_AM_XNEWS_ADDCLONE, 'clonate.php?op=add_clone', 'add');
+ echo $clonerAdmin->renderButton();
+ global $xoopsDB, $xoopsConfig, $xoopsModule, $myts;
+ include_once XOOPS_ROOT_PATH.'/class/xoopsformloader.php';
+
+ $clone_modulename = '';
+
+ $start = isset($_GET['start']) ? intval($_GET['start']) : 0;
+
+ $result = $xoopsDB->query('SELECT * FROM ' . $xoopsDB->prefix('news_clonerdata'));
+ $ix = 0;
+ $iy = 0;
+ $clone_arr = array();
+ while ( $clone = $xoopsDB->fetchArray($result) ) {
+ //DNPROSSI - Control if clone dir exists
+ if ( is_dir(XOOPS_ROOT_PATH . "/modules/" . $clone['clone_dir']) ) {
+ $clone_arr[$ix] = $clone;
+ $ix++;
+ } else {
+ $nonclone_arr[$iy] = $clone;
+ $iy++;
+ }
+ }
+ // If cloned dir does not exists because deleted remove from dtb
+ if ( isset($nonclone_arr) ) {
+ for ($iy = 0; $iy < count($nonclone_arr); $iy++) {
+ $result = $xoopsDB->queryF("DELETE FROM " . $xoopsDB->prefix('news_clonerdata') . " WHERE clone_dir = '" . $nonclone_arr[$iy]['clone_dir'] . "' ;");
+ }
+ }
+
+ $totalclones = count($clone_arr);
+ $class='';
+
+ //echo '<h2>' . _AM_XNEWS_CLONER . '</h2>';
+ //xnews_collapsableBar('NewsCloner', 'topNewsCloner');
+ //echo "<img onclick=\"toggle('toptable'); toggleIcon('toptableicon');\" id='topNewsCloner' name='topNewsCloner' src='" . NW_MODULE_URL . "/images/close12.gif' alt='' /></a> " . _AM_XNEWS_CLONER_CLONES . ' (' . $totalclones . ')'."</h4>";
+ echo "<div id='NewsCloner'>";
+ echo '<br />';
+ echo "<div style='text-align: center;'>";
+ echo "<table width='100%' cellspacing='1' cellpadding='3' border='0' class='outer'><tr class='bg5'><th align='center'>" . _AM_XNEWS_CLONER_NAME . "</th><th align='center'>" . _AM_XNEWS_CLONER_DIRFOL . "</th><th align='center'>" . _AM_XNEWS_SUBPREFIX . "</th><th align='center'>" . _AM_XNEWS_CLONER_VERSION . "</th><th align='center'>" . _AM_XNEWS_ACTION . "</th><th align='center'>" . _AM_XNEWS_CLONER_ACTION_INSTALL . "</th></tr>";
+ if(is_array($clone_arr) && $totalclones) {
+ $cpt=1;
+ $tmpcpt=$start;
+ $ok=true;
+ $output='';
+ while($ok) {
+ if($tmpcpt < $totalclones) {
+ //DNPROSSI - Upgrade if clone version is different from original news version
+ //DNPROSSI - Install if cloned
+ if ( $clone_arr[$tmpcpt]['clone_dir'] != $clone_arr[0]['clone_dir'] ) {
+ if ( $clone_arr[$tmpcpt]['clone_version'] != $clone_arr[0]['clone_version'] )
+ {
+ $linkupgrade = NW_MODULE_URL . '/admin/clonate.php?op=cloneupgrade&clone_id=' . $clone_arr[$tmpcpt]['clone_id'];
+ $action = sprintf("<a href='%s'>%s</a>", $linkupgrade, _AM_XNEWS_UPGRADE);
+ if ( $clone_arr[$tmpcpt]['clone_installed'] == 1 )
+ {
+ $linkupgrade = XOOPS_URL . '/modules/system/admin.php?fct=modulesadmin&op=uninstall&module=' . $clone_arr[$tmpcpt]['clone_dir'];
+ $installaction = sprintf("<a href='%s'>%s</a>", $linkupgrade, _AM_XNEWS_CLONER_UNINSTALL);
+ } else {
+ $linkupgrade = XOOPS_URL . '/modules/system/admin.php?fct=modulesadmin&op=install&module=' . $clone_arr[$tmpcpt]['clone_dir'];
+ $linkdelete = NW_MODULE_URL . '/admin/clonate.php?op=clonedelete&clone_id=' . $clone_arr[$tmpcpt]['clone_id'];
+ $installaction = sprintf("<a href='%s'>%s</a> - <a href='%s'>%s</a>", $linkupgrade, _AM_XNEWS_CLONER_INSTALL, $linkdelete, _AM_XNEWS_DELETE);
+ }
+ } else {
+ $linkforce = NW_MODULE_URL . '/admin/clonate.php?op=cloneupgrade&clone_id=' . $clone_arr[$tmpcpt]['clone_id'];
+ $action=sprintf( _AM_XNEWS_CLONER_CLONEUPGRADED . " - <a href='%s'>%s</a>", $linkforce, _AM_XNEWS_CLONER_UPGRADEFORCE);
+ if ( $clone_arr[$tmpcpt]['clone_installed'] == 1 )
+ {
+ $linkupgrade = XOOPS_URL . '/modules/system/admin.php?fct=modulesadmin&op=uninstall&module=' . $clone_arr[$tmpcpt]['clone_dir'];
+ $installaction = sprintf("<a href='%s'>%s</a>", $linkupgrade, _AM_XNEWS_CLONER_UNINSTALL);
+ } else {
+ $linkupgrade = XOOPS_URL . '/modules/system/admin.php?fct=modulesadmin&op=install&module=' . $clone_arr[$tmpcpt]['clone_dir'];
+ $linkdelete = NW_MODULE_URL . '/admin/clonate.php?op=clonedelete&clone_id=' . $clone_arr[$tmpcpt]['clone_id'];
+ $installaction = sprintf("<a href='%s'>%s</a> - <a href='%s'>%s</a>", $linkupgrade, _AM_XNEWS_CLONER_INSTALL, $linkdelete, _AM_XNEWS_DELETE);
+ }
+ }
+ } else {
+ $linkupgrade = XOOPS_URL . '/modules/system/admin.php?fct=modulesadmin&op=update&module=' . $clone_arr[$tmpcpt]['clone_dir'];
+ $action = sprintf("<a href='%s'>%s</a>", $linkupgrade, _AM_XNEWS_CLONER_UPDATE);
+ $installaction = '';
+ }
+ $class = ($class == 'even') ? 'odd' : 'even';
+ $output = $output . "<tr class='" . $class . "'><td align='center'>" . $clone_arr[$tmpcpt]['clone_name'] . "</td><td align='center'>" . $clone_arr[$tmpcpt]['clone_dir'] . "</td><td align='center'>" . $clone_arr[$tmpcpt]['clone_subprefix'] . "</td><td align='center'>" . round($clone_arr[$tmpcpt]['clone_version'] / 100, 2) . "</td><td>" . $action . "</td><td>" . $installaction . "</td></tr>";
+ } else {
+ $ok=false;
+ }
+ if($cpt>=xnews_getmoduleoption('storycountadmin', NW_MODULE_DIR_NAME)) {
+ $ok=false;
+ }
+ $tmpcpt++;
+ $cpt++;
+ }
+ echo $output;
+ }
+ $pagenav = new XoopsPageNav( $totalclones, xnews_getmoduleoption('storycountadmin', NW_MODULE_DIR_NAME), $start, 'start', 'op=clonemanager');
+ echo "</table><div align='right'>".$pagenav->renderNav().'</div><br />';
+ echo "</div></div><br />\n";
+
+ $clone_id = isset($_GET['clone_id']) ? intval($_GET['clone_id'])...
[truncated message content] |