You can subscribe to this list here.
| 2012 |
Jan
|
Feb
(214) |
Mar
(139) |
Apr
(198) |
May
(187) |
Jun
(151) |
Jul
(210) |
Aug
(169) |
Sep
(58) |
Oct
(53) |
Nov
(54) |
Dec
(301) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2013 |
Jan
(348) |
Feb
(178) |
Mar
(219) |
Apr
(154) |
May
(117) |
Jun
(194) |
Jul
(61) |
Aug
(132) |
Sep
(121) |
Oct
(110) |
Nov
(11) |
Dec
(18) |
| 2014 |
Jan
(34) |
Feb
(50) |
Mar
(82) |
Apr
(98) |
May
(39) |
Jun
(111) |
Jul
(67) |
Aug
(36) |
Sep
(33) |
Oct
(26) |
Nov
(53) |
Dec
(44) |
| 2015 |
Jan
(29) |
Feb
(47) |
Mar
(25) |
Apr
(19) |
May
(23) |
Jun
(20) |
Jul
(49) |
Aug
(7) |
Sep
(10) |
Oct
(10) |
Nov
(4) |
Dec
(25) |
| 2016 |
Jan
(8) |
Feb
(7) |
Mar
(1) |
Apr
|
May
(3) |
Jun
|
Jul
(1) |
Aug
(2) |
Sep
|
Oct
|
Nov
(7) |
Dec
(5) |
| 2017 |
Jan
(4) |
Feb
|
Mar
|
Apr
|
May
(15) |
Jun
|
Jul
(18) |
Aug
(24) |
Sep
|
Oct
(14) |
Nov
|
Dec
|
| 2018 |
Jan
|
Feb
(22) |
Mar
|
Apr
(11) |
May
(1) |
Jun
(17) |
Jul
(2) |
Aug
(2) |
Sep
|
Oct
(6) |
Nov
(5) |
Dec
|
| 2019 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(2) |
| 2025 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
|
|
From: <rgr...@us...> - 2013-10-22 17:13:46
|
Revision: 12192
http://sourceforge.net/p/xoops/svn/12192
Author: rgriffith
Date: 2013-10-22 17:13:44 +0000 (Tue, 22 Oct 2013)
Log Message:
-----------
Patch for input validation bypass issue reported by Tatane.
There are steps which should be taken but this should solve the most important issues.
Modified Paths:
--------------
XoopsCore/branches/2.5.x/2.5.7/htdocs/modules/profile/include/forms.php
XoopsCore/branches/2.5.x/2.5.7/htdocs/modules/profile/register.php
Modified: XoopsCore/branches/2.5.x/2.5.7/htdocs/modules/profile/include/forms.php
===================================================================
--- XoopsCore/branches/2.5.x/2.5.7/htdocs/modules/profile/include/forms.php 2013-10-21 09:25:26 UTC (rev 12191)
+++ XoopsCore/branches/2.5.x/2.5.7/htdocs/modules/profile/include/forms.php 2013-10-22 17:13:44 UTC (rev 12192)
@@ -279,6 +279,13 @@
*/
function profile_getRegisterForm(&$user, $profile, $step = null)
{
+ global $opkey; // should be set in register.php
+ if (empty($opkey)) {
+ $opkey='profile_opname';
+ }
+ $next_opname = 'op' . mt_rand(10000, 99999);
+ $_SESSION[$opkey] = $next_opname;
+
include_once $GLOBALS['xoops']->path('class/xoopsformloader.php');
if (empty($GLOBALS['xoopsConfigUser'])) {
$config_handler =& xoops_gethandler('config');
@@ -358,6 +365,7 @@
$reg_form->addElement(new XoopsFormCaptcha(), true);
}
+ $reg_form->addElement(new XoopsFormHidden($next_opname, 'register'));
$reg_form->addElement(new XoopsFormHidden('uid', $user->getVar('uid')));
$reg_form->addElement(new XoopsFormHidden('step', $step_no) );
$reg_form->addElement(new XoopsFormButton('', 'submitButton', _SUBMIT, 'submit'));
Modified: XoopsCore/branches/2.5.x/2.5.7/htdocs/modules/profile/register.php
===================================================================
--- XoopsCore/branches/2.5.x/2.5.7/htdocs/modules/profile/register.php 2013-10-21 09:25:26 UTC (rev 12191)
+++ XoopsCore/branches/2.5.x/2.5.7/htdocs/modules/profile/register.php 2013-10-22 17:13:44 UTC (rev 12192)
@@ -41,7 +41,19 @@
exit();
}
-$op = !isset($_POST['op']) ? 'register' : $_POST['op'];
+// get the key we need to access out 'op' in $_POST
+// if this key is not set, empty $_POST since this is a new registration and
+// no legitimate data would be there.
+$opkey = 'profile_opname';
+if (isset($_SESSION[$opkey])) {
+ $current_opname = $_SESSION[$opkey];
+ unset($_SESSION[$opkey]);
+} else {
+ $_POST=array();
+ $current_opname = 'op'; // does not matter, it isn't there
+}
+
+$op = !isset($_POST[$current_opname]) ? 'register' : $_POST[$current_opname];
$current_step = isset($_POST['step']) ? intval( $_POST['step'] ) : 0;
// The newly introduced variable $_SESSION['profile_post'] is contaminated by $_POST, thus we use an old vaiable to hold uid parameter
|
|
From: <go...@us...> - 2013-10-21 09:25:29
|
Revision: 12191
http://sourceforge.net/p/xoops/svn/12191
Author: goffy
Date: 2013-10-21 09:25:26 +0000 (Mon, 21 Oct 2013)
Log Message:
-----------
Modified Paths:
--------------
XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php 2013-10-21 09:19:26 UTC (rev 12190)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php 2013-10-21 09:25:26 UTC (rev 12191)
@@ -32,7 +32,7 @@
xoops_load('XoopsLists');
$modversion['name'] = _MI_XNEWSLETTER_NAME;
-$modversion['version'] = 1.1;
+$modversion['version'] = 1.2;
$modversion['description'] = _MI_XNEWSLETTER_DESC;
$modversion['author'] = "Goffy, Alfred";
$modversion['credits'] = "";
@@ -56,10 +56,10 @@
$modversion['module_website_url'] = "wedega.com";
$modversion['module_website_name'] = "Webdesign Gabor";
$modversion['release'] = "1.0";
-$modversion['module_status'] = "Stable";
+$modversion['module_status'] = "Final";
$modversion['release_info'] = "";
$modversion['release_file'] = XOOPS_URL."/modules/{$dirname}/docs/";
-$modversion['release_date'] = "2013/08/27";
+$modversion['release_date'] = "2013/10/20";
$modversion['manual'] = "xNewsletter.txt";
$modversion['manual_file'] = XOOPS_URL."/modules/{$dirname}/docs/";
|
|
From: <go...@us...> - 2013-10-21 09:19:30
|
Revision: 12190
http://sourceforge.net/p/xoops/svn/12190
Author: goffy
Date: 2013-10-21 09:19:26 +0000 (Mon, 21 Oct 2013)
Log Message:
-----------
added new block for general info (feichtl/goffy)
removed xoops captcha when unsubscribe by link (feichtl/goffy)
Modified Paths:
--------------
XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_subscr.php
XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt
XoopsModules/xnewsletter/trunk/xNewsletter/docs/lang_diff.txt
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php
XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php
Added Paths:
-----------
XoopsModules/xnewsletter/trunk/xNewsletter/blocks/blocks_subscrinfo.php
XoopsModules/xnewsletter/trunk/xNewsletter/templates/blocks/xnewsletter_subscrinfo_block.html
Added: XoopsModules/xnewsletter/trunk/xNewsletter/blocks/blocks_subscrinfo.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/blocks/blocks_subscrinfo.php (rev 0)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/blocks/blocks_subscrinfo.php 2013-10-21 09:19:26 UTC (rev 12190)
@@ -0,0 +1,40 @@
+<?php
+/**
+ * ****************************************************************************
+ * XNEWSLETTER - MODULE FOR XOOPS
+ * Copyright (c) 2012
+ * Goffy ( wedega.com )
+ *
+ * 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 Goffy ( wedega.com )
+ * @license GPL 2.0
+ * @package xNewsletter
+ * @author Goffy ( web...@we... )
+ *
+ * Version : 1 Mon 2012/11/05 14:31:32 : Exp $
+ * ****************************************************************************
+ */
+
+function b_xnewsletter_subscrinfo($options) {
+
+ xoops_loadLanguage('modinfo', "xNewsletter");
+ $unique_id = uniqid(mt_rand());
+ $subscrinfo = array();
+ $subscrinfo["formname"] = "formsubscrinfo_".$unique_id;
+ $subscrinfo["formaction"] = XOOPS_URL."/modules/xNewsletter/subscription.php";
+ $subscrinfo["infotext"] = _MI_XNEWSLETTER_SUBSCRINFO_TEXT_BLOCK;
+ $subscrinfo["buttontext"] = _MI_XNEWSLETTER_SUBSCRIBE;
+
+ return $subscrinfo;
+
+}
+?>
\ No newline at end of file
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_subscr.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_subscr.php 2013-10-21 08:49:51 UTC (rev 12189)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_subscr.php 2013-10-21 09:19:26 UTC (rev 12190)
@@ -67,8 +67,10 @@
$email_field->setExtra('disabled="disabled"');
}
$email_tray->addElement($email_field, false);
- $email_tray->addElement(new XoopsFormCaptcha('<br /><br />'), true);
- $email_tray->addElement(new XoopsFormButton("<br /><br />", "submit", _AM_XNEWSLETTER_SUBSCRIPTION_SEARCH_ADD, "submit"));
+ if ( $this->getVar("subscr_email") == "" ) {
+ $email_tray->addElement(new XoopsFormCaptcha('<br /><br />'), true);
+ $email_tray->addElement(new XoopsFormButton("<br /><br />", "submit", _AM_XNEWSLETTER_SUBSCRIPTION_SEARCH_ADD, "submit"));
+ }
$form->addElement($email_tray);
$form->addElement(new XoopsFormHidden("op", "exec_search"));
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt 2013-10-21 08:49:51 UTC (rev 12189)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt 2013-10-21 09:19:26 UTC (rev 12190)
@@ -1,5 +1,7 @@
Version 1.2
--------------
+ - added new block for general info (feichtl/goffy)
+ - removed xoops captcha when unsubscribe by link (feichtl/goffy)
- transfered error text to language file (feichtl/goffy)
- fixed bug when filter subscribers in admin/subscr.php (feichtl/goffy)
- french translation (pierredelu)
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/docs/lang_diff.txt
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/docs/lang_diff.txt 2013-10-21 08:49:51 UTC (rev 12189)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/docs/lang_diff.txt 2013-10-21 09:19:26 UTC (rev 12190)
@@ -15,3 +15,8 @@
----------
define("_AM_XNEWSLETTER_IMPORT_ERROR_NO_PLUGIN","Error: required file 'plugins/%p.php' not found!");
define("_AM_XNEWSLETTER_IMPORT_ERROR_NO_FUNCTION","Error: required function 'xnewsletter_plugin_getdata_%f' doesn't exist!");
+
+modinfo.php
+-----------
+define("_MI_XNEWSLETTER_SUBSCRINFO_BLOCK","Info Newsletter");
+define("_MI_XNEWSLETTER_SUBSCRINFO_TEXT_BLOCK","If you want to be informed in time, then subscribe to our newsletter");
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php 2013-10-21 08:49:51 UTC (rev 12189)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php 2013-10-21 09:19:26 UTC (rev 12190)
@@ -84,4 +84,7 @@
define('_MI_XNEWSLETTER_SEND_IN_PACKAGES_TIME', "Time period for sending e-mails in packages");
define('_MI_XNEWSLETTER_SEND_IN_PACKAGES_TIME_DESC', "Time period in minutes, when the next package should be sent. Only used, if 'Send e-mails in packages' is bigger than 0.");
define('_MI_XNEWSLETTER_UPGRADEFAILED', "Error while updating module");
+// version 1.2
+define("_MI_XNEWSLETTER_SUBSCRINFO_BLOCK","Info Newsletter");
+define("_MI_XNEWSLETTER_SUBSCRINFO_TEXT_BLOCK","If you want to be informed in time, then subscribe to our newsletter");
?>
\ No newline at end of file
Added: XoopsModules/xnewsletter/trunk/xNewsletter/templates/blocks/xnewsletter_subscrinfo_block.html
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/templates/blocks/xnewsletter_subscrinfo_block.html (rev 0)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/templates/blocks/xnewsletter_subscrinfo_block.html 2013-10-21 09:19:26 UTC (rev 12190)
@@ -0,0 +1,10 @@
+<form name="<{$block.formname}>" id="<{$block.formname}>" action="<{$block.formaction}>" method="post" enctype="multipart/form-data">
+ <table class="outer">
+ <tr class = "<{cycle values = "even,odd"}>">
+ <td style="text-align:center"><{$block.infotext}></td>
+ </tr>
+ <tr class = "<{cycle values = "even,odd"}>">
+ <td style="text-align:center"><input type="submit" class="formButton" name="submit" id="submit" value="<{$block.buttontext}>" title="<{$block.buttontext}>" /></td>
+ </tr>
+ </table>
+</form>
\ No newline at end of file
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php 2013-10-21 08:49:51 UTC (rev 12189)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php 2013-10-21 09:19:26 UTC (rev 12190)
@@ -22,7 +22,7 @@
* @package xNewsletter
* @author Goffy ( web...@we... )
*
- * Version : $Id: xoops_version.php 181 2013-08-31 20:32:00Z alfred $
+ * Version : $Id: xoops_version.php 200 2013-10-19 21:20:11Z goffy $
* ****************************************************************************
*/
@@ -32,7 +32,7 @@
xoops_load('XoopsLists');
$modversion['name'] = _MI_XNEWSLETTER_NAME;
-$modversion['version'] = 1.2;
+$modversion['version'] = 1.1;
$modversion['description'] = _MI_XNEWSLETTER_DESC;
$modversion['author'] = "Goffy, Alfred";
$modversion['credits'] = "";
@@ -56,10 +56,10 @@
$modversion['module_website_url'] = "wedega.com";
$modversion['module_website_name'] = "Webdesign Gabor";
$modversion['release'] = "1.0";
-$modversion['module_status'] = "Final";
+$modversion['module_status'] = "Stable";
$modversion['release_info'] = "";
$modversion['release_file'] = XOOPS_URL."/modules/{$dirname}/docs/";
-$modversion['release_date'] = "2013/10/20";
+$modversion['release_date'] = "2013/08/27";
$modversion['manual'] = "xNewsletter.txt";
$modversion['manual_file'] = XOOPS_URL."/modules/{$dirname}/docs/";
@@ -338,9 +338,20 @@
$b++;
$modversion['blocks'][$b] = array(
+ 'file' => 'blocks_subscrinfo.php' ,
+ 'name' => _MI_XNEWSLETTER_SUBSCRINFO_BLOCK ,
+ 'description' => '' ,
+ 'show_func' => 'b_xnewsletter_subscrinfo' ,
+ 'edit_func' => '' ,
+ 'template' => 'xnewsletter_subscrinfo_block.html',
+ 'can_clone' => true ,
+ 'options' => ''
+);
+
+$b++;
+$modversion['blocks'][$b] = array(
'file' => 'blocks_catsubscr.php' ,
'name' => _MI_XNEWSLETTER_CATSUBSCR_BLOCK_RECENT ,
- //'description' => _MI_APCAL_BNAME_MINICAL_DESC ,
'description' => '' ,
'show_func' => 'b_xnewsletter_catsubscr' ,
'edit_func' => 'b_xnewsletter_catsubscr_edit' ,
@@ -353,7 +364,6 @@
$modversion['blocks'][$b] = array(
'file' => 'blocks_catsubscr.php' ,
'name' => _MI_XNEWSLETTER_CATSUBSCR_BLOCK_DAY ,
- //'description' => _MI_APCAL_BNAME_MINICAL_DESC ,
'description' => '' ,
'show_func' => 'b_xnewsletter_catsubscr' ,
'edit_func' => 'b_xnewsletter_catsubscr_edit' ,
@@ -366,7 +376,6 @@
$modversion['blocks'][$b] = array(
'file' => 'blocks_letter.php' ,
'name' => _MI_XNEWSLETTER_LETTER_BLOCK_RECENT ,
- //'description' => _MI_APCAL_BNAME_MINICAL_DESC ,
'description' => '' ,
'show_func' => 'b_xnewsletter_letter' ,
'edit_func' => 'b_xnewsletter_letter_edit' ,
@@ -379,7 +388,6 @@
$modversion['blocks'][$b] = array(
'file' => 'blocks_letter.php' ,
'name' => _MI_XNEWSLETTER_LETTER_BLOCK_DAY ,
- //'description' => _MI_APCAL_BNAME_MINICAL_DESC ,
'description' => '' ,
'show_func' => 'b_xnewsletter_letter' ,
'edit_func' => 'b_xnewsletter_letter_edit' ,
@@ -392,7 +400,6 @@
$modversion['blocks'][$b] = array(
'file' => 'blocks_letter.php' ,
'name' => _MI_XNEWSLETTER_LETTER_BLOCK_RANDOM ,
- //'description' => _MI_APCAL_BNAME_MINICAL_DESC ,
'description' => '' ,
'show_func' => 'b_xnewsletter_letter' ,
'edit_func' => 'b_xnewsletter_letter_edit' ,
|
|
From: <txm...@us...> - 2013-10-21 08:49:57
|
Revision: 12189
http://sourceforge.net/p/xoops/svn/12189
Author: txmodxoops
Date: 2013-10-21 08:49:51 +0000 (Mon, 21 Oct 2013)
Log Message:
-----------
This version 1.381 Stable
- fixed several error and bugs
- fixed bugs in const_include_search.php
- Moved search_field function in file include/function_const.php
- Tested without errors
Features:
Add fieldname in tables to subdivide tables_name with table_fieldname for sql and other files
Replacement of tables_ with table_ in all files
Other additions to version 1.387
Added Paths:
-----------
XoopsModules/TDMCreate/branches/timgno/1.381/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/about.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/admin_footer.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/admin_header.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/building.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/includes.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/index.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/menu.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/modules.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/tables.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/class/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/class/constArch.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/class/constArchitecture.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/class/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/class/logoGenerator.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/class/tdmcreate_modules.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/class/tdmcreate_tables.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_about_language.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_admin_about.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_admin_footer.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_admin_header.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_admin_help.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_admin_index.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_admin_language.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_admin_menu.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_admin_pages.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_admin_permissions.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_architecture.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_blocks.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_blocks_language.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_blocks_templates.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_changelog.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_class.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_class_admin.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_class_menu.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_css_admin.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_css_style.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_entete.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_header.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_help_language.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_include_comments.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_include_comments_functions.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_include_configs.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_include_functions.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_include_install.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_include_jquery.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_include_notification.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_include_search.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_js_jquery.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_languages.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_main_header.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_main_index.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_main_language.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_modinfo_language.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_sql.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_templates.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_templates_admin_about.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_templates_admin_help.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_templates_footer.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_templates_header.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_templates_index.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_templates_pages.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_user_comments.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_user_header.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_user_index.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_user_pages.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_waiting.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/const/const_xoopsversion.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/css/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/css/admin.css
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/css/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/docs/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/docs/changelog.txt
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/docs/credits.txt
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/docs/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/docs/install.txt
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/docs/lang_diff.txt
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/docs/license.txt
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/docs/readme.txt
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/32/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/32/addmodule.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/32/addtable.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/32/builder.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/32/dashboard.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/32/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/icons/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/icons/arrow.gif
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/icons/blank.gif
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/icons/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/icons/loading.gif
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/icons/off.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/icons/on.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/loading.gif
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/logos/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/logos/VeraBd.ttf
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/logos/green.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/logos/red.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/logos/xoops2.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/menu/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/menu/bg.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/menu/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/menu/left_both.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/menu/right_both.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/module_logo.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/tdmcreate_slogo.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/modules/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/modules/Test1Logo.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/modules/Test1_logo.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/modules/empty.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/modules/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/modules/module_logo.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/modules/test3_logo.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/modules/test4_logo.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/modules/test5_logo.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/modules/test6_logo.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/modules/test7_logo.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/modules/xcvLogo.txt
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/tables/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/tables/blank.gif
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/uploads/tables/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/images/xoops2.png
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/include/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/include/comment_delete.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/include/comment_edit.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/include/comment_new.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/include/comment_post.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/include/comment_reply.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/include/functions.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/include/functions_const.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/include/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/include/install.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/include/jq.init.js
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/include/update.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/js/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/js/functions.js
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/js/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/english/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/english/admin.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/english/help/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/english/help/help.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/english/help/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/english/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/english/modinfo.php
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/update language 1.0 to 1.1.txt
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/update language 1.1 to 1.15.txt
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/update language 1.1 to 1.37.txt
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/update language 1.15 to 1.37.txt
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/language/update language 1.37 to 1.38.txt
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/modules/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/modules/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/sql/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/sql/index.html
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/sql/mysql.sql
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/templates/
XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/xoops_version.php
Added: XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/about.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/about.php (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/about.php 2013-10-21 08:49:51 UTC (rev 12189)
@@ -0,0 +1,22 @@
+<?php
+/**
+ * TDMCreate module
+ *
+ * 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.
+ *
+ * @copyright The XOOPS Project (http://www.xoops.org)
+ * @license GNU GPL (http://www.gnu.org/licenses/gpl-2.0.html/)
+ * @package TDMCreate
+ * @since 2.5.0
+ * @author Mage, Mamba
+ * @version $Id $
+ **/
+include 'admin_header.php';
+echo $adminMenu->addNavigation('about.php');
+echo $adminMenu->renderabout('6KJ7RW5DR3VTJ', false);
+include 'admin_footer.php';
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/admin_footer.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/admin_footer.php (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/admin_footer.php 2013-10-21 08:49:51 UTC (rev 12189)
@@ -0,0 +1,22 @@
+<?php
+/**
+ * XoopsPoll module
+ *
+ * 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.
+ *
+ * @copyright The XOOPS Project http://sourceforge.net/projects/xoops/
+ * @license http://www.fsf.org/copyleft/gpl.html GNU public license
+ * @package XoopsPoll
+ * @since 2.5.0
+ * @author Mamba (www.xoops.org)
+ * @version $Id $
+**/
+
+echo "<div align=\"center\"><a href=\"http://www.xoops.org\" target=\"_blank\"><img src=" . $pathIcon32.'/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/TDMCreate/branches/timgno/1.381/TDMCreate/admin/admin_header.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/admin_header.php (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/admin_header.php 2013-10-21 08:49:51 UTC (rev 12189)
@@ -0,0 +1,54 @@
+<?php
+/**
+ * Marquee module
+ *
+ * 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.
+ *
+ * @copyright The XOOPS Project http://sourceforge.net/projects/xoops/
+ * @license http://www.fsf.org/copyleft/gpl.html GNU public license
+ * @package Marquee
+ * @since 2.5.0
+ * @author XOOPS Module Team
+ * @version $Id $
+**/
+include_once dirname(dirname(dirname(dirname(__FILE__)))) . '/mainfile.php';
+include_once XOOPS_ROOT_PATH . '/include/cp_header.php';
+include_once("../include/functions.php");
+include_once 'includes.php';
+//
+$thisDirname = $GLOBALS['xoopsModule']->getVar('dirname');
+//
+
+$pathIcon16 = '../' . $xoopsModule->getInfo('icons16');
+$pathIcon32 = '../' . $xoopsModule->getInfo('icons32');
+$pathModuleAdmin = $xoopsModule->getInfo('dirmoduleadmin');
+
+//load class
+$modulesHandler =& xoops_getModuleHandler('tdmcreate_modules', 'TDMCreate');
+$tablesHandler =& xoops_getModuleHandler('tdmcreate_tables', 'TDMCreate');
+//
+$myts =& MyTextSanitizer::getInstance();
+if (!isset($xoopsTpl) || !is_object($xoopsTpl)) {
+ include_once(XOOPS_ROOT_PATH."/class/template.php");
+ $xoopsTpl = new XoopsTpl();
+}
+//
+$xoopsTpl->assign('pathIcon16', $pathIcon16);
+$xoopsTpl->assign('pathIcon32', $pathIcon32);
+//Load languages
+xoops_loadLanguage('admin', $thisDirname);
+xoops_loadLanguage('modinfo', $thisDirname);
+xoops_loadLanguage('main', $thisDirname);
+// Locad admin menu class
+if ( file_exists($GLOBALS['xoops']->path($pathModuleAdmin.'/moduleadmin.php'))){
+ include_once $GLOBALS['xoops']->path($pathModuleAdmin.'/moduleadmin.php');
+}else{
+ redirect_header("../../../admin.php", 5, _AM_MODULEADMIN_MISSING, false);
+}
+xoops_cp_header();
+$adminMenu = new ModuleAdmin();
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/building.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/building.php (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/building.php 2013-10-21 08:49:51 UTC (rev 12189)
@@ -0,0 +1,224 @@
+<?php
+/**
+ * ****************************************************************************
+ * - TDMCreate By TDM - TEAM DEV MODULE FOR XOOPS
+ * - Licence GPL Copyright (c) (http://www.tdmxoops.net)
+ *
+ * Cette licence, contient des limitations!!!
+ *
+ * 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.
+ *
+ * @license TDM GPL license
+ * @author TDM TEAM DEV MODULE
+ *
+ * ****************************************************************************
+ */
+include 'admin_header.php';
+echo $adminMenu->addNavigation('const.php');
+$op = TDMCreate_CleanVars( $_REQUEST, 'op', 'default', 'string' );
+
+if (isset($_REQUEST['modules_name'])) {
+ $modules =& $modulesHandler->get($_REQUEST['modules_name']);
+} else {
+ $modules = & $modulesHandler;
+}
+
+$modules_name = $modules->getVar('modules_name');
+$modules_desc = $modules->getVar('modules_description');
+$modules_author_website_name = $modules->getVar('modules_author_website_name');
+$modules_author_website_url = $modules->getVar('modules_author_website_url');
+$modules_image = $modules->getVar('modules_image');
+$modules_active_search = $modules->getVar('modules_active_search');
+$modules_active_comments = $modules->getVar('modules_active_comments');
+
+//Nom des tables et combien de tables
+$criteria = new CriteriaCompo();
+if (isset($_REQUEST['modules_name'])) {
+ $criteria->add(new Criteria('tables_modules', $_REQUEST['modules_name']));
+} else {
+ $criteria->add(new Criteria('tables_modules'));
+}
+
+$nb_tables = $tablesHandler->getCount($criteria);
+$tables_arr = $tablesHandler->getall($criteria);
+
+switch ($op) {
+ case "creation":
+
+ //Effacer repertoire du nouveau module s'il existe
+ clearDir($modPath.'/modules/'.$modules_name);
+
+ //Debut
+ OpenTable();
+ /************************************************/
+ /*Structure*/
+ /************************************************/
+ //Creation de l'architecture
+ const_architecture($modules_name, $modules_image);
+ //Creation du changelog.txt
+ const_changelog($modules, $modules_name);
+ //Creation de admin index.php
+ const_admin_index($modules, $modules_name, $tables_arr);
+ //const_class_admin($modules, $modules_name);
+
+ foreach (array_keys($tables_arr) as $i)
+ {
+ //Variables
+ $tables_id = $tables_arr[$i]->getVar('tables_id');
+ $tables_name = $tables_arr[$i]->getVar('tables_name');
+ $tables_category = $tables_arr[$i]->getVar('tables_category');
+ $tables_module_table = $tables_arr[$i]->getVar('tables_module_table');
+ $tables_img = $tables_arr[$i]->getVar('tables_img');
+ $tables_fields = $tables_arr[$i]->getVar('tables_fields');
+ $tables_parameters = $tables_arr[$i]->getVar('tables_parameters');
+ $tables_blocks = $tables_arr[$i]->getVar('tables_blocks');
+ $tables_display_admin = $tables_arr[$i]->getVar('tables_display_admin');
+ $tables_display_user = $tables_arr[$i]->getVar('tables_display_user');
+ $tables_search = $tables_arr[$i]->getVar('tables_search');
+ $tables_comments = $tables_arr[$i]->getVar('tables_comments');
+ $tables_waiting = $tables_arr[$i]->getVar('tables_waiting');
+
+ //Fabrication
+ //Copie of images tables
+ $tables_img1 = $modPath."/images/uploads/tables/".$tables_img;
+ if (file_exists($tables_img1)) {
+ copy($tables_img1, $modPath."/modules/".$modules_name."/images/icons/".$tables_img);
+ }
+ //Creation des classes
+ const_class($modules, $modules_name, $tables_module_table, $tables_name, $tables_fields, $tables_parameters);
+
+ if ( $tables_category == 1) { //|| $tables_module_table != null
+ const_admin_permissions($modules, $modules_name, $tables_name, $tables_category);
+ }
+
+ //Creation of pages admin
+ if ( $tables_display_admin == 1 ) {
+ const_admin_pages($modules, $modules_name, $tables_id, $tables_module_table, $tables_category, $tables_name, $tables_img, $tables_fields, $tables_parameters);
+ }
+ //Creation of pages and templates user
+ if ( $tables_display_user == 1 && $tables_module_table != NULL ) {
+ const_user_pages($modules, $modules_name, $tables_id, $tables_module_table, $tables_name, $tables_img, $tables_fields, $tables_parameters);
+ const_templates_pages($modules, $modules_name, $tables_name, $tables_module_table, $tables_fields, $tables_parameters);
+ }
+ //Creation de search
+ if ( $modules_active_search == 1 && $tables_search == 1 ) {
+ const_include_search($modules, $modules_name, $tables_name, $tables_module_table, $tables_fields, $tables_parameters, $tables_img);
+ }
+ //Creation of comments
+ if ( $modules_active_comments == 1 && $tables_comments == 1 ) {
+ const_include_comments($modules, $modules_name, $tables_name, $tables_module_table, $tables_fields, $tables_parameters, $tables_img);
+ }
+
+ //Creation of the file mysql.sql
+ const_sql($modules_name, $tables_module_table, $tables_name, $tables_fields);
+
+ $result = $xoopsDB->queryF("SELECT COUNT(*) FROM " . $xoopsDB->prefix("tdmcreate_tables")." WHERE tables_name = 'category'");
+ list( $category ) = $xoopsDB->fetchRow($result);
+ //Creation des blocks
+ if ( $tables_blocks == 1 ) {
+ const_blocks($modules, $modules_name, $tables_module_table, $tables_name, $tables_fields, $tables_parameters, $category);
+ //Creation du template des blocks
+ const_blocks_templates($modules, $modules_name, $tables_name, $tables_module_table, $tables_fields, $tables_parameters);
+ }
+ }
+
+ //Creation of Waiting Plugin
+ const_waiting($modules, $modules_name, $tables_arr);
+
+
+ //Creation de xoopsversion.php
+ /*Mettre xoops version vers la fin pour integrer les bloc, etc*/
+ const_xoopsversion($modules, $modules_name, $tables_arr, $tables_module_table);
+ // Creation of template index
+ const_templates_index($modules, $modules_name, $tables_name, $tables_module_table, $tables_fields, $tables_parameters);
+ // Creation of template header
+ const_templates_header($modules, $modules_name);
+ // Creation of template footer
+ const_templates_footer($modules, $modules_name, $tables_module_table);
+ // Creation of template admin about
+ const_templates_admin_about($modules, $modules_name);
+ // Creation of template admin help
+ const_templates_admin_help($modules, $modules_name);
+ //Creation du fichier permissions
+
+
+ //Include
+ //Configs
+ const_include_configs($modules, $modules_name, $modules_author_website_name, $modules_author_website_url);
+ //Style
+ //const_css_admin($modules, $modules_name);
+ //const_include_style($modules, $modules_name);
+ //Functions
+ const_include_functions($modules, $modules_name);
+ //Creation du fichier install pour l'uploads
+ const_include_install($modules, $modules_name, $tables_arr);
+ //Language
+ ///////////////////////////////////////////////////////////////////////
+ //Creation du language main.php
+ const_main_language($modules, $modules_name, $modules_desc, $tables_arr);
+ //Creation du language modinfo.php
+ const_modinfo_language($modules, $modules_name, $modules_desc, $tables_arr, $category);
+ //Creation du language admin.php
+ const_admin_language($modules, $modules_name, $tables_arr, $tables_name);
+ //Creation du language blocks.php
+ const_blocks_language($modules, $modules_name, $tables_arr);
+ //Creation du language help/help.html
+ const_help_language($modules, $modules_name, $modules_desc);
+ ///////////////////////////////////////////////////////////////////////
+ //Creation de la class menu
+ //const_class_menu($modules, $modules_name);
+
+ /************************************************/
+ /*Admin*/
+ /************************************************/
+ //Creation de admin header.php
+ const_admin_header($modules, $modules_name, $tables_arr);
+ //Creation de admin footer.php
+ const_admin_footer($modules, $modules_name, $tables_arr);
+ //Creation de admin menu.php
+ const_admin_menu($modules, $modules_name, $tables_arr, $category);
+ //Creation de admin about.php
+ //$menu++;
+ const_admin_about($modules, $modules_name);
+ /************************************************/
+ /*Admin*/
+ /************************************************/
+ const_user_header($modules, $modules_name, $tables_id, $tables_module_table, $tables_name);
+ const_user_index($modules, $modules_name, $tables_id, $tables_module_table, $tables_name, $tables_fields, $tables_parameters);
+ CloseTable();
+
+ break;
+
+ case "default":
+ default:
+
+ include_once(XOOPS_ROOT_PATH."/class/xoopsformloader.php");
+ $action = $_SERVER['REQUEST_URI'];
+
+ $form = new XoopsThemeForm(_AM_TDMCREATE_ADMIN_CONST, 'form_creation', $action, 'post', TRUE);
+
+ $modules_select = new XoopsFormSelect(_AM_TDMCREATE_CONST_MODULES, 'modules_name', 'modules_name');
+ $modules_select->addOptionArray($modulesHandler->getList());
+ $form->addElement($modules_select, TRUE);
+
+ foreach (array_keys($tables_arr) as $i)
+ {
+ //Variables
+ $tables_name = $tables_arr[$i]->getVar('tables_name');
+ }
+
+ $tables_select = new XoopsFormSelect(_AM_TDMCREATE_CONST_TABLES, 'tables_name', $tables_name, 4);
+ $tables_select->addOptionArray($tablesHandler->getList());
+ $form->addElement($tables_select, FALSE);
+
+ $form->addElement(new XoopsFormHidden('op', 'creation'));
+ $form->addElement(new XoopsFormButton('', 'submit', _SUBMIT, 'submit'));
+ $form->display();
+ break;
+}
+include "admin_footer.php";
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/includes.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/includes.php (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/includes.php 2013-10-21 08:49:51 UTC (rev 12189)
@@ -0,0 +1,67 @@
+<?php
+/**
+ * ****************************************************************************
+ * - TDMCreate By TDM - TEAM DEV MODULE FOR XOOPS
+ * - Licence GPL Copyright (c) (http://www.tdmxoops.net)
+ *
+ * Cette licence, contient des limitations!!!
+ *
+ * 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.
+ *
+ * @license TDM GPL license
+ * @author TDM TEAM DEV MODULE
+ *
+ * ****************************************************************************
+ */
+include '../../../include/cp_header.php';
+include_once("../include/functions.php");
+
+$modPath = XOOPS_ROOT_PATH.'/modules/TDMCreate';
+$cPath = $modPath.'/const';
+
+include_once $cPath.'/const_architecture.php';
+include_once $cPath.'/const_xoopsversion.php';
+include_once $cPath.'/const_changelog.php';
+include_once $cPath.'/const_include_search.php';
+include_once $cPath.'/const_include_comments.php';
+include_once $cPath.'/const_include_configs.php';
+include_once $cPath.'/const_include_functions.php';
+include_once $cPath.'/const_include_install.php';
+include_once $cPath.'/const_waiting.php';
+//include_once $cPath.'/const_include_style.php';
+include_once $cPath.'/const_sql.php';
+include_once $cPath.'/const_blocks.php';
+include_once $cPath.'/const_blocks_templates.php';
+include_once $cPath.'/const_class.php';
+include_once $cPath.'/const_class_admin.php';
+//include_once $cPath.'/const_class_menu.php';
+
+include_once $cPath.'/const_admin_header.php';
+include_once $cPath.'/const_admin_footer.php';
+include_once $cPath.'/const_admin_menu.php';
+include_once $cPath.'/const_admin_index.php';
+include_once $cPath.'/const_admin_pages.php';
+include_once $cPath.'/const_admin_about.php';
+include_once $cPath.'/const_admin_permissions.php';
+include_once $cPath.'/const_admin_language.php';
+include_once $cPath.'/const_modinfo_language.php';
+include_once $cPath.'/const_about_language.php';
+include_once $cPath.'/const_help_language.php';
+include_once $cPath.'/const_blocks_language.php';
+include_once $cPath.'/const_main_language.php';
+include_once $cPath.'/const_user_header.php';
+include_once $cPath.'/const_user_index.php';
+include_once $cPath.'/const_user_pages.php';
+include_once $cPath.'/const_templates_header.php';
+include_once $cPath.'/const_templates_index.php';
+include_once $cPath.'/const_templates_pages.php';
+include_once $cPath.'/const_templates_footer.php';
+include_once $cPath.'/const_templates_admin_about.php';
+include_once $cPath.'/const_templates_admin_help.php';
+
+?>
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/index.html
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/index.html (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/index.html 2013-10-21 08:49:51 UTC (rev 12189)
@@ -0,0 +1 @@
+ <script>history.go(-1);</script>
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/index.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/index.php (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/index.php 2013-10-21 08:49:51 UTC (rev 12189)
@@ -0,0 +1,33 @@
+<?php
+/**
+ * ****************************************************************************
+ * - TDMCreate By TDM - TEAM DEV MODULE FOR XOOPS
+ * - Licence GPL Copyright (c) (http://www.tdmxoops.net)
+ *
+ * Cette licence, contient des limitations!!!
+ *
+ * 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.
+ *
+ * @license TDM GPL license
+ * @author TDM TEAM DEV MODULE
+ *
+ * ****************************************************************************
+ */
+include 'admin_header.php';
+ $criteria = new CriteriaCompo();
+ $count_modules = $modulesHandler->getCount($criteria);
+ $count_tables = $tablesHandler->getCount($criteria);
+
+$adminMenu->addInfoBox(_AM_TDMCREATE_ADMIN_NUMMODULES) ;
+$adminMenu->addInfoBoxLine(_AM_TDMCREATE_ADMIN_NUMMODULES, "<label>" ._AM_TDMCREATE_THEREARE_NUMMODULES. "</label>", $count_modules, 'Green') ;
+$adminMenu->addInfoBoxLine(_AM_TDMCREATE_ADMIN_NUMMODULES, "<label>" ._AM_TDMCREATE_THEREARE_NUMTABLES. "</label>", $count_tables, 'Orange');
+
+ echo $adminMenu->addNavigation('index.php');
+ echo $adminMenu->renderIndex();
+
+include "admin_footer.php";
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/menu.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/menu.php (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/menu.php 2013-10-21 08:49:51 UTC (rev 12189)
@@ -0,0 +1,46 @@
+<?php
+/**
+ * ****************************************************************************
+ * - TDMCreate By TDM - TEAM DEV MODULE FOR XOOPS
+ * - Licence GPL Copyright (c) (http://www.tdmxoops.net)
+ *
+ * Cette licence, contient des limitations!!!
+ *
+ * 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.
+ *
+ * @license TDM GPL license
+ * @author TDM TEAM DEV MODULE
+ *
+ * ****************************************************************************
+ */
+$module_handler =& xoops_gethandler('module');
+$xoopsModule =& XoopsModule::getByDirname('TDMCreate');
+$moduleInfo =& $module_handler->get($xoopsModule->getVar('mid'));
+$pathIcon32 = $moduleInfo->getInfo('icons32');
+$adminmenu = array();
+$i = 1;
+$adminmenu[$i]["title"] = _MI_TDMCREATE_ADMIN_INDEX;
+$adminmenu[$i]["link"] = 'admin/index.php';
+$adminmenu[$i]["icon"] = $pathIcon32.'/home.png';
+$i++;
+$adminmenu[$i]["title"] = _MI_TDMCREATE_ADMIN_MODULES;
+$adminmenu[$i]["link"] = 'admin/modules.php';
+$adminmenu[$i]["icon"] = 'images/32/addmodule.png';
+$i++;
+$adminmenu[$i]["title"] = _MI_TDMCREATE_ADMIN_TABLES;
+$adminmenu[$i]["link"] = 'admin/tables.php';
+$adminmenu[$i]["icon"] = 'images/32/addtable.png';
+$i++;
+$adminmenu[$i]["title"] = _MI_TDMCREATE_ADMIN_CONST;
+$adminmenu[$i]["link"] = 'admin/building.php';
+$adminmenu[$i]["icon"] = 'images/32/builder.png';
+$i++;
+$adminmenu[$i]["title"] = _MI_TDMCREATE_ADMIN_ABOUT;
+$adminmenu[$i]["link"] = 'admin/about.php';
+$adminmenu[$i]["icon"] = $pathIcon32.'/about.png';
+unset($i);
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/modules.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/modules.php (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/modules.php 2013-10-21 08:49:51 UTC (rev 12189)
@@ -0,0 +1,167 @@
+<?php
+/**
+ * ****************************************************************************
+ * - TDMCreate By TDM - TEAM DEV MODULE FOR XOOPS
+ * - Licence GPL Copyright (c) (http://www.tdmxoops.net)
+ *
+ * Cette licence, contient des limitations!!!
+ *
+ * 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.
+ *
+ * @license TDM GPL license
+ * @author TDM TEAM DEV MODULE
+ *
+ * ****************************************************************************
+ */
+include_once 'admin_header.php';
+$op = TDMCreate_CleanVars( $_REQUEST, 'op', 'default', 'string' );
+switch ($op) {
+ case "modules_save":
+ if (!$GLOBALS['xoopsSecurity']->check()) {
+ redirect_header('modules.php', 3, implode(',', $GLOBALS['xoopsSecurity']->getErrors()));
+ }
+
+ if (isset($_REQUEST['modules_id'])) {
+ $obj =& $modulesHandler->get($_REQUEST['modules_id']);
+ } else {
+ $obj =& $modulesHandler->create();
+ }
+ //Image
+ include_once XOOPS_ROOT_PATH.'/class/uploader.php';
+ $uploaddir = XOOPS_ROOT_PATH . "/modules/".$xoopsModule->dirname()."/images/uploads/modules/";
+ $uploader = new XoopsMediaUploader($uploaddir, "gif|jpeg|pjpeg|png", 104857600, null, null);
+
+ if ($uploader->fetchMedia($_POST['xoops_upload_file'][0])) {
+ $extension = preg_replace( "/^.+\.([^.]+)$/sU" , "\\1" , $_FILES["attachedfile"]['name']) ;
+ $name_img = $_REQUEST['modules_name'].'_slogo.'.$extension;
+ $uploader->setTargetFileName($name_img);
+ $uploader->fetchMedia($_POST['xoops_upload_file'][0]);
+ if (!$uploader->upload()) {
+ $errors = $uploader->getErrors();
+ redirect_header("javascript:history.go(-1)",3, $errors);
+ } else {
+ $obj->setVar('modules_image', $uploader->getSavedFileName());
+ }
+ } else {
+ $obj->setVar('modules_image', $_REQUEST['modules_image']);
+ }
+ //remove all spaces from the new name
+ $spacesRemoved = str_replace(' ', '', $_REQUEST['modules_name']);
+
+ $obj->setVar('modules_name', $spacesRemoved );
+ $obj->setVar('modules_version', $_REQUEST['modules_version']);
+ $obj->setVar('modules_description', $_REQUEST['modules_description']);
+ $obj->setVar('modules_author', $_REQUEST['modules_author']);
+ $obj->setVar('modules_author_mail', $_REQUEST['modules_author_mail']);
+ $obj->setVar('modules_author_website_url', $_REQUEST['modules_author_website_url']);
+ $obj->setVar('modules_author_website_name', $_REQUEST['modules_author_website_name']);
+ $obj->setVar('modules_credits', $_REQUEST['modules_credits']);
+ $obj->setVar('modules_license', $_REQUEST['modules_license']);
+ $obj->setVar('modules_release_info', $_REQUEST['modules_release_info']);
+ $obj->setVar('modules_release_file', $_REQUEST['modules_release_file']);
+ $obj->setVar('modules_manual', $_REQUEST['modules_manual']);
+ $obj->setVar('modules_manual_file', $_REQUEST['modules_manual_file']);
+ $obj->setVar('modules_demo_site_url', $_REQUEST['modules_demo_site_url']);
+ $obj->setVar('modules_demo_site_name', $_REQUEST['modules_demo_site_name']);
+ $obj->setVar('modules_forum_site_url', $_REQUEST['modules_forum_site_url']);
+ $obj->setVar('modules_forum_site_name', $_REQUEST['modules_forum_site_name']);
+ $obj->setVar('modules_module_website_url', $_REQUEST['modules_module_website_url']);
+ $obj->setVar('modules_module_website_name', $_REQUEST['modules_module_website_name']);
+ $obj->setVar('modules_release', $_REQUEST['modules_release']);
+ $obj->setVar('modules_module_status', $_REQUEST['modules_module_status']);
+ $obj->setVar('modules_display_admin', $_REQUEST['modules_display_admin']);
+ $obj->setVar('modules_display_user', $_REQUEST['modules_display_user']);
+ $obj->setVar('modules_active_search', $_REQUEST['modules_active_search']);
+ $obj->setVar('modules_active_comments', $_REQUEST['modules_active_comments']);
+
+ if ($modulesHandler->insert($obj)) {
+ redirect_header('modules.php?op=default', 2, _AM_TDMCREATE_FORMOK);
+ }
+ break;
+
+ case "modules_create":
+ echo $adminMenu->addNavigation('modules.php');
+ $adminMenu->addItemButton(_AM_TDMCREATE_MODULES_LIST, 'modules.php?op=modules_list', 'list');
+ echo $adminMenu->renderButton();
+
+ $obj =& $modulesHandler->create();
+ $form = $obj->getForm();
+ break;
+ case "modules_edit":
+ $obj =& $modulesHandler->get($_REQUEST['modules_id']);
+ $form = $obj->getForm();
+ break;
+ case "modules_delete":
+ $obj =& $modulesHandler->get($_REQUEST['modules_id']);
+ if (isset($_REQUEST['ok']) && $_REQUEST['ok'] == 1)
+ {
+ if (!$GLOBALS['xoopsSecurity']->check()) {
+ redirect_header('modules.php', 3, implode(',', $GLOBALS['xoopsSecurity']->getErrors()));
+ }
+ if ($modulesHandler->delete($obj)) {
+ $xoopsDB->queryF("DELETE FROM ".$xoopsDB->prefix("tdmcreate_modules")." WHERE modules_id = ".$_REQUEST['modules_id']);
+ redirect_header('modules.php', 3, _AM_TDMCREATE_FORMDELOK);
+ } else {
+ echo $obj->getHtmlErrors();
+ }
+ } else {
+ xoops_confirm(array('ok' => 1, 'modules_id' => $_REQUEST['modules_id'], 'op' => 'modules_delete'), $_SERVER['REQUEST_URI'], sprintf(_AM_TDMCREATE_FORMSUREDEL, $obj->getVar('modules_name')));
+ }
+ break;
+ case "modules_list":
+ default:
+ echo $adminMenu->addNavigation('modules.php');
+ $adminMenu->addItemButton(_AM_TDMCREATE_MODULES_NEW, 'modules.php?op=modules_create', 'add');
+ echo $adminMenu->renderButton();
+
+ $criteria = new CriteriaCompo();
+ $criteria->setSort('modules_name');
+ $criteria->setOrder('ASC');
+ $modules_arr = $modulesHandler->getall($criteria);
+ $numrows_modules = $modulesHandler->getCount();
+
+ if ( $numrows_modules > 0 )
+ {
+ echo '<table width="100%" cellspacing="1" class="outer">';
+ echo '<tr class="center">';
+ echo '<th width="20%">'._AM_TDMCREATE_NAME.'</th>';
+ echo '<th width="10%">'._AM_TDMCREATE_IMAGE.'</th>';
+ echo '<th width="15%">'._AM_TDMCREATE_DISPLAY_ADMIN.'</th>';
+ echo '<th width="15%">'._AM_TDMCREATE_DISPLAY_USER.'</th>';
+ echo '<th width="10%">'._AM_TDMCREATE_BLOCKS.'</th>';
+ echo '<th width="10%">'._AM_TDMCREATE_NB_FIELDS.'</th>';
+ echo '<th width="10%">'._AM_TDMCREATE_FORMACTION.'</th>';
+ echo '</tr>';
+ $class = 'odd';
+ foreach (array_keys($modules_arr) as $i)
+ {
+ $modules_id = $modules_arr[$i]->getVar('modules_id');
+ $modules_name = $modules_arr[$i]->getVar('modules_name');
+ $modules_image = $modules_arr[$i]->getVar('modules_image');
+ //$modules_blocks = $modules_arr[$i]->getVar('modules_blocks');
+ $modules_display_admin = $modules_arr[$i]->getVar('modules_display_admin');
+ $modules_display_user = $modules_arr[$i]->getVar('modules_display_user');
+ $display_admin = ($modules_display_admin == 1) ? _YES : _NO;
+ $display_user = ($modules_display_user == 1) ? _YES : _NO;
+ echo '<tr class="odd center">';
+ echo '<td><b>'.$modules_name.'</b></td>';
+ echo '<td><img src="../images/uploads/modules/'.$modules_image.'" height="30px"></td>';
+ echo '<td>'.$display_admin.'</td>';
+ echo '<td>'.$display_user.'</td>';
+ echo '<td> </td>';
+ echo '<td> </td>';
+ echo '<td>';
+ echo '<a href="modules.php?op=modules_edit&modules_id='.$modules_id.'"><img src='. $pathIcon16 ."/edit.png alt="._AM_TDMCREATE_FORMEDIT.'" title="'._AM_TDMCREATE_FORMEDIT.'"></a> <a href="modules.php?op=modules_delete&modules_id='.$modules_id.'"><img src='. $pathIcon16 ."/delete.png alt="._AM_TDMCREATE_FORMDEL.'" title="'._AM_TDMCREATE_FORMDEL.'"></a>';
+ echo '</td>';
+ echo '</tr>';
+ }
+ echo '</table><br><br>';
+ }
+ break;
+}
+include_once "admin_footer.php";
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/tables.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/tables.php (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.381/TDMCreate/admin/tables.php 2013-10-21 08:49:51 UTC (rev 12189)
@@ -0,0 +1,569 @@
+<?php
+/**
+ * ****************************************************************************
+ * - TDMCreate By TDM - TEAM DEV MODULE FOR XOOPS
+ * - Licence GPL Copyright (c) (http://www.tdmxoops.net)
+ *
+ * Cette licence, contient des limitations!!!
+ *
+ * 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.
+ *
+ * @license TDM GPL license
+ * @author TDM TEAM DEV MODULE
+ *
+ * ****************************************************************************
+ */
+include_once 'admin_header.php';
+$op = TDMCreate_CleanVars( $_REQUEST, 'op', 'default', 'string' );
+switch ($op) {
+ case "tables_save":
+ if (isset($_REQUEST['tables_id'])) {
+ $obj =& $tablesHandler->get($_REQUEST['tables_id']);
+ } else {
+ $obj =& $tablesHandler->create();
+ }
+
+ //Module Name
+ $modules =& $modulesHandler->get($_REQUEST['tables_modules']);
+ $modules_name = $modules->getVar('modules_name');
+
+ $obj->setVar('tables_modules', $_REQUEST['tables_modules']);
+
+ if ( $_REQUEST['select'] == 1 )
+ {
+ $obj->setVar('tables_module_table', strtolower($modules_name.'_category'));
+ $obj->setVar('tables_category', 1);
+ $obj->setVar('tables_name', 'category');
+ $obj->setVar('tables_blocks', 0);
+ $obj->setVar('tables_display_admin', 1);
+ $obj->setVar('tables_display_user', 1);
+ $obj->setVar('tables_status', 0);
+ $obj->setVar('tables_waiting', 0);
+ $obj->setVar('tables_online', 0);
+ $obj->setVar('tables_search', 0);
+ $obj->setVar('tables_comments', 0);
+ $obj->setVar('tables_nb_fields', 7);
+
+ $tables_fields = 'category_id:int:11:unsigned:NOT NULL: :|category_pid:int:5:unsigned:NOT NULL:0:|category_title:varchar:255: :NOT NULL: :|category_desc:text: : :NOT NULL: :|category_img:varchar:255: :NOT NULL: :|category_weight:int:5: :NOT NULL:0:|category_color:varchar:10: :NULL: :';
+
+ $tables_parameters = 'XoopsFormCategory:0:0:0:0:0:0|XoopsFormText:1:1:0:1:0:1|XoopsFormTextArea:0:1:0:0:0:1|XoopsFormUploadImage:1:1:0:0:0:0|XoopsFormText:1:1:0:0:0:0|XoopsFormColorPicker:1:1:0:0:0:0|XoopsFormSelectUser:0:0:0:0:0:1|XoopsFormTextDateSelect:0:0:0:0:0:1|XoopsFormCheckBox:1:1:0:0:0:1';
+
+ //Image
+ include_once XOOPS_ROOT_PATH.'/class/uploader.php';
+
+ if(is_dir($pathIcon32)){
+ $uploaddir = $pathIcon32;
+ }else{
+ $uploaddir = XOOPS_ROOT_PATH . "/modules/".$xoopsModule->dirname()."/images/uploads/tables/";
+ }
+
+ $uploader = new XoopsMediaUploader($uploaddir, "gif|jpeg|pjpeg|png", 104857600, null, null);
+
+ if ($uploader->fetchMedia($_POST['xoops_upload_file'][0])) {
+ $extension = preg_replace( "/^.+\.([^.]+)$/sU" , "\\1" , $_FILES["attachedfile1"]['name']) ;
+ $name_img = 'category.'.$extension;
+ $uploader->setTargetFileName($name_img);
+ $uploader->fetchMedia($_POST['xoops_upload_file'][0]);
+ if (!$uploader->upload()) {
+ $errors = $uploader->getErrors();
+ redirect_header("javascript:history.go(-1)",3, $errors);
+ } else {
+ $obj->setVar('tables_img', $uploader->getSavedFileName());
+ }
+ } else {
+ $obj->setVar('tables_img', $_REQUEST['tables_img1']);
+ }
+ } else {
+
+ $obj->setVar('tables_module_table', strtolower($modules_name.'_'.$_REQUEST['tables_name']));
+ $obj->setVar('tables_name', strtolower($_REQUEST['tables_name']));
+ $obj->setVar('tables_blocks', $_REQUEST['tables_blocks']);
+ $obj->setVar('tables_display_admin', $_REQUEST['tables_display_admin']);
+ $obj->setVar('tables_display_user', $_REQUEST['tables_display_user']);
+ $obj->setVar('tables_status', $_REQUEST['tables_status']);
+ $obj->setVar('tables_waiting', $_REQUEST['tables_waiting']);
+ $obj->setVar('tables_online', $_REQUEST['tables_online']);
+ $obj->setVar('tables_search', $_REQUEST['tables_search']);
+ $obj->setVar('tables_comments', $_REQUEST['tables_comments']);
+
+ $obj->setVar('tables_nb_fields', $_REQUEST['tables_nb_fields']);
+
+ $tables_fields = '';
+ $tables_parameters = '';
+ for($i=0; $i<$_REQUEST['tables_nb_fields']; $i++)
+ {
+ //Additions of parameters: text: on: off: ...
+ if ( $i != 0 ) {
+ $tables_parameters .= ( !empty($_REQUEST['fields_param_elements'][$i]) ) ? "".$_REQUEST['fields_param_elements'][$i].":" : " :";
+ $tables_parameters .= ( !empty($_REQUEST['fields_param_display_admin'][$i]) ) ? "1:" : "0:";
+ $tables_parameters .= ( !empty($_REQUEST['fields_param_display_user'][$i]) ) ? "1:" : "0:";
+ $tables_parameters .= ( !empty($_REQUEST['fields_param_display_blocks'][$i]) ) ? "1:" : "0:";
+ $tables_parameters .= ( $i == $_REQUEST['fields_param_main_field']) ? "1:" : "0:";
+ $tables_parameters .= ( !empty($_REQUEST['fields_param_search_field'][$i]) ) ? "1:" : "0:";
+ $tables_parameters .= ( !empty($_REQUEST['fields_param_required_field'][$i]) ) ? "1" : "0";
+ }
+
+ //Additions of fields: test: int: 4: ...
+ $tables_fields .= (!empty($_REQUEST['fields_name'][$i])) ? "".$_REQUEST['fields_name'][$i].":" : " :";
+ $tables_fields .= (!empty($_REQUEST['fields_type'][$i])) ? "".$_REQUEST['fields_type'][$i].":" : " :";
+ $tables_fields .= (!empty($_REQUEST['fields_value'][$i])) ? "".$_REQUEST['fields_value'][$i].":" : " :";
+ $tables_fields .= (!empty($_REQUEST['fields_attributes'][$i])) ? "".$_REQUEST['fields_attributes'][$i].":" : " :";
+ $tables_fields .= (!empty($_REQUEST['fields_null'][$i])) ? "".strtoupper($_REQUEST['fields_null'][$i]).":" : " :";
+ $tables_fields .= (!empty($_REQUEST['fields_default'][$i])) ? "".$_REQUEST['fields_default'][$i].":" : " :";
+ $tables_fields .= (!empty($_REQUEST['fields_index'][$i])) ? "".$_REQUEST['fields_index'][$i]."" : " ";
+
+ //Break between fields and between the parameters
+ if ( $i != $_REQUEST['tables_nb_fields'] - 1) {
+ $tables_fields .= '|';
+ if ( $i != 0 )
+ $tables_parameters .= '|';
+ } else {
+ $tables_fields .= '|'.strtolower($_REQUEST['tables_name']).'_status:int:10: :NOT NULL:0:|'.strtolower($_REQUEST['tables_name']).'_waiting:int:10: :NOT NULL:0:|'.strtolower($_REQUEST['tables_name']).'_online:tinyint:1: :NOT NULL:0:';
+ $tables_parameters .= '|XoopsFormCheckBox:1:1:1:0:0:1|XoopsFormCheckBox:1:1:1:0:0:1|XoopsFormCheckBox:1:1:1:0:0:1';
+ }
+ }
+ }
+ $obj->setVar('tables_fields', $tables_fields);
+ $obj->setVar('tables_parameters', $tables_parameters);
+
+ if ($tablesHandler->insert($obj))
+ {
+ redirect_header('tables.php?op=default', 2, _AM_TDMCREATE_FORMOK);
+ }
+
+ break;
+
+ case "tables_save1":
+ if (!$GLOBALS['xoopsSecurity']->check()) {
+ redirect_header('tables.php', 3, implode(',', $GLOBALS['xoopsSecurity']->getErrors()));
+ }
+
+ if (isset($_REQUEST['tables_id'])) {
+ $obj =& $tablesHandler->get($_REQUEST['tables_id']);
+ } else {
+ $obj =& $tablesHandler->create();
+ }
+ //Module Name
+ $modules =& $modulesHandler->get($_REQUEST['tables_modules']);
+ $modules_name = $modules->getVar('modules_name');
+
+ $tables_blocks = (isset($_REQUEST['tables_blocks'])) ? $_REQUEST['tables_blocks'] : '0';
+ $tables_display_admin = (isset($_REQUEST['tables_display_admin'])) ? $_REQUEST['tables_display_admin'] : '0';
+ $tables_display_user = (isset($_REQUEST['tables_display_user'])) ? $_REQUEST['tables_display_user'] : '0';
+ $tables_status = (isset($_REQUEST['tables_status'])) ? $_REQUEST['tables_status'] : '0';
+ $tables_waiting = (isset($_REQUEST['tables_waiting'])) ? $_REQUEST['tables_waiting'] : '0';
+ $tables_online = (isset($_REQUEST['tables_online'])) ? $_REQUEST['tables_online'] : '0';
+ $tables_search = (isset($_REQUEST['tables_search'])) ? $_REQUEST['tables_search'] : '0';
+ $tables_comments = (isset($_REQUEST['tables_comments'])) ? $_REQUEST['tables_comments'] : '0';
+ $select = (isset($_REQUEST['select'])) ? $_REQUEST['select'] : '0';
+
+ //Image
+ include_once XOOPS_ROOT_PATH.'/class/uploader.php';
+ if(is_dir($pathIcon32)){
+ $uploaddir = $pathIcon32;
+ }else{
+ $uploaddir = XOOPS_ROOT_PATH . "/modules/".$xoopsModule->dirname()."/images/uploads/tables/";
+ }
+ $uploader = new XoopsMediaUploader($uploaddir, "gif|jpeg|pjpeg|png", 104857600, null, null);
+
+ if ($uploader->fetchMedia($_POST['xoops_upload_file'][0])) {
+ $extension = preg_replace( "/^.+\.([^.]+)$/sU" , "\\1" , $_FILES["attachedfile"]['name']) ;
+ $name_img = $_REQUEST['tables_name'].'.'.$extension;
+ $uploader->setTargetFileName($name_img);
+ $uploader->fetchMedia($_POST['xoops_upload_file'][0]);
+ if (!$uploader->upload()) {
+ $errors = $uploader->getErrors();
+ redirect_header("javascript:history.go(-1)",3, $errors);
+ } else {
+ $obj->setVar('tables_img', $uploader->getSavedFileName());
+ }
+ } else {
+ $obj->setVar('tables_img', $_REQUEST['tables_img']);
+ }
+
+
+ $oldname=$obj->getVar('tables_name');
+
+
+ $obj->setVar('tables_modules', strtolower($_REQUEST['tables_modules']));
+ $obj->setVar('tables_module_table', strtolower($modules_name.'_'.$_REQUEST['tables_name']));
+ $obj->setVar('tables_name', strtolower($_REQUEST['tables_name']));
+ $obj->setVar('tables_blocks', $_REQUEST['tables_blocks']);
+ $obj->setVar('tables_display_admin', $_REQUEST['tables_display_admin']);
+ $obj->setVar('tables_display_user', $_REQUEST['tables_display_user']);
+ $obj->setVar('tables_status', $_REQUEST['tables_status']);
+ $obj->setVar('tables_waiting', $_REQUEST['tables_waiting']);
+ $obj->setVar('tables_online', $_REQUEST['tables_online']);
+ //Setting isset for Search
+ if ( isset($_REQUEST['tables_search']) )
+ $obj->setVar('tables_search', $_REQUEST['tables_search']);
+ if ( isset($_REQUEST['tables_comments']) )
+ $obj->setVar('tables_comments', $_REQUEST['tables_comments']);
+ $obj->setVar('tables_nb_fields', $_REQUEST['tables_nb_fields']);
+
+ $tables_fields = $obj->getVar('tables_fields');
+ $tables_nb_fields=$_REQUEST['tables_nb_fields'];
+
+ $fields_total = explode("|", $tables_fields);
+ $count_fields = count($fields_total);
+
+ $newname=strtolower($_REQUEST['tables_name']);
+ //echo $count_parameters;
+ //fields
+ for($i=0; $i<$count_fields; $i++)
+ {
+// if ( $i >= $count_fields ) {
+// $fields_name[$i] = '';
+// $fields_type[$i] = '';
+// $fields_value[$i] = '';
+// $fields_attributes[$i] = '';
+// $fields_null[$i] = '';
+// $fields_default[$i] = '';
+// $fields_index[$i] = '';
+// } else {
+ $fields = explode(":", $fields_total[$i]);
+
+ $fields[0] = $newname . substr($fields[0],stripos($fields[0],'_'));
+// $fields_type[$i] = $fields[1];
+// $fields_value[$i] = $fields[2];
+// $fields_attributes[$i] = $fields[3];
+// $fields_null[$i] = $fields[4];
+// $fields_default[$i] = $fields[5];
+// $fields_index[$i] = $fields[6];
+ $newfields[$i]=implode(":",$fields);
+ //}
+ }
+
+$newTableFields=implode("|",$newfields);
+ $obj->setVar('tables_fields', $newTableFields);
+
+
+
+ if ($tablesHandler->insert($obj)) {
+ redirect_header('tables.php?op=default', 2, _AM_TDMCREATE_FORMOK);
+ }
+ break;
+
+ case "edit_tables":
+ $obj =& $tablesHandler->get($_REQUEST['tables_id']);
+ $form = $obj->getFormTable();
+ break;
+
+ case "edit_fields":
+ $obj =& $tablesHandler->get($_REQUEST['tables_id']);
+ $form = $obj->getFormEditFields(false, $_REQUEST['tables_id']);
+ break;
+
+ case "delete_tables":
+ $obj =& $tablesHandler->get($_REQUEST['tables_id']);
+ if (isset($_REQUEST['ok']) && $_REQUEST['ok'] == 1) {
+ if (!$GLOBALS['xoopsSecurity']->check()) {
+ redirect_header('tables.php', 3, implode(',', $GLOBALS['xoopsSecurity']->getErrors()));
+ }
+ if ($tablesHandler->delete($obj)) {
+ redirect_header('tables.php', 3, _AM_TDMCREATE_FORMDELOK);
+ } else {
+ echo $obj->getHtmlErrors();
+ }
+ } else {
+ xoops_confirm(array('ok' => 1, 'tables_id' => $_REQUEST['tables_id'], 'op' => 'delete_tables'), $_SERVER['REQUEST_URI'], sprintf(_AM_TDMCREATE_FORMSUREDEL, $obj->getVar('tables_name')));
+ }
+ break;
+ //-------------- MODULE -------------------------
+ case "modules_save":
+ if (!$GLOBALS['xoopsSecurity']->check()) {
+ ...
[truncated message content] |
|
From: <ce...@us...> - 2013-10-20 15:52:29
|
Revision: 12188
http://sourceforge.net/p/xoops/svn/12188
Author: cesag
Date: 2013-10-20 15:52:27 +0000 (Sun, 20 Oct 2013)
Log Message:
-----------
Updated version number indicated on the changelog (cesag)
Modified Paths:
--------------
XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php 2013-10-20 15:00:39 UTC (rev 12187)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php 2013-10-20 15:52:27 UTC (rev 12188)
@@ -32,7 +32,7 @@
xoops_load('XoopsLists');
$modversion['name'] = _MI_XNEWSLETTER_NAME;
-$modversion['version'] = 1.1;
+$modversion['version'] = 1.2;
$modversion['description'] = _MI_XNEWSLETTER_DESC;
$modversion['author'] = "Goffy, Alfred";
$modversion['credits'] = "";
@@ -56,10 +56,10 @@
$modversion['module_website_url'] = "wedega.com";
$modversion['module_website_name'] = "Webdesign Gabor";
$modversion['release'] = "1.0";
-$modversion['module_status'] = "Stable";
+$modversion['module_status'] = "Final";
$modversion['release_info'] = "";
$modversion['release_file'] = XOOPS_URL."/modules/{$dirname}/docs/";
-$modversion['release_date'] = "2013/08/27";
+$modversion['release_date'] = "2013/10/20";
$modversion['manual'] = "xNewsletter.txt";
$modversion['manual_file'] = XOOPS_URL."/modules/{$dirname}/docs/";
|
|
From: <ce...@us...> - 2013-10-20 15:00:42
|
Revision: 12187
http://sourceforge.net/p/xoops/svn/12187
Author: cesag
Date: 2013-10-20 15:00:39 +0000 (Sun, 20 Oct 2013)
Log Message:
-----------
Replacing <br/> with <br /> in english language files (cesag)
Modified Paths:
--------------
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/help/help.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php 2013-10-20 14:22:43 UTC (rev 12186)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php 2013-10-20 15:00:39 UTC (rev 12187)
@@ -89,7 +89,7 @@
define('_AM_XNEWSLETTER_SEND_ERROR_NO_EMAIL', "Error: No e-mail-address available");
define('_AM_XNEWSLETTER_SEND_ERROR_NO_LETTERID', "Error: No valid newsletter selected");
define('_AM_XNEWSLETTER_SEND_ERROR_INALID_TEMPLATE_PATH', "Error: template path '%p' not found");
-define('_AM_XNEWSLETTER_SEND_SURE_SENT', "This newsletter was already sent to all subscribers.<br/>Do you really want to send this newsletter again to all subscribers?");
+define('_AM_XNEWSLETTER_SEND_SURE_SENT', "This newsletter was already sent to all subscribers.<br />Do you really want to send this newsletter again to all subscribers?");
define('_AM_XNEWSLETTER_SEND_ERROR_NO_SUBSCR', "Error: No valid subscriptions for the selected newsletter(s) found");
//Index
define('_AM_XNEWSLETTER_LETTER', "Newsletter Statistics");
@@ -181,9 +181,9 @@
define('_AM_XNEWSLETTER_CAT_NAME', "Newsletter name");
define('_AM_XNEWSLETTER_CAT_INFO', "Additional info");
define('_AM_XNEWSLETTER_CAT_GPERMS_CREATE', "Permissions to create");
-define('_AM_XNEWSLETTER_CAT_GPERMS_CREATE_DESC', "<br/><span style='font-weight:normal'>- Create new newsletters<br/>- Edit, delete, send of own newsletters</span>");
+define('_AM_XNEWSLETTER_CAT_GPERMS_CREATE_DESC', "<br /><span style='font-weight:normal'>- Create new newsletters<br />- Edit, delete, send of own newsletters</span>");
define('_AM_XNEWSLETTER_CAT_GPERMS_ADMIN', "Permission to admin");
-define('_AM_XNEWSLETTER_CAT_GPERMS_ADMIN_DESC', "<br/><span style='font-weight:normal'>Edit, delete, send of all newsletters of this category</span>");
+define('_AM_XNEWSLETTER_CAT_GPERMS_ADMIN_DESC', "<br /><span style='font-weight:normal'>Edit, delete, send of all newsletters of this category</span>");
define('_AM_XNEWSLETTER_CAT_GPERMS_READ', "Permissions to read/subscribe");
define('_AM_XNEWSLETTER_CAT_GPERMS_LIST', "Permissions to see list of subscribers");
define('_AM_XNEWSLETTER_CAT_SUBMITTER', "Submitter");
@@ -291,10 +291,10 @@
define('_AM_XNEWSLETTER_BMH_MEASURE_QUITED', "Subscriber temporary quit");
define('_AM_XNEWSLETTER_BMH_MEASURE_DELETED', "Subscriber deleted");
define('_AM_XNEWSLETTER_BMH_MEASURE_ALREADY_DELETED', "Subscriber already deleted! Action not possible!");
-define('_AM_XNEWSLETTER_BMH_MEASURE_DELETE_SURE', "Do you really want to delete this registration with all subscriptions?<br /><br />Reactivating by the subscriber will not be possible later!<br/><br />");
+define('_AM_XNEWSLETTER_BMH_MEASURE_DELETE_SURE', "Do you really want to delete this registration with all subscriptions?<br /><br />Reactivating by the subscriber will not be possible later!<br /><br />");
define('_AM_XNEWSLETTER_BMH_ERROR_NO_SUBSCRID', "There is nor existing registration for the this email!");
define('_AM_XNEWSLETTER_BMH_ERROR_NO_ACTIVE', "Bounced email handler isn't activated in any account");
-define('_AM_XNEWSLETTER_BMH_RSLT', "Result of checking mailbox %b<br/>Messages read: %r<br/>Action taken: %a<br/>No action taken: %n<br/>Moved: %m<br/>Deleted: %d<br/><br/><br/>");
+define('_AM_XNEWSLETTER_BMH_RSLT', "Result of checking mailbox %b<br />Messages read: %r<br />Action taken: %a<br />No action taken: %n<br />Moved: %m<br />Deleted: %d<br /><br /><br />");
define('_AM_XNEWSLETTER_BMH_SUCCESSFUL', "Bounced email handler successfully finished");
define('_AM_XNEWSLETTER_BMH_MEASURE_ALL', "Show all");
define('_AM_XNEWSLETTER_BMH_MEASURE_SHOW_NONE', "No Bounced email items for measure '%s' available");
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/help/help.html
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/help/help.html 2013-10-20 14:22:43 UTC (rev 12186)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/help/help.html 2013-10-20 15:00:39 UTC (rev 12187)
@@ -68,67 +68,67 @@
<h5 class="odd">(Un) subscriptions to newsletters</h5>
<p class="even">
- You can define for each newsletter and for each group, whether for (un) subscritpion or change a confirmation email with activation key is necessary or not (use double-option).<br/>
+ You can define for each newsletter and for each group, whether for (un) subscritpion or change a confirmation email with activation key is necessary or not (use double-option).<br />
<br /><br /></p>
<h5 class="odd">Accounts</h5>
<p class="even">
- You can use one or more email-account; sending with php mail, php sendmail, smtp is possible.<br/>
- There is a feature for testing pop3 and imap accounts.<br/>
+ You can use one or more email-account; sending with php mail, php sendmail, smtp is possible.<br />
+ There is a feature for testing pop3 and imap accounts.<br />
<br />
- Pay attention: functions like testing account, sending emails, start Bounced email handler,... work not with local server (you get white page without any error).<br/>
+ Pay attention: functions like testing account, sending emails, start Bounced email handler,... work not with local server (you get white page without any error).<br />
<br /><br /></p>
<h5 class="odd">Newsletter categories</h5>
<p class="even">
- You can handle one or more newsletter categories.<br/>
- It is possible to set permissions "read", "create", "admin" and "list subscribers" for each newsletter cat.<br/>
+ You can handle one or more newsletter categories.<br />
+ It is possible to set permissions "read", "create", "admin" and "list subscribers" for each newsletter cat.<br />
<br /><br /></p>
<h5 class="odd">Create a newsletter</h5>
<p class="even">
- The newsletter can be created with each text editor which is installed in current xoops core (e.g. TinyMCE). <br/>
- For each newsletter you can use different templates (see also 'Newsletter templates').<br/>
- You can define one or more newsletter categories for your newsletter.<br/>
- You can add 5 files maximum as attachment to each newsletter.<br/><br/>
- Optionally you can also copy an older newsletter and edit or send it as a new one.<br/><br/>
- The type of text editor, allows mime-types and size of mail attachments can be set in module preferences.<br/>
+ The newsletter can be created with each text editor which is installed in current xoops core (e.g. TinyMCE). <br />
+ For each newsletter you can use different templates (see also 'Newsletter templates').<br />
+ You can define one or more newsletter categories for your newsletter.<br />
+ You can add 5 files maximum as attachment to each newsletter.<br /><br />
+ Optionally you can also copy an older newsletter and edit or send it as a new one.<br /><br />
+ The type of text editor, allows mime-types and size of mail attachments can be set in module preferences.<br />
<br /><br /></p>
<h5 class="odd">Newsletter templates</h5>
<p class="even">
- The newsletters are template based.<br/>
- The templates you can find in language/{yourlanguage}/templates.<br/>
- To create a new template you have only to make a new html-file in this folder and to put in the smarty-vars.<br/>
+ The newsletters are template based.<br />
+ The templates you can find in language/{yourlanguage}/templates.<br />
+ To create a new template you have only to make a new html-file in this folder and to put in the smarty-vars.<br />
<br /><br /></p>
<h5 class="odd">Sending newsletter</h5>
<p class="even">
- You can show a preview of a newsletter before sending.<br/>
- You can send the newsletter for testing to a defined email-address.<br/>
- The newsletters will be sent subscriber by subscriber.<br/>
- For each sending action a protocol will be created.<br/>
- If one or more send failed, you can see it in the protocol.<br/>
- You can restart sending procedure. You can send it again to all subscribers or send it only to the subscribers, where sending procedure failed).<br/>
+ You can show a preview of a newsletter before sending.<br />
+ You can send the newsletter for testing to a defined email-address.<br />
+ The newsletters will be sent subscriber by subscriber.<br />
+ For each sending action a protocol will be created.<br />
+ If one or more send failed, you can see it in the protocol.<br />
+ You can restart sending procedure. You can send it again to all subscribers or send it only to the subscribers, where sending procedure failed).<br />
<br />
- You can send all emails immediately or limit emails send in one package.<br/>
- The number of emails and the minutes untill next sending can be defined in module preferences (e.g. 200 emails all 60 minutes).<br/>
- The first package will be sent immediately. To start the next sending procedure you need an external cronjob, which is calling "../modules/xNewsletter/cron.php". Xoops cannot do this with current version (2.5.5).<br/>
- <br/>
- Pay attention: functions like testing account, sending emails, start Bounced email handler,... work not with local server (you get white page).<br/>
+ You can send all emails immediately or limit emails send in one package.<br />
+ The number of emails and the minutes untill next sending can be defined in module preferences (e.g. 200 emails all 60 minutes).<br />
+ The first package will be sent immediately. To start the next sending procedure you need an external cronjob, which is calling "../modules/xNewsletter/cron.php". Xoops cannot do this with current version (2.5.5).<br />
+ <br />
+ Pay attention: functions like testing account, sending emails, start Bounced email handler,... work not with local server (you get white page).<br />
<br /><br /></p>
<h5 class="odd">Task list</h5>
<p class="even">
- If you limit emails send in one package, you can see all newsletters waiting for next cronjob and the time, when cronjob can send the newsletter.<br/>
- If you do not use this option, this list must always be empty.<br/>
- Normally the tab "Task list" is hidden, if this option is disabled.<br/>
+ If you limit emails send in one package, you can see all newsletters waiting for next cronjob and the time, when cronjob can send the newsletter.<br />
+ If you do not use this option, this list must always be empty.<br />
+ Normally the tab "Task list" is hidden, if this option is disabled.<br />
<br /><br /></p>
<h5 class="odd">Handle mailing lists</h5>
<p class="even">
- If you have an existing mailing list, you can synchronize the (un) subscriptions of one newsletter category with one mailing list.<br/>
- I use majordomo beside this newsletter module because then I can also send an email from my email-client to the newsletter recipients.<br/>
+ If you have an existing mailing list, you can synchronize the (un) subscriptions of one newsletter category with one mailing list.<br />
+ I use majordomo beside this newsletter module because then I can also send an email from my email-client to the newsletter recipients.<br />
One of the disadvantages of mailing lists is, that, if one person is registered in two or more mailing lists and you send a one newsletter to all mailing lists, this person gets the same newsletter more than one time. With xNewsletter he gets only one newsletter.<br />
<br />
<br />Normally the tab "Mailing list" is hidden, if this option is disabled.<br />
@@ -138,26 +138,26 @@
<h5 class="odd">Bounced email handler (BMH)</h5>
<p class="even">
- If you send newsletters, there will always be some emails not delivered to recipient (Bounced email), because email is no more valid, mailbox is full, and so on.<br/>
- To handle this event and to react on this, you can use BMH.<br/>
- You can activate BMH for each account.<br/>
- Mails, which are detected as Bounced emails by BMH, can be deleted or moved in a special folder, you have to define.<br/>
- Possible actions for Bounced emails:<br/>
- -- no action (only store)<br/>
- -- quit temporary the subscriptions of this email-address<br/>
- -- delete the subscriptions of this email-address<br/>
- <br/>
+ If you send newsletters, there will always be some emails not delivered to recipient (Bounced email), because email is no more valid, mailbox is full, and so on.<br />
+ To handle this event and to react on this, you can use BMH.<br />
+ You can activate BMH for each account.<br />
+ Mails, which are detected as Bounced emails by BMH, can be deleted or moved in a special folder, you have to define.<br />
+ Possible actions for Bounced emails:<br />
+ -- no action (only store)<br />
+ -- quit temporary the subscriptions of this email-address<br />
+ -- delete the subscriptions of this email-address<br />
<br />
+ <br />
<h6 class="odd">Types of Bounced emails</h6>
<u>bounce type hard:</u>
- This means that there is a permanent error when sending a mail, e.g. unknown recipient, unknown domain, and so on.<br/>
- This mails will be deleted after detection, so it is recommended using the move hard option (the email will be only moved in this folder, you can check this mail later, if you want).<br/>
+ This means that there is a permanent error when sending a mail, e.g. unknown recipient, unknown domain, and so on.<br />
+ This mails will be deleted after detection, so it is recommended using the move hard option (the email will be only moved in this folder, you can check this mail later, if you want).<br />
<br />
- <u>bounce type soft:</u><br/>
- This means that there is a temporary problem with sending a mail, e.g. mailbox full, server not available, and so on.<br/>
- This mails will not be deleted after detection, but it is recommended using the move soft option in order to keep your basic in box clean.<br/>
+ <u>bounce type soft:</u><br />
+ This means that there is a temporary problem with sending a mail, e.g. mailbox full, server not available, and so on.<br />
+ This mails will not be deleted after detection, but it is recommended using the move soft option in order to keep your basic in box clean.<br />
<br />
- Pay attention: functions like testing account, sending emails, start Bounced email handler,... work not with local server (you get white page).<br/>
+ Pay attention: functions like testing account, sending emails, start Bounced email handler,... work not with local server (you get white page).<br />
<br /><br /></p>
<h5 class="odd">Maintenance</h5>
@@ -177,15 +177,15 @@
<li>module subscribers</li>
<li>users from xoops users</li>
<ul>
- The import tool works in this way:<br/>
- - Adding email to the list of subscribers<br/>
- - Subscribe this email to one newsletter cat<br/>
- Before you run import tool therefore, please create first minimum one newsletter cat, otherwise the email cannot be subscribed to a cat and the import fails.<br/>
- You have the possibility<br/>
- - to import the E-Mail-Addresses without any check (recommended for big import data sets) or<br/>
- - after reading data you can decide for each email<br/>
- -- whether you want to make a subscription or not<br/>
- -- to which newsletter you want to make the subscription<br/>
+ The import tool works in this way:<br />
+ - Adding email to the list of subscribers<br />
+ - Subscribe this email to one newsletter cat<br />
+ Before you run import tool therefore, please create first minimum one newsletter cat, otherwise the email cannot be subscribed to a cat and the import fails.<br />
+ You have the possibility<br />
+ - to import the E-Mail-Addresses without any check (recommended for big import data sets) or<br />
+ - after reading data you can decide for each email<br />
+ -- whether you want to make a subscription or not<br />
+ -- to which newsletter you want to make the subscription<br />
If an email is already registered, import of this email should be skipped (default action, do not touch existing registrations).
<br />
Sample files (sample1col.csv, sample4col.csv) for csv-import you can find in ../xNewsletter/plugins/
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php 2013-10-20 14:22:43 UTC (rev 12186)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php 2013-10-20 15:00:39 UTC (rev 12187)
@@ -45,12 +45,12 @@
define('_MA_XNEWSLETTER_SUBSCRIPTION_EXIST', "Existing subscriptions");
define('_MA_XNEWSLETTER_SUBSCRIPTION_EXIST_NONE', "No subscriptions existing");
define('_MA_XNEWSLETTER_REGISTRATION_EXIST', "Existing registrations of this email");
-define('_MA_XNEWSLETTER_REGISTRATION_NONE', "Your email isn't registered till now. For subscriptions we need further information. Please fill in registration form.<br/>We want to inform you, that your ip-address will be saved for the purpose of transparency.");
+define('_MA_XNEWSLETTER_REGISTRATION_NONE', "Your email isn't registered till now. For subscriptions we need further information. Please fill in registration form.<br />We want to inform you, that your ip-address will be saved for the purpose of transparency.");
define('_MA_XNEWSLETTER_REGISTRATION_ADD', "If you want, you can add more than one person to one email, and later on you can make different suscriptions");
define('_MA_XNEWSLETTER_SUBSCRIPTION_ADD', "Add a new subscription");
define('_MA_XNEWSLETTER_SUBSCRIPTION_EDIT', "Edit subscriptions");
define('_MA_XNEWSLETTER_SUBSCRIPTION_DELETE', "Delete subscriptions");
-define('_MA_XNEWSLETTER_SUBSCRIPTION_DELETE_SURE', "Do you really want to delete this registration with all subscriptions?<br /><br />If you want to (un)subscribe for one or more newsletters, please use the edit button!<br/><br />");
+define('_MA_XNEWSLETTER_SUBSCRIPTION_DELETE_SURE', "Do you really want to delete this registration with all subscriptions?<br /><br />If you want to (un)subscribe for one or more newsletters, please use the edit button!<br /><br />");
define('_MA_XNEWSLETTER_SUBSCRIPTION_INFO_PERS', "Your personal information");
define('_MA_XNEWSLETTER_SUBSCRIPTION_SELECT_CATS', "Select your newsletter");
define('_MA_XNEWSLETTER_SUBSCRIPTION_CATS_AVAIL', "Available newsletters");
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php 2013-10-20 14:22:43 UTC (rev 12186)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php 2013-10-20 15:00:39 UTC (rev 12187)
@@ -72,7 +72,7 @@
define('_MI_XNEWSLETTER_ATTACHMENT_PATH', "Upload-path");
define('_MI_XNEWSLETTER_ATTACHMENT_PATH_DESC', "Define path, where uploaded attachments will be saved ( folders after {XOOPS_ROOT_PATH}/uploads ), <b>with slash at beginning</b> and <b>with tailing slash</b>.");
define('_MI_XNEWSLETTER_USE_MAILINGLIST', "Use additional feature mailinglists");
-define('_MI_XNEWSLETTER_USE_MAILINGLIST_DESC', "If you have an existing mailinglist, you can syncronize the (un)subscriptions of one newsletter category with one mailing list.<br/>I use majordomo beside this newsletter module, because then I can also send an email form my email-client to the newsletter.<br/>The of the disadvantages of mailinglists is, that, if one person is registered in two or more mailinglists and you send a one newsletter to all mailinglists, this person gets the same newsletter more than one time. With xNewsletter he gets only one newsletter.");
+define('_MI_XNEWSLETTER_USE_MAILINGLIST_DESC', "If you have an existing mailinglist, you can syncronize the (un)subscriptions of one newsletter category with one mailing list.<br />I use majordomo beside this newsletter module, because then I can also send an email form my email-client to the newsletter.<br />The of the disadvantages of mailinglists is, that, if one person is registered in two or more mailinglists and you send a one newsletter to all mailinglists, this person gets the same newsletter more than one time. With xNewsletter he gets only one newsletter.");
define('_MI_XNEWSLETTER_GROUPS_WITHOUT_ACTKEY', "Groups (un)subscribing without confirmation email");
define('_MI_XNEWSLETTER_GROUPS_WITHOUT_ACTKEY_DESC', "Define the groups, which can make (un)subscriptions to a newsletter directly, without sending back a confirmation email");
define('_MI_XNEWSLETTER_GROUPS_CHANGE_OTHER', "Groups with permission to change subscription of other persons");
|
|
From: <ce...@us...> - 2013-10-20 14:22:45
|
Revision: 12186
http://sourceforge.net/p/xoops/svn/12186
Author: cesag
Date: 2013-10-20 14:22:43 +0000 (Sun, 20 Oct 2013)
Log Message:
-----------
Fixed typos in the English language files (cesag)
Modified Paths:
--------------
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/help/help.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php 2013-10-20 12:27:39 UTC (rev 12185)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php 2013-10-20 14:22:43 UTC (rev 12186)
@@ -82,8 +82,8 @@
define('_AM_XNEWSLETTER_SEND_SUCCESS', "Newsletter sent");
define('_AM_XNEWSLETTER_SEND_SUCCESS_TEST', "Newsletter sent for test");
define('_AM_XNEWSLETTER_SEND_SUCCESS_NUMBER', "Sending %t newsletter(s) successfully");
-define('_AM_XNEWSLETTER_SEND_SUCCESS_ML', "Handle mailinglist successfully");
-define('_AM_XNEWSLETTER_SEND_SUCCESS_ML_DETAIL', "Sending '%a' to mailinglist successfully");
+define('_AM_XNEWSLETTER_SEND_SUCCESS_ML', "Handle mailing list successfully");
+define('_AM_XNEWSLETTER_SEND_SUCCESS_ML_DETAIL', "Sending '%a' to mailing list successfully");
define('_AM_XNEWSLETTER_SEND_ERROR_NUMBER', "Error sending newsletter: %e of %t newsletters not sent");
define('_AM_XNEWSLETTER_SEND_ERROR_PHPMAILER', "Error phpmailer: ");
define('_AM_XNEWSLETTER_SEND_ERROR_NO_EMAIL', "Error: No e-mail-address available");
@@ -129,9 +129,9 @@
define('_AM_XNEWSLETTER_NEWMAILINGLIST', "Add New Mailinglist");
define('_AM_XNEWSLETTER_MAILINGLISTLIST', "List Mailinglist");
define('_AM_XNEWSLETTER_MAILINGLISTWAIT', "Pending Mailinglist");
-define('_AM_XNEWSLETTER_RUNBMH', "Run bounced mail handler");
-define('_AM_XNEWSLETTER_BMHLIST', "List bounced mail handlers");
-define('_AM_XNEWSLETTER_BMHWAIT', "Pending bounced mail handlers");
+define('_AM_XNEWSLETTER_RUNBMH', "Run Bounced email handler");
+define('_AM_XNEWSLETTER_BMHLIST', "List Bounced email handlers");
+define('_AM_XNEWSLETTER_BMHWAIT', "Pending Bounced email handlers");
define('_AM_XNEWSLETTER_ACCOUNTS_ADD', "Add an Account");
define('_AM_XNEWSLETTER_ACCOUNTS_EDIT', "Edit an Account");
define('_AM_XNEWSLETTER_ACCOUNTS_DELETE', "Delete an Account");
@@ -151,32 +151,32 @@
define('_AM_XNEWSLETTER_ACCOUNTS_PORT_OUT', "Port out");
define('_AM_XNEWSLETTER_ACCOUNTS_SECURETYPE_OUT', "Securetype out");
define('_AM_XNEWSLETTER_ACCOUNTS_DEFAULT', "Default account");
-define('_AM_XNEWSLETTER_ACCOUNTS_BOUNCE_INFO', "Addtional info for bounced mails handling");
-define('_AM_XNEWSLETTER_ACCOUNTS_USE_BMH', "Use bounced mails handling");
-define('_AM_XNEWSLETTER_ACCOUNTS_INBOX', "Mailbox to check for bounced mails");
-define('_AM_XNEWSLETTER_ACCOUNTS_HARDBOX', "Use this mailbox as 'hardbox'");
-define('_AM_XNEWSLETTER_ACCOUNTS_HARDBOX_DESC', "The mailboxname must start with 'INBOX.'. You can select a standard folder in your mailbox (e.g. INBOX.Trash) or create your own special folders like 'hard' and 'soft'. If you type in a new folder name, the folder will be created (this function is not available for gmail-accounts).");
-define('_AM_XNEWSLETTER_ACCOUNTS_MOVEHARD', "Move bounced mail in 'hardbox'");
-define('_AM_XNEWSLETTER_ACCOUNTS_SOFTBOX', "Use this mailbox as 'softbox'");
-define('_AM_XNEWSLETTER_ACCOUNTS_MOVESOFT', "Move bounced mail in 'softbox'");
+define('_AM_XNEWSLETTER_ACCOUNTS_BOUNCE_INFO', "Addtional info for Bounced emails handling");
+define('_AM_XNEWSLETTER_ACCOUNTS_USE_BMH', "Use Bounced emails handling");
+define('_AM_XNEWSLETTER_ACCOUNTS_INBOX', "Mailbox to check for Bounced emails");
+define('_AM_XNEWSLETTER_ACCOUNTS_HARDBOX', "Use this mailbox as 'hard box'");
+define('_AM_XNEWSLETTER_ACCOUNTS_HARDBOX_DESC', "The mailbox name must start with 'INBOX.'. You can select a standard folder in your mailbox (e.g. INBOX.Trash) or create your own special folders like 'hard' and 'soft'. If you type in a new folder name, the folder will be created (this function is not available for gmail-accounts).");
+define('_AM_XNEWSLETTER_ACCOUNTS_MOVEHARD', "Move Bounced email in 'hard box'");
+define('_AM_XNEWSLETTER_ACCOUNTS_SOFTBOX', "Use this mailbox as 'soft box'");
+define('_AM_XNEWSLETTER_ACCOUNTS_MOVESOFT', "Move Bounced email in 'soft box'");
define('_AM_XNEWSLETTER_ACCOUNTS_SUBMITTER', "Submitter");
define('_AM_XNEWSLETTER_ACCOUNTS_CREATED', "Created");
define('_AM_XNEWSLETTER_ACCOUNTS_ERROR_OPEN_MAILBOX', "Error open mailbox! Please check your settings!");
define('_AM_XNEWSLETTER_SAVE_AND_CHECK', "Save and check settings");
-define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_OK', "succesful ");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_OK', "successful ");
define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_FAILED', "failed ");
define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_SKIPPED', "skipped");
define('_AM_XNEWSLETTER_ACCOUNTS_CHECK', "Check result");
define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_INFO', "Additional info");
define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_OPEN_MAILBOX', "Open mailbox ");
define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_OPEN_FOLDERS', "Open folders ");
-define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH', "Bounced mail handler ");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH', "Bounced email handler ");
define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH_INBOX', "Mailbox");
define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH_HARDBOX', "Hardbox");
define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH_SOFTBOX', "Softbox");
define('_AM_XNEWSLETTER_CAT_ADD', "Add a category");
-define('_AM_XNEWSLETTER_CAT_EDIT', "Edit a categories");
-define('_AM_XNEWSLETTER_CAT_DELETE', "Delete a categories");
+define('_AM_XNEWSLETTER_CAT_EDIT', "Edit a category");
+define('_AM_XNEWSLETTER_CAT_DELETE', "Delete a category");
define('_AM_XNEWSLETTER_CAT_ID', "Id");
define('_AM_XNEWSLETTER_CAT_NAME', "Newsletter name");
define('_AM_XNEWSLETTER_CAT_INFO', "Additional info");
@@ -188,15 +188,15 @@
define('_AM_XNEWSLETTER_CAT_GPERMS_LIST', "Permissions to see list of subscribers");
define('_AM_XNEWSLETTER_CAT_SUBMITTER', "Submitter");
define('_AM_XNEWSLETTER_CAT_CREATED', "Created");
-define('_AM_XNEWSLETTER_CAT_MAILINGLIST', "Mailinglist");
+define('_AM_XNEWSLETTER_CAT_MAILINGLIST', "Mailing list");
define('_AM_XNEWSLETTER_SUBSCR_ADD', "Add a Subscriber");
define('_AM_XNEWSLETTER_SUBSCR_EDIT', "Edit a Subscriber");
define('_AM_XNEWSLETTER_SUBSCR_DELETE', "Delete a Subscriber");
define('_AM_XNEWSLETTER_SUBSCR_ID', "Id");
define('_AM_XNEWSLETTER_SUBSCR_EMAIL', "Email");
-define('_AM_XNEWSLETTER_SUBSCR_FIRSTNAME', "Firstname");
-define('_AM_XNEWSLETTER_SUBSCR_LASTNAME', "Lastname");
-define('_AM_XNEWSLETTER_SUBSCR_UID', "Membername");
+define('_AM_XNEWSLETTER_SUBSCR_FIRSTNAME', "First name");
+define('_AM_XNEWSLETTER_SUBSCR_LASTNAME', "Last name");
+define('_AM_XNEWSLETTER_SUBSCR_UID', "Member name");
define('_AM_XNEWSLETTER_SUBSCR_SEX', "Salutation");
define('_AM_XNEWSLETTER_SUBSCR_SEX_EMPTY', "");
define('_AM_XNEWSLETTER_SUBSCR_SEX_MALE', "Mr.");
@@ -207,13 +207,13 @@
define('_AM_XNEWSLETTER_SUBSCR_CREATED', "Created");
define('_AM_XNEWSLETTER_SUBSCR_ACTIVATED', "activated?");
define('_AM_XNEWSLETTER_SUBSCR_SHOW_ALL', "Show all");
-define('_AM_XNEWSLETTER_CATSUBSCR_ADD', "Add a Categories-Subscribers");
-define('_AM_XNEWSLETTER_CATSUBSCR_EDIT', "Edit a Categories-Subscribers");
-define('_AM_XNEWSLETTER_CATSUBSCR_DELETE', "Delete a Categories-Subscribers");
+define('_AM_XNEWSLETTER_CATSUBSCR_ADD', "Add a subscriber to a category");
+define('_AM_XNEWSLETTER_CATSUBSCR_EDIT', "Edit a a subscriber to a category");
+define('_AM_XNEWSLETTER_CATSUBSCR_DELETE', "Delete a subscriber to a category");
define('_AM_XNEWSLETTER_CATSUBSCR_ID', "Id");
-define('_AM_XNEWSLETTER_CATSUBSCR_CATID', "Cat-Id");
+define('_AM_XNEWSLETTER_CATSUBSCR_CATID', "Newsletter");
define('_AM_XNEWSLETTER_CATSUBSCR_SUBSCRID', "Subscribers");
-define('_AM_XNEWSLETTER_CATSUBSCR_QUITED', "Quited");
+define('_AM_XNEWSLETTER_CATSUBSCR_QUITED', "Unsubscribed");
define('_AM_XNEWSLETTER_CATSUBSCR_SUBMITTER', "Submitter");
define('_AM_XNEWSLETTER_CATSUBSCR_CREATED', "Created");
define('_AM_XNEWSLETTER_CATSUBSCR_SUREDELETE', "Do you really want to delete<br />'%s'<br />from<br />'%c' ?");
@@ -264,20 +264,20 @@
define('_AM_XNEWSLETTER_MAILINGLIST_ID', "Id");
define('_AM_XNEWSLETTER_MAILINGLIST_NAME', "Name");
define('_AM_XNEWSLETTER_MAILINGLIST_EMAIL', "Email");
-define('_AM_XNEWSLETTER_MAILINGLIST_EMAIL_DESC', "Email, where subscription code should be send to");
+define('_AM_XNEWSLETTER_MAILINGLIST_EMAIL_DESC', "Email, where subscription code should be sending to");
define('_AM_XNEWSLETTER_MAILINGLIST_LISTNAME', "Listname");
define('_AM_XNEWSLETTER_MAILINGLIST_SUBSCRIBE', "Subscribe code");
define('_AM_XNEWSLETTER_MAILINGLIST_SUBSCRIBE_DESC', "{email} will be replaced by the email of the subscriber");
define('_AM_XNEWSLETTER_MAILINGLIST_UNSUBSCRIBE', "Unsubscribe code");
define('_AM_XNEWSLETTER_MAILINGLIST_SUBMITTER', "Submitter");
define('_AM_XNEWSLETTER_MAILINGLIST_CREATED', "Created");
-define('_AM_XNEWSLETTER_BOUNCETYPE', "Bouncetype");
-define('_AM_XNEWSLETTER_BMH_EDIT', "Edit a bounced mail handler");
-define('_AM_XNEWSLETTER_BMH_DELETE', "Delete a bounced mail handler");
+define('_AM_XNEWSLETTER_BOUNCETYPE', "Bounce type");
+define('_AM_XNEWSLETTER_BMH_EDIT', "Edit a Bounced email handler");
+define('_AM_XNEWSLETTER_BMH_DELETE', "Delete a Bounced email handler");
define('_AM_XNEWSLETTER_BMH_ID', "Id");
define('_AM_XNEWSLETTER_BMH_RULE_NO', "Rule no");
define('_AM_XNEWSLETTER_BMH_RULE_CAT', "Rule cat");
-define('_AM_XNEWSLETTER_BMH_BOUNCETYPE', "Bouncetype");
+define('_AM_XNEWSLETTER_BMH_BOUNCETYPE', "Bounce type");
define('_AM_XNEWSLETTER_BMH_REMOVE', "Removed");
define('_AM_XNEWSLETTER_BMH_EMAIL', "Email");
define('_AM_XNEWSLETTER_BMH_SUBJECT', "Subject");
@@ -288,22 +288,22 @@
define('_AM_XNEWSLETTER_BMH_MEASURE_NOTHING', "Do nothing");
define('_AM_XNEWSLETTER_BMH_MEASURE_QUIT', "Quit this subscriber temporary");
define('_AM_XNEWSLETTER_BMH_MEASURE_DELETE', "Delete this subscriber");
-define('_AM_XNEWSLETTER_BMH_MEASURE_QUITED', "Subscriber temporary quited");
+define('_AM_XNEWSLETTER_BMH_MEASURE_QUITED', "Subscriber temporary quit");
define('_AM_XNEWSLETTER_BMH_MEASURE_DELETED', "Subscriber deleted");
define('_AM_XNEWSLETTER_BMH_MEASURE_ALREADY_DELETED', "Subscriber already deleted! Action not possible!");
-define('_AM_XNEWSLETTER_BMH_MEASURE_DELETE_SURE', "Do you really want to delete this registration with all subscriptions?<br /><br />Reactivating by the subscriber will not be posssible later!<br/><br />");
+define('_AM_XNEWSLETTER_BMH_MEASURE_DELETE_SURE', "Do you really want to delete this registration with all subscriptions?<br /><br />Reactivating by the subscriber will not be possible later!<br/><br />");
define('_AM_XNEWSLETTER_BMH_ERROR_NO_SUBSCRID', "There is nor existing registration for the this email!");
-define('_AM_XNEWSLETTER_BMH_ERROR_NO_ACTIVE', "Bounced mail handler isn't activated in any account");
+define('_AM_XNEWSLETTER_BMH_ERROR_NO_ACTIVE', "Bounced email handler isn't activated in any account");
define('_AM_XNEWSLETTER_BMH_RSLT', "Result of checking mailbox %b<br/>Messages read: %r<br/>Action taken: %a<br/>No action taken: %n<br/>Moved: %m<br/>Deleted: %d<br/><br/><br/>");
-define('_AM_XNEWSLETTER_BMH_SUCCESSFUL', "Bounced mail handler successfully finished");
+define('_AM_XNEWSLETTER_BMH_SUCCESSFUL', "Bounced email handler successfully finished");
define('_AM_XNEWSLETTER_BMH_MEASURE_ALL', "Show all");
-define('_AM_XNEWSLETTER_BMH_MEASURE_SHOW_NONE', "No bmh items for measure '%s' available");
+define('_AM_XNEWSLETTER_BMH_MEASURE_SHOW_NONE', "No Bounced email items for measure '%s' available");
define('_AM_XNEWSLETTER_MAINTENANCE_CAT', "Category");
define('_AM_XNEWSLETTER_MAINTENANCE_DESCR', "Description");
-define('_AM_XNEWSLETTER_MAINTENANCE_PARAM', "Params");
+define('_AM_XNEWSLETTER_MAINTENANCE_PARAM', "Parameter");
define('_AM_XNEWSLETTER_MAINTENANCE_ERROR', "Error while running maintenance");
-define('_AM_XNEWSLETTER_MAINTENANCE_DELETEDATE', "Delete all registrations without confirmation, where registration was before this date.<br />Attention: there is noe undo possible! Please check date before execution!");
-define('_AM_XNEWSLETTER_MAINTENANCE_DELETEUSER', "Should these <b>%s</b> unconfirmed registrations with date before %s really deleted.<br />Attention: there is noe undo possible!");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETEDATE', "Delete all registrations without confirmation, where registration was before this date.<br />Attention: there is no undo possible! Please check date before!");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETEUSER', "Should these <b>%s</b> unconfirmed registrations with date before %s really deleted.<br />Attention: there is no undo possible!");
define('_AM_XNEWSLETTER_MAINTENANCE_DELETEPROTOCOL', "Delete all protocols and reset tables");
define('_AM_XNEWSLETTER_MAINTENANCE_DELETEPROTOK', "Table protocol maintained.");
define('_AM_XNEWSLETTER_MAINTENANCE_DELETENOTHING', "No action necessary.");
@@ -311,43 +311,43 @@
define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_SUBCR', "Delete subscriptions to newsletter without an existing registration");
define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_SUBCR_OK', "%s subscriptions have been deleted");
define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_SUBCR_NODATA', "No invalid data in table catsubsr found");
-define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML', "Compare data from newsletter cats with mailinglists and correct invalid data");
-define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML_OK', "%s wrong data in mailinglist have been corrected");
-define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML_NODATA', "No invalid data mailinglist found");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML', "Compare data from newsletter cats with mailing lists and correct invalid data");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML_OK', "%s wrong data in mailing list have been corrected");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML_NODATA', "No invalid data mailing list found");
define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_CATNL', "Compare data from newsletter cats with newsletters and correct invalid data");
define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_CATNL_OK', "%s wrong data in newsletters have been corrected");
define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_CATNL_NODATA', "No invalid data newsletters found");
define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_IMPORT', "Delete table import and reset table");
define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_IMPORT_OK', "Table import maintained.");
-define('_AM_XNEWSLETTER_IMPORT_SEARCH', "Search available E-Mail-Addresses for import");
+define('_AM_XNEWSLETTER_IMPORT_SEARCH', "Search available email addresses to import");
define('_AM_XNEWSLETTER_IMPORT_PRESELECT_CAT', "Preselect category");
-define('_AM_XNEWSLETTER_IMPORT_PLUGINS_AVAIL', "Available plugins");
+define('_AM_XNEWSLETTER_IMPORT_PLUGINS_AVAIL', "Available plug-ins");
define('_AM_XNEWSLETTER_IMPORT_CONTINUE', "Continue");
define('_AM_XNEWSLETTER_IMPORT_AFTER_READ', "Action after reading the data");
-define('_AM_XNEWSLETTER_IMPORT_READ_CHECK', "Show data for check");
-define('_AM_XNEWSLETTER_IMPORT_CHECK_LIMIT', "Limit E-Mail-Addresses for import");
+define('_AM_XNEWSLETTER_IMPORT_READ_CHECK', "Show data to check");
+define('_AM_XNEWSLETTER_IMPORT_CHECK_LIMIT', "Limit email addresses to import");
define('_AM_XNEWSLETTER_IMPORT_CHECK_LIMIT_PACKAGE', "Limit E-Mail-Addresses per processing step");
define('_AM_XNEWSLETTER_IMPORT_NOLIMIT', "No limit");
define('_AM_XNEWSLETTER_IMPORT_READ_IMPORT', "Import data at once without a check");
define('_AM_XNEWSLETTER_IMPORT_SHOW', "Show %s to %l of %n available E-Mail-Addresses");
define('_AM_XNEWSLETTER_IMPORT_NODATA', "No data found");
-define('_AM_XNEWSLETTER_IMPORT_EMAIL_EXIST', "E-Mail already registered");
+define('_AM_XNEWSLETTER_IMPORT_EMAIL_EXIST', "Email already registered");
define('_AM_XNEWSLETTER_IMPORT_CATSUBSCR_EXIST', "Subscription already exist");
-define('_AM_XNEWSLETTER_IMPORT_NOIMPORT', "-- no import --");
-define('_AM_XNEWSLETTER_IMPORT_EXEC', "Import E-Mail-Addresses as preselected");
-define('_AM_XNEWSLETTER_IMPORT_RESULT_SKIP', "Import E-Mail-Address %e skipped");
-define('_AM_XNEWSLETTER_IMPORT_RESULT_FAILED', "Import E-Mail-Address %e failed");
+define('_AM_XNEWSLETTER_IMPORT_NOIMPORT', "-- No import --");
+define('_AM_XNEWSLETTER_IMPORT_EXEC', "Import email addresses as preselected");
+define('_AM_XNEWSLETTER_IMPORT_RESULT_SKIP', "Import email addresses %e skipped");
+define('_AM_XNEWSLETTER_IMPORT_RESULT_FAILED', "Import email addresses %e failed");
define('_AM_XNEWSLETTER_IMPORT_RESULT_REG_OK', "Registration successful");
define('_AM_XNEWSLETTER_IMPORT_RESULT_SUBSCR_OK', "Subscription to category successful");
define('_AM_XNEWSLETTER_IMPORT_SKIP_EXISTING', "Skip existing subscriptions");
-define('_AM_XNEWSLETTER_IMPORT_FINISHED', "Processing %p of %t email-addresses successful finished");
+define('_AM_XNEWSLETTER_IMPORT_FINISHED', "Processing %p of %t email addresses successful finished");
define('_AM_XNEWSLETTER_IMPORT_INFO', "Add all users of a group to a newsletter");
define('_AM_XNEWSLETTER_IMPORT_CSV_OPT', "Options for CSV-file");
define('_AM_XNEWSLETTER_IMPORT_CSV_FILE', "CSV-file:");
define('_AM_XNEWSLETTER_IMPORT_CSV_DELIMITER', "Delimiter:");
define('_AM_XNEWSLETTER_IMPORT_CSV_HEADER', "CSV-file with header");
-define('_AM_XNEWSLETTER_IMPORT_CSV', "One column ( email ) or four columns ( email | sex | firstname | lastname )<br />see sample1col.csv and sample4col.csv in /plugins");
-define('_AM_XNEWSLETTER_IMPORT_XOOPSUSER', "Options for import/syncronisation XoopsUsers");
+define('_AM_XNEWSLETTER_IMPORT_CSV', "One column ( email ) or four columns ( email | sex | first name | last name )<br />see sample1col.csv and sample4col.csv in /plug-ins");
+define('_AM_XNEWSLETTER_IMPORT_XOOPSUSER', "Options to import/synchronise XoopsUsers");
define('_AM_XNEWSLETTER_IMPORT_XOOPSUSER_GROUPS', "Select groups");
define('_AM_XNEWSLETTER_NEWTASK', "Add New task");
define('_AM_XNEWSLETTER_TASKLIST', "List task");
@@ -361,14 +361,14 @@
define('_AM_XNEWSLETTER_TASK_STARTTIME', "Starttime");
define('_AM_XNEWSLETTER_TASK_SUBMITTER', "Submitter");
define('_AM_XNEWSLETTER_TASK_CREATED', "Created");
-define('_AM_XNEWSLETTER_TASK_ERROR_CREATE', "Error creating item in tasklist");
+define('_AM_XNEWSLETTER_TASK_ERROR_CREATE', "Error creating item in task list");
define('_AM_XNEWSLETTER_TASK_NO_DATA', "No tasks waiting");
//Error NoFrameworks
-define('_AM_XNEWSLETTER_NOFRAMEWORKS', "Error: You do not use the Frameworks \"admin module\". Please install this Frameworks");
+define('_AM_XNEWSLETTER_NOFRAMEWORKS', "Error: You don't use the Frameworks \"admin module\". Please install this Frameworks");
define('_AM_XNEWSLETTER_MAINTAINEDBY', "is maintained by the");
define('_AM_XNEWSLETTER_SEND_ERROR_NO_LETTERCONTENT', "No text available for printing");
-define('_AM_XNEWSLETTER_FORMSEARCH_SUBSCR_EXIST', "Search existing subscription of an e-mail-address");
-define('_AM_XNEWSLETTER_SUBSCR_NO_CATSUBSCR', "For this e-mail-address are no subscription to newsletter cats available");
+define('_AM_XNEWSLETTER_FORMSEARCH_SUBSCR_EXIST', "Search existing subscription of an email address");
+define('_AM_XNEWSLETTER_SUBSCR_NO_CATSUBSCR', "For this email address, no subscription to newsletter categories are available");
//version 1.2
define('_AM_XNEWSLETTER_IMPORT_ERROR_NO_PLUGIN', "Error: required file 'plugins/%p.php' not found!");
define('_AM_XNEWSLETTER_IMPORT_ERROR_NO_FUNCTION', "Error: required function 'xnewsletter_plugin_getdata_%f' doesn't exist!");
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/help/help.html
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/help/help.html 2013-10-20 12:27:39 UTC (rev 12185)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/help/help.html 2013-10-20 14:22:43 UTC (rev 12186)
@@ -43,10 +43,10 @@
- Detailed handling of permissions for subscription procedures<br />
- Newsletter are based on templates<br />
- Detailed handling of permissions for groups and newsletter (subscribe, write, send)<br />
- - Send: send test mail, resend to all subscribers or only to subscrbers, where sending failed<br />
+ - Send: send test mail, resend to all subscribers or only to subscribers, where sending failed<br />
- Sending newsletters to unlimited number of recipients or in packages with certain number of recipients by using cronjob<br />
- - Bounced mail handler for handling bounced mails in case of invalid e-mail-addresses<br />
- - Optionally syncronisation with mailinglists (e.g. majordomo)<br />
+ - Bounced email handler for handling Bounced emails in case of invalid e-mail-addresses<br />
+ - Optionally synchronisation with mailing lists (e.g. majordomo)<br />
- Maintenace function included<br />
- Creating protocol for the important steps<br />
<br />
@@ -66,17 +66,17 @@
<p class="even">The module is based on PHPMailer and PHPMailer-BMH
<br /><br /></p>
- <h5 class="odd">(Un)subscriptions to newsletters</h5>
+ <h5 class="odd">(Un) subscriptions to newsletters</h5>
<p class="even">
- You can define for each newsletter and for each group, whether for (un)subscritpion or change a confirmation email with aktivation key is necessary or not (use double-optin).<br/>
+ You can define for each newsletter and for each group, whether for (un) subscritpion or change a confirmation email with activation key is necessary or not (use double-option).<br/>
<br /><br /></p>
<h5 class="odd">Accounts</h5>
<p class="even">
- You can use one ore more email-account; sending with php mail, php sendmail, smtp is possible.<br/>
+ You can use one or more email-account; sending with php mail, php sendmail, smtp is possible.<br/>
There is a feature for testing pop3 and imap accounts.<br/>
<br />
- Pay attention: functions like testing account, sending mails, start bounced mail handler,... work not with local server (you get white page without any error).<br/>
+ Pay attention: functions like testing account, sending emails, start Bounced email handler,... work not with local server (you get white page without any error).<br/>
<br /><br /></p>
<h5 class="odd">Newsletter categories</h5>
@@ -87,12 +87,12 @@
<h5 class="odd">Create a newsletter</h5>
<p class="even">
- The newsletter can be created with each texteditorm which is installed in current xoops core (e.g. TinyMCE). <br/>
+ The newsletter can be created with each text editor which is installed in current xoops core (e.g. TinyMCE). <br/>
For each newsletter you can use different templates (see also 'Newsletter templates').<br/>
You can define one or more newsletter categories for your newsletter.<br/>
- You can add 5 files maximun as attachment to each newsletter.<br/><br/>
+ You can add 5 files maximum as attachment to each newsletter.<br/><br/>
Optionally you can also copy an older newsletter and edit or send it as a new one.<br/><br/>
- The type of texteditor, allowes mime-types and size of mail attachments can be set in module preferences.<br/>
+ The type of text editor, allows mime-types and size of mail attachments can be set in module preferences.<br/>
<br /><br /></p>
<h5 class="odd">Newsletter templates</h5>
@@ -111,11 +111,11 @@
If one or more send failed, you can see it in the protocol.<br/>
You can restart sending procedure. You can send it again to all subscribers or send it only to the subscribers, where sending procedure failed).<br/>
<br />
- You can send all emails immediatly or limit emails send in one package.<br/>
- The number of emails and the minutes till next sending can be defined in module preferences (e.g. 200 emails all 60 minutes).<br/>
- The first package will be sent immediatly. To start the next sending procedure you need an external cronjob, which is calling "../modules/xNewsletter/cron.php". Xoops can not do this with current version (2.5.5).<br/>
+ You can send all emails immediately or limit emails send in one package.<br/>
+ The number of emails and the minutes untill next sending can be defined in module preferences (e.g. 200 emails all 60 minutes).<br/>
+ The first package will be sent immediately. To start the next sending procedure you need an external cronjob, which is calling "../modules/xNewsletter/cron.php". Xoops cannot do this with current version (2.5.5).<br/>
<br/>
- Pay attention: functions like testing account, sending mails, start bounced mail handler,... work not with local server (you get white page).<br/>
+ Pay attention: functions like testing account, sending emails, start Bounced email handler,... work not with local server (you get white page).<br/>
<br /><br /></p>
<h5 class="odd">Task list</h5>
@@ -125,49 +125,49 @@
Normally the tab "Task list" is hidden, if this option is disabled.<br/>
<br /><br /></p>
- <h5 class="odd">Handle mailinglists</h5>
+ <h5 class="odd">Handle mailing lists</h5>
<p class="even">
- If you have an existing mailinglist, you can syncronize the (un)subscriptions of one newsletter category with one mailing list.<br/>
- I use majordomo beside this newsletter module, because then I can also send an email form my email-client to the newsletter recipients.<br/>
- One of the disadvantages of mailinglists is, that, if one person is registered in two or more mailinglists and you send a one newsletter to all mailinglists, this person gets the same newsletter more than one time. With xNewsletter he gets only one newsletter.<br />
+ If you have an existing mailing list, you can synchronize the (un) subscriptions of one newsletter category with one mailing list.<br/>
+ I use majordomo beside this newsletter module because then I can also send an email from my email-client to the newsletter recipients.<br/>
+ One of the disadvantages of mailing lists is, that, if one person is registered in two or more mailing lists and you send a one newsletter to all mailing lists, this person gets the same newsletter more than one time. With xNewsletter he gets only one newsletter.<br />
<br />
- <br />Normally the tab "Mailinglist" is hidden, if this option is disabled.<br />
+ <br />Normally the tab "Mailing list" is hidden, if this option is disabled.<br />
<br />
- <b>xNewsletter can not create mailing lists</b>.
+ <b>xNewsletter cannot create mailing lists</b>.
<br /><br /></p>
- <h5 class="odd">Bounced mail handler (BMH)</h5>
+ <h5 class="odd">Bounced email handler (BMH)</h5>
<p class="even">
- If you send newsletters, there will always be some mails not delivered to recipient (bounced mail), because email is no more valid, mailbox is full, and so on.<br/>
- To handle this event and to react on this you can use BMH.<br/>
- You can acitvate BMH for each account.<br/>
- Mails, which are detected as bounced mails by BMH, can be deleted or moved in a special folder, you have to define.<br/>
- Possible actions for bounced mails:<br/>
+ If you send newsletters, there will always be some emails not delivered to recipient (Bounced email), because email is no more valid, mailbox is full, and so on.<br/>
+ To handle this event and to react on this, you can use BMH.<br/>
+ You can activate BMH for each account.<br/>
+ Mails, which are detected as Bounced emails by BMH, can be deleted or moved in a special folder, you have to define.<br/>
+ Possible actions for Bounced emails:<br/>
-- no action (only store)<br/>
- -- quit temporary the subsriptions of this email-address<br/>
- -- delete the subsriptions of this email-address<br/>
+ -- quit temporary the subscriptions of this email-address<br/>
+ -- delete the subscriptions of this email-address<br/>
<br/>
<br />
- <h6 class="odd">Types of bounced mails</h6>
+ <h6 class="odd">Types of Bounced emails</h6>
<u>bounce type hard:</u>
This means that there is a permanent error when sending a mail, e.g. unknown recipient, unknown domain, and so on.<br/>
- This mails will be deleted after detection, so it is recommended to use the movehard-option (the mail will be only moved in this folder, you can check this mail later, if you want).<br/>
+ This mails will be deleted after detection, so it is recommended using the move hard option (the email will be only moved in this folder, you can check this mail later, if you want).<br/>
<br />
<u>bounce type soft:</u><br/>
This means that there is a temporary problem with sending a mail, e.g. mailbox full, server not available, and so on.<br/>
- This mails will not be deleted after detection, but it is recommended to use the movesoft-option in order to keep your basic inbox clean.<br/>
+ This mails will not be deleted after detection, but it is recommended using the move soft option in order to keep your basic in box clean.<br/>
<br />
- Pay attention: functions like testing account, sending mails, start bounced mail handler,... work not with local server (you get white page).<br/>
+ Pay attention: functions like testing account, sending emails, start Bounced email handler,... work not with local server (you get white page).<br/>
<br /><br /></p>
<h5 class="odd">Maintenance</h5>
<p class="even">
- This module have a maintain function, which can repair several faults in the data.<br />
+ This module has a maintain function, which can repair several faults in the data.<br />
<br /><br /></p>
<h5 class="odd">Import</h5>
<p class="even">
- You can import data with various plugins:
+ You can import data with various plug-ins:
<ul>
<li>csv</li>
<li>module rmbulletin</li>
@@ -177,25 +177,25 @@
<li>module subscribers</li>
<li>users from xoops users</li>
<ul>
- The importtool works in this way:<br/>
+ The import tool works in this way:<br/>
- Adding email to the list of subscribers<br/>
- Subscribe this email to one newsletter cat<br/>
- Before you run import tool, therefore please create first minimum one newsletter cat, otherwise the email cannot be subscribed to a cat and the import fails.<br/>
+ Before you run import tool therefore, please create first minimum one newsletter cat, otherwise the email cannot be subscribed to a cat and the import fails.<br/>
You have the possibility<br/>
- - to import the E-Mail-Addresses without any check (recommended for big import datasets) or<br/>
+ - to import the E-Mail-Addresses without any check (recommended for big import data sets) or<br/>
- after reading data you can decide for each email<br/>
- -- whether you want make a subscription or not<br/>
+ -- whether you want to make a subscription or not<br/>
-- to which newsletter you want to make the subscription<br/>
If an email is already registered, import of this email should be skipped (default action, do not touch existing registrations).
<br />
Sample files (sample1col.csv, sample4col.csv) for csv-import you can find in ../xNewsletter/plugins/
<br /><br />
- <b>Attention:</b>In case of registrations/subscription with this import tool there will not be sent an e-mail-notification to the e-mail-owner.<br />
+ <b>Attention:</b>In case of registrations/subscription with this import tool there will not be sent an email notification to the email owner.<br />
<br /><br />
<b>Importation of big email lists:</b><br />
To avoid cache overflow during importation, there are two limits:<br />
- - first limit: only 100000 lines (e.g. of a csv-file) can be stored in temporary importtable<br />
- - second limit: you can finally import data from temporary importtable in packages of max. 25000<br />
+ - first limit: only 100000 lines (e.g. of a csv-file) can be stored in temporary import table<br />
+ - second limit: you can finally import data from temporary import table in packages of max. 25000<br />
<br />
For import of more than 100k emails following procedure can be done:<br />
- run first import email 1 to 100000
@@ -203,9 +203,9 @@
- run second import emails 100001 to 200000 (select option "skip existing subscriptions")
- import finally in packages of 25k
and so on.<br />
- If filesize is not too big for upload, you can repeat as often you want.<br />
+ If file size is not too big to upload, you can repeat as often you want.<br />
<br /><br />
- If you get somewhere a white page, it is no problem, because if option "skip existing subscriptions" is selected the import procedure restart at the first not imported email-address.<br />
+ If you get somewhere a white page, it is no problem because if option "skip existing subscriptions" is selected the import procedure restart at the first not imported email-address.<br />
Reduce number of importing emails or package size and try again.<br />
<br /><br /></p>
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php 2013-10-20 12:27:39 UTC (rev 12185)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php 2013-10-20 14:22:43 UTC (rev 12186)
@@ -28,15 +28,15 @@
// Main
define('_MA_XNEWSLETTER_INDEX', "Home");
define('_MA_XNEWSLETTER_TITLE', "xNewsletter");
-define('_MA_XNEWSLETTER_DESC', "newsletter module for xoops");
+define('_MA_XNEWSLETTER_DESC', "Newsletter module for xoops");
define('_MA_XNEWSLETTER_WELCOME', "<h2>Welcome in our newsletter system</h2>We hope, we can keep you up to date with our newsletters. Feel free to subscribe to one or more of our newsletters. If you do not want a newsletter any more, than you can easily unsubscribe here. You also can unsubscribe in a simple way via a link in each of our newsletters.");
define('_MA_XNEWSLETTER_ACCOUNTS', "Accounts");
-define('_MA_XNEWSLETTER_CAT', "Cat");
-define('_MA_XNEWSLETTER_SUBSCR', "Subscr");
-define('_MA_XNEWSLETTER_CATSUBSCR', "Catsubscr");
+define('_MA_XNEWSLETTER_CAT', "Category");
+define('_MA_XNEWSLETTER_SUBSCR', "Subscribers");
+define('_MA_XNEWSLETTER_CATSUBSCR', "Subscriber Newsletter category");
define('_MA_XNEWSLETTER_LETTER', "Letter");
define('_MA_XNEWSLETTER_PROTOCOL', "Protocol");
-define('_MA_XNEWSLETTER_BMH', "Bounced mail handler");
+define('_MA_XNEWSLETTER_BMH', "Bounced email handler");
define('_MA_XNEWSLETTER_ADMIN', "Admin");
define('_MA_XNEWSLETTER_LETTER_CATS', "Sent with newsletter");
define('_MA_XNEWSLETTER_SUBSCRIPTION_SEARCH', "Search for subscriptions");
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php 2013-10-20 12:27:39 UTC (rev 12185)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php 2013-10-20 14:22:43 UTC (rev 12186)
@@ -38,7 +38,7 @@
define('_MI_XNEWSLETTER_ADMENU7', "Attachments");
define('_MI_XNEWSLETTER_ADMENU8', "Protocols");
define('_MI_XNEWSLETTER_ADMENU9', "Mailinglists");
-define('_MI_XNEWSLETTER_ADMENU10', "Bounced mail handler");
+define('_MI_XNEWSLETTER_ADMENU10', "Bounced email handler");
define('_MI_XNEWSLETTER_ADMENU11', "Maintenance");
define('_MI_XNEWSLETTER_ADMENU12', "Import");
define('_MI_XNEWSLETTER_ADMENU13', "Task list");
|
|
From: <ce...@us...> - 2013-10-20 12:27:42
|
Revision: 12185
http://sourceforge.net/p/xoops/svn/12185
Author: cesag
Date: 2013-10-20 12:27:39 +0000 (Sun, 20 Oct 2013)
Log Message:
-----------
Standardization of the English language files and some corrections (cesag).
Modified Paths:
--------------
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/blocks.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/activate.tpl
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/delete.tpl
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/info_change.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/update.tpl
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php 2013-10-17 23:40:19 UTC (rev 12184)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php 2013-10-20 12:27:39 UTC (rev 12185)
@@ -1,409 +1,375 @@
-<?php
-/**
- * ****************************************************************************
- * XNEWSLETTER - MODULE FOR XOOPS
- * Copyright (c) 2007 - 2012
- * Goffy ( wedega.com )
- *
- * 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 Goffy ( wedega.com )
- * @license GPL 2.0
- * @package xNewsletter
- * @author Goffy ( web...@we... )
- *
- * Version : 1 Mon 2012/11/05 14:31:32 : Exp $
- * ****************************************************************************
- */
-
-//General
-define("_AM_XNEWSLETTER_FORMOK","Registered successfull");
-define("_AM_XNEWSLETTER_FORMDELOK","Deleted successfull");
-define("_AM_XNEWSLETTER_FORMDELNOTOK","Error while deleting");
-define("_AM_XNEWSLETTER_FORMSUREDEL", "Are you sure you want to delete: <span class='bold red'>%s</span>");
-define("_AM_XNEWSLETTER_FORMSUREDEL_LIST", "Are you sure you want to delete all protocol items of: <span class='bold red'>%s</span>");
-define("_AM_XNEWSLETTER_FORMSURERENEW", "Are you sure you want renew: <span class='bold red'>%s</span>");
-define("_AM_XNEWSLETTER_FORMUPLOAD","Upload");
-define("_AM_XNEWSLETTER_FORMIMAGE_PATH","File presents in %s");
-define("_AM_XNEWSLETTER_FORMACTION","Action");
-
-define("_AM_XNEWSLETTER_ERROR_NO_VALID_ID","Error: no valid id!");
-define("_AM_XNEWSLETTER_OK","Succesful");
-define("_AM_XNEWSLETTER_FAILED","failed");
-define("_AM_XNEWSLETTER_SAVE","Save");
-define("_AM_XNEWSLETTER_DETAILS","Show details");
-define("_AM_XNEWSLETTER_SEARCH","Search");
-define("_AM_XNEWSLETTER_SEARCH_EQUAL","=");
-define("_AM_XNEWSLETTER_SEARCH_CONTAINS","contains");
-
-define("_AM_ACCOUNTS_TYPE_PHPMAIL","php mail()");
-define("_AM_ACCOUNTS_TYPE_PHPSENDMAIL","php sendmail()");
-define("_AM_ACCOUNTS_TYPE_POP3","pop before smtp");
-define("_AM_ACCOUNTS_TYPE_SMTP","smtp");
-define("_AM_ACCOUNTS_TYPE_GMAIL","gmail");
-
-define("_AM_ACCOUNTS_TYPE_NOTREQUIRED","Not required");
-define("_AM_ACCOUNTS_TYPE_NAME","My account name");
-define("_AM_ACCOUNTS_TYPE_YOURNAME","John Doe");
-define("_AM_ACCOUNTS_TYPE_YOUREMAIL","na...@yo...");
-define("_AM_ACCOUNTS_TYPE_USERNAME","username");
-define("_AM_ACCOUNTS_TYPE_PWD","password");
-define("_AM_ACCOUNTS_TYPE_POP3_SERVER_IN","pop3.yourdomain.com");
-define("_AM_ACCOUNTS_TYPE_POP3_PORT_IN","110");
-define("_AM_ACCOUNTS_TYPE_POP3_SERVER_OUT","mail.yourdomain.com");
-define("_AM_ACCOUNTS_TYPE_POP3_PORT_OUT","25");
-define("_AM_ACCOUNTS_TYPE_SMTP_SERVER_IN","imap.yourdomain.com");
-define("_AM_ACCOUNTS_TYPE_SMTP_PORT_IN","143");
-define("_AM_ACCOUNTS_TYPE_SMTP_SERVER_OUT","mail.yourdomain.com");
-define("_AM_ACCOUNTS_TYPE_SMTP_PORT_OUT","25");
-define("_AM_ACCOUNTS_TYPE_GMAIL_USERNAME","you...@gm...");
-define("_AM_ACCOUNTS_TYPE_GMAIL_SERVER_IN","imap.gmail.com");
-define("_AM_ACCOUNTS_TYPE_GMAIL_PORT_IN","993");
-define("_AM_ACCOUNTS_TYPE_SECURETYPE_IN","tls");
-define("_AM_ACCOUNTS_TYPE_GMAIL_SERVER_OUT","smtp.gmail.com");
-define("_AM_ACCOUNTS_TYPE_GMAIL_PORT_OUT","465");
-define("_AM_ACCOUNTS_TYPE_SECURETYPE_OUT","ssl");
-
-define("_AM_ACCOUNTS_TYPE_CHECK","Check the settings");
-
-define("_AM_XNEWSLETTER_LETTER_ACTION","Action after saving");
-define("_AM_XNEWSLETTER_LETTER_ACTION_SAVED","Saved");
-define("_AM_XNEWSLETTER_LETTER_ACTION_NO","No action");
-define("_AM_XNEWSLETTER_LETTER_ACTION_COPYNEW","Copy and new");
-define("_AM_XNEWSLETTER_LETTER_ACTION_PREVIEW","Show preview");
-define("_AM_XNEWSLETTER_LETTER_ACTION_SEND","Send newsletter to all subscribers");
-define("_AM_XNEWSLETTER_LETTER_ACTION_RESEND","Resend newsletter to subscribers, where sending failed");
-define("_AM_XNEWSLETTER_LETTER_ACTION_SENDTEST","Send newsletter for testing");
-define("_AM_XNEWSLETTER_LETTER_EMAIL_TEST","E-mail for testing newsletter");
-define("_AM_XNEWSLETTER_LETTER_EMAIL_ALTBODY","To view the message, please use an HTML compatible email viewer!");
-define("_AM_XNEWSLETTER_LETTER_ERROR_INVALID_ATT_ID","Error deleting attachment (invalid attachment id)");
-
-define("_AM_XNEWSLETTER_SEND_SUCCESS","Newsletter sent");
-define("_AM_XNEWSLETTER_SEND_SUCCESS_TEST","Newsletter sent for test");
-define("_AM_XNEWSLETTER_SEND_SUCCESS_NUMBER","Sending %t newsletter(s) successfully");
-define("_AM_XNEWSLETTER_SEND_SUCCESS_ML","Handle mailinglist successfully");
-define("_AM_XNEWSLETTER_SEND_SUCCESS_ML_DETAIL","Sending '%a' to mailinglist successfully");
-define("_AM_XNEWSLETTER_SEND_ERROR_NUMBER","Error sending newsletter: %e of %t newsletters not sent");
-define("_AM_XNEWSLETTER_SEND_ERROR_PHPMAILER","Error phpmailer: ");
-define("_AM_XNEWSLETTER_SEND_ERROR_NO_EMAIL","Error: No e-mail-address available");
-define("_AM_XNEWSLETTER_SEND_ERROR_NO_LETTERID","Error: No valid newsletter selected");
-define("_AM_XNEWSLETTER_SEND_ERROR_INALID_TEMPLATE_PATH","Error: template path '%p' not found");
-define("_AM_XNEWSLETTER_SEND_SURE_SENT","This newsletter was already sent to all subscribers.<br/>Do you really want to send this newsletter again to all subscribers?");
-define("_AM_XNEWSLETTER_SEND_ERROR_NO_SUBSCR","Error: No valid subscriptions for the selected newsletter(s) found");
-
-//Index
-define("_AM_XNEWSLETTER_LETTER","Newsletter Statistics");
-define("_AM_XNEWSLETTER_THEREARE_ACCOUNTS","There are <span class='bold'>%s</span> Accounts in the Database");
-define("_AM_XNEWSLETTER_THEREARE_CAT","There are <span class='bold'>%s</span> Categories in the Database");
-define("_AM_XNEWSLETTER_THEREARE_SUBSCR","There are <span class='bold'>%s</span> Subscribers in the Database");
-define("_AM_XNEWSLETTER_THEREARE_CATSUBSCR","There are <span class='bold'>%s</span> Categories-Subscribers in the Database");
-define("_AM_XNEWSLETTER_THEREARE_LETTER","There are <span class='bold'>%s</span> Newsletter in the Database");
-define("_AM_XNEWSLETTER_THEREARE_PROTOCOL","There are <span class='bold'>%s</span> Protocol in the Database");
-define("_AM_XNEWSLETTER_THEREARE_ATTACHMENT","There are <span class='bold'>%s</span> Attachment in the Database");
-define("_AM_XNEWSLETTER_THEREARE_MAILINGLIST","There are <span class='bold'>%s</span> Mailinglist in the Database");
-define("_AM_XNEWSLETTER_THEREARE_BMH","There are <span class='bold'>%s</span> Bounce Mails in the Database");
-define("_AM_XNEWSLETTER_THEREARE_TASK","There are <span class='bold'>%s</span> Task in the Database");
-
-
-//Buttons
-define("_AM_XNEWSLETTER_NEWACCOUNTS","Add New Account");
-define("_AM_XNEWSLETTER_ACCOUNTSLIST","List Accounts");
-define("_AM_XNEWSLETTER_ACCOUNTSWAIT","Pending Accounts");
-define("_AM_XNEWSLETTER_NEWCAT","Add New Category");
-define("_AM_XNEWSLETTER_CATLIST","List Categories");
-define("_AM_XNEWSLETTER_CATWAIT","Pending Categories");
-define("_AM_XNEWSLETTER_NEWSUBSCR","Add New Subscriber");
-define("_AM_XNEWSLETTER_SUBSCRLIST","List Subscribers");
-define("_AM_XNEWSLETTER_SUBSCRWAIT","Pending Subscribers");
-define("_AM_XNEWSLETTER_NEWCATSUBSCR","Add New Categories-Subscribers");
-define("_AM_XNEWSLETTER_CATSUBSCRLIST","List Categories-Subscribers");
-define("_AM_XNEWSLETTER_CATSUBSCRWAIT","Pending Categories-Subscribers");
-define("_AM_XNEWSLETTER_NEWLETTER","Add New Newsletter");
-define("_AM_XNEWSLETTER_LETTERLIST","List Newsletters");
-define("_AM_XNEWSLETTER_LETTERWAIT","Pending Newsletters");
-define("_AM_XNEWSLETTER_LETTER_DELETE_ALL","Delete protocol of this newsletter");
-define("_AM_XNEWSLETTER_NEWPROTOCOL","Add New Protocol");
-define("_AM_XNEWSLETTER_PROTOCOLLIST","List Protocol");
-define("_AM_XNEWSLETTER_PROTOCOLWAIT","Pending Protocol");
-define("_AM_XNEWSLETTER_NEWATTACHMENT","Add New Attachment");
-define("_AM_XNEWSLETTER_ATTACHMENTLIST","List Attachment");
-define("_AM_XNEWSLETTER_ATTACHMENTWAIT","Pending Attachment");
-define("_AM_XNEWSLETTER_NEWMAILINGLIST","Add New Mailinglist");
-define("_AM_XNEWSLETTER_MAILINGLISTLIST","List Mailinglist");
-define("_AM_XNEWSLETTER_MAILINGLISTWAIT","Pending Mailinglist");
-define("_AM_XNEWSLETTER_RUNBMH","Run bounced mail handler");
-define("_AM_XNEWSLETTER_BMHLIST","List bounced mail handlers");
-define("_AM_XNEWSLETTER_BMHWAIT","Pending bounced mail handlers");
-
-define("_AM_XNEWSLETTER_ACCOUNTS_ADD","Add an Account");
-define("_AM_XNEWSLETTER_ACCOUNTS_EDIT","Edit an Account");
-define("_AM_XNEWSLETTER_ACCOUNTS_DELETE","Delete an Account");
-define("_AM_XNEWSLETTER_ACCOUNTS_ID","Id");
-define("_AM_XNEWSLETTER_ACCOUNTS_TYPE","Type");
-define("_AM_XNEWSLETTER_ACCOUNTS_NAME","Name");
-define("_AM_XNEWSLETTER_ACCOUNTS_YOURNAME","Your name");
-define("_AM_XNEWSLETTER_ACCOUNTS_YOURMAIL","Your mail");
-define("_AM_XNEWSLETTER_ACCOUNTS_USERNAME","Username");
-define("_AM_XNEWSLETTER_ACCOUNTS_PASSWORD","Password");
-define("_AM_XNEWSLETTER_ACCOUNTS_INCOMING","Incoming");
-define("_AM_XNEWSLETTER_ACCOUNTS_SERVER_IN","Server incoming");
-define("_AM_XNEWSLETTER_ACCOUNTS_PORT_IN","Port in");
-define("_AM_XNEWSLETTER_ACCOUNTS_SECURETYPE_IN","Securetype in");
-define("_AM_XNEWSLETTER_ACCOUNTS_OUTGOING","Outgoing");
-define("_AM_XNEWSLETTER_ACCOUNTS_SERVER_OUT","Server outgoing");
-define("_AM_XNEWSLETTER_ACCOUNTS_PORT_OUT","Port out");
-define("_AM_XNEWSLETTER_ACCOUNTS_SECURETYPE_OUT","Securetype out");
-define("_AM_XNEWSLETTER_ACCOUNTS_DEFAULT","Default account");
-define("_AM_XNEWSLETTER_ACCOUNTS_BOUNCE_INFO","Addtional info for bounced mails handling");
-define("_AM_XNEWSLETTER_ACCOUNTS_USE_BMH","Use bounced mails handling");
-define("_AM_XNEWSLETTER_ACCOUNTS_INBOX","Mailbox to check for bounced mails");
-define("_AM_XNEWSLETTER_ACCOUNTS_HARDBOX","Use this mailbox as 'hardbox'");
-define("_AM_XNEWSLETTER_ACCOUNTS_HARDBOX_DESC","The mailboxname must start with 'INBOX.'. You can select a standard folder in your mailbox (e.g. INBOX.Trash) or create your own special folders like 'hard' and 'soft'. If you type in a new folder name, the folder will be created (this function is not available for gmail-accounts).");
-define("_AM_XNEWSLETTER_ACCOUNTS_MOVEHARD","Move bounced mail in 'hardbox'");
-define("_AM_XNEWSLETTER_ACCOUNTS_SOFTBOX","Use this mailbox as 'softbox'");
-define("_AM_XNEWSLETTER_ACCOUNTS_MOVESOFT","Move bounced mail in 'softbox'");
-define("_AM_XNEWSLETTER_ACCOUNTS_SUBMITTER","Submitter");
-define("_AM_XNEWSLETTER_ACCOUNTS_CREATED","Created");
-define("_AM_XNEWSLETTER_ACCOUNTS_ERROR_OPEN_MAILBOX","Error open mailbox! Please check your settings!");
-
-define("_AM_XNEWSLETTER_SAVE_AND_CHECK","Save and check settings");
-define("_AM_XNEWSLETTER_ACCOUNTS_CHECK_OK","succesful ");
-define("_AM_XNEWSLETTER_ACCOUNTS_CHECK_FAILED","failed ");
-define("_AM_XNEWSLETTER_ACCOUNTS_CHECK_SKIPPED","skipped");
-define("_AM_XNEWSLETTER_ACCOUNTS_CHECK","Check result");
-define("_AM_XNEWSLETTER_ACCOUNTS_CHECK_INFO","Additional info");
-define("_AM_XNEWSLETTER_ACCOUNTS_CHECK_OPEN_MAILBOX","Open mailbox ");
-define("_AM_XNEWSLETTER_ACCOUNTS_CHECK_OPEN_FOLDERS","Open folders ");
-define("_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH","Bounced mail handler ");
-define("_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH_INBOX","Mailbox");
-define("_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH_HARDBOX","Hardbox");
-define("_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH_SOFTBOX","Softbox");
-
-define("_AM_XNEWSLETTER_CAT_ADD","Add a category");
-define("_AM_XNEWSLETTER_CAT_EDIT","Edit a categories");
-define("_AM_XNEWSLETTER_CAT_DELETE","Delete a categories");
-define("_AM_XNEWSLETTER_CAT_ID","Id");
-define("_AM_XNEWSLETTER_CAT_NAME","Newsletter name");
-define("_AM_XNEWSLETTER_CAT_INFO","Additional info");
-define("_AM_XNEWSLETTER_CAT_GPERMS_CREATE","Permissions to create");
-define("_AM_XNEWSLETTER_CAT_GPERMS_CREATE_DESC","<br/><span style='font-weight:normal'>- Create new newsletters<br/>- Edit, delete, send of own newsletters</span>");
-define("_AM_XNEWSLETTER_CAT_GPERMS_ADMIN","Permission to admin");
-define("_AM_XNEWSLETTER_CAT_GPERMS_ADMIN_DESC","<br/><span style='font-weight:normal'>Edit, delete, send of all newsletters of this category</span>");
-define("_AM_XNEWSLETTER_CAT_GPERMS_READ","Permissions to read/subscribe");
-define("_AM_XNEWSLETTER_CAT_GPERMS_LIST","Permissions to see list of subscribers");
-define("_AM_XNEWSLETTER_CAT_SUBMITTER","Submitter");
-define("_AM_XNEWSLETTER_CAT_CREATED","Created");
-define("_AM_XNEWSLETTER_CAT_MAILINGLIST","Mailinglist");
-
-define("_AM_XNEWSLETTER_SUBSCR_ADD","Add a Subscriber");
-define("_AM_XNEWSLETTER_SUBSCR_EDIT","Edit a Subscriber");
-define("_AM_XNEWSLETTER_SUBSCR_DELETE","Delete a Subscriber");
-define("_AM_XNEWSLETTER_SUBSCR_ID","Id");
-define("_AM_XNEWSLETTER_SUBSCR_EMAIL","Email");
-define("_AM_XNEWSLETTER_SUBSCR_FIRSTNAME","Firstname");
-define("_AM_XNEWSLETTER_SUBSCR_LASTNAME","Lastname");
-define("_AM_XNEWSLETTER_SUBSCR_UID","Membername");
-define("_AM_XNEWSLETTER_SUBSCR_SEX","Salutation");
-define("_AM_XNEWSLETTER_SUBSCR_SEX_EMPTY","");
-define("_AM_XNEWSLETTER_SUBSCR_SEX_MALE","Mr.");
-define("_AM_XNEWSLETTER_SUBSCR_SEX_FEMALE","Mrs.");
-define("_AM_XNEWSLETTER_SUBSCR_SEX_FAMILY","Family");
-define("_AM_XNEWSLETTER_SUBSCR_SEX_COMP","Company");
-define("_AM_XNEWSLETTER_SUBSCR_SUBMITTER","Submitter");
-define("_AM_XNEWSLETTER_SUBSCR_CREATED","Created");
-define("_AM_XNEWSLETTER_SUBSCR_ACTIVATED","activated?");
-define("_AM_XNEWSLETTER_SUBSCR_SHOW_ALL","Show all");
-
-define("_AM_XNEWSLETTER_CATSUBSCR_ADD","Add a Categories-Subscribers");
-define("_AM_XNEWSLETTER_CATSUBSCR_EDIT","Edit a Categories-Subscribers");
-define("_AM_XNEWSLETTER_CATSUBSCR_DELETE","Delete a Categories-Subscribers");
-define("_AM_XNEWSLETTER_CATSUBSCR_ID","Id");
-define("_AM_XNEWSLETTER_CATSUBSCR_CATID","Cat-Id");
-define("_AM_XNEWSLETTER_CATSUBSCR_SUBSCRID","Subscribers");
-define("_AM_XNEWSLETTER_CATSUBSCR_QUITED","Quited");
-define("_AM_XNEWSLETTER_CATSUBSCR_SUBMITTER","Submitter");
-define("_AM_XNEWSLETTER_CATSUBSCR_CREATED","Created");
-define("_AM_XNEWSLETTER_CATSUBSCR_SUREDELETE","Do you really want to delete<br />'%s'<br />from<br />'%c' ?");
-define("_AM_XNEWSLETTER_CATSUBSCR_QUIT_NONE","None");
-define("_AM_XNEWSLETTER_CATSUBSCR_QUIT_NOW","Quit now");
-define("_AM_XNEWSLETTER_CATSUBSCR_QUIT_REMOVE","Remove quit date");
-
-define("_AM_XNEWSLETTER_LETTER_ADD","Add a newsletter");
-define("_AM_XNEWSLETTER_LETTER_EDIT","Edit a newsletter");
-define("_AM_XNEWSLETTER_LETTER_DELETE","Delete a newsletter");
-define("_AM_XNEWSLETTER_LETTER_ID","Id");
-define("_AM_XNEWSLETTER_LETTER_TITLE","Title");
-define("_AM_XNEWSLETTER_LETTER_CONTENT","Content");
-define("_AM_XNEWSLETTER_LETTER_TEMPLATE","Template");
-define("_AM_XNEWSLETTER_LETTER_CATS","Categories");
-define("_AM_XNEWSLETTER_LETTER_ATTACHMENT","Attachments");
-define("_AM_XNEWSLETTER_LETTER_STATUS","Status");
-define("_AM_XNEWSLETTER_LETTER_SUBMITTER","Submitter");
-define("_AM_XNEWSLETTER_LETTER_CREATED","Created");
-define("_AM_XNEWSLETTER_LETTER_ACCOUNTS_AVAIL","Available accounts");
-define("_AM_XNEWSLETTER_LETTER_ACCOUNT","Account");
-define("_AM_XNEWSLETTER_LETTER_MAILINGLIST","Use mailing list");
-define("_AM_XNEWSLETTER_LETTER_MAILINGLIST_NO","None");
-
-define("_AM_XNEWSLETTER_ATTACHMENT_ADD","Add an attachment");
-define("_AM_XNEWSLETTER_ATTACHMENT_EDIT","Edit an attachment");
-define("_AM_XNEWSLETTER_ATTACHMENT_DELETE","Delete an attachment");
-define("_AM_XNEWSLETTER_ATTACHMENT_ID","Id");
-define("_AM_XNEWSLETTER_ATTACHMENT_LETTER_ID","Letter-Id");
-define("_AM_XNEWSLETTER_ATTACHMENT_NAME","Name");
-define("_AM_XNEWSLETTER_ATTACHMENT_TYPE","File type");
-define("_AM_XNEWSLETTER_ATTACHMENT_SUBMITTER","Submitter");
-define("_AM_XNEWSLETTER_ATTACHMENT_CREATED","Created");
-
-define("_AM_XNEWSLETTER_PROTOCOL_ADD","Add a Protocol");
-define("_AM_XNEWSLETTER_PROTOCOL_EDIT","Edit a Protocol");
-define("_AM_XNEWSLETTER_PROTOCOL_DELETE","Delete a Protocol");
-define("_AM_XNEWSLETTER_PROTOCOL_ID","Id");
-define("_AM_XNEWSLETTER_PROTOCOL_LETTER_ID","Newsletter-Id");
-define("_AM_XNEWSLETTER_PROTOCOL_SUBSCRIBER_ID","Subscriber-Id");
-define("_AM_XNEWSLETTER_PROTOCOL_STATUS","Status");
-define("_AM_XNEWSLETTER_PROTOCOL_SUCCESS","Success");
-define("_AM_XNEWSLETTER_PROTOCOL_SUBMITTER","Submitter");
-define("_AM_XNEWSLETTER_PROTOCOL_CREATED","Created");
-define("_AM_XNEWSLETTER_PROTOCOL_LAST_STATUS","Last status");
-define("_AM_XNEWSLETTER_PROTOCOL_MISC","Misc protocol items");
-define("_AM_XNEWSLETTER_PROTOCOL_NO_SUBSCREMAIL","No email of recipient found");
-
-define("_AM_XNEWSLETTER_MAILINGLIST_ADD","Add a Mailinglist");
-define("_AM_XNEWSLETTER_MAILINGLIST_EDIT","Edit a Mailinglist");
-define("_AM_XNEWSLETTER_MAILINGLIST_DELETE","Delete a Mailinglist");
-define("_AM_XNEWSLETTER_MAILINGLIST_ID","Id");
-define("_AM_XNEWSLETTER_MAILINGLIST_NAME","Name");
-define("_AM_XNEWSLETTER_MAILINGLIST_EMAIL","Email");
-define("_AM_XNEWSLETTER_MAILINGLIST_EMAIL_DESC","Email, where subscription code should be send to");
-define("_AM_XNEWSLETTER_MAILINGLIST_LISTNAME","Listname");
-define("_AM_XNEWSLETTER_MAILINGLIST_SUBSCRIBE","Subscribe code");
-define("_AM_XNEWSLETTER_MAILINGLIST_SUBSCRIBE_DESC","{email} will be replaced by the email of the subscriber");
-define("_AM_XNEWSLETTER_MAILINGLIST_UNSUBSCRIBE","Unsubscribe code");
-define("_AM_XNEWSLETTER_MAILINGLIST_SUBMITTER","Submitter");
-define("_AM_XNEWSLETTER_MAILINGLIST_CREATED","Created");
-
-define("_AM_XNEWSLETTER_BOUNCETYPE","Bouncetype");
-define("_AM_XNEWSLETTER_BMH_EDIT","Edit a bounced mail handler");
-define("_AM_XNEWSLETTER_BMH_DELETE","Delete a bounced mail handler");
-define("_AM_XNEWSLETTER_BMH_ID","Id");
-define("_AM_XNEWSLETTER_BMH_RULE_NO","Rule no");
-define("_AM_XNEWSLETTER_BMH_RULE_CAT","Rule cat");
-define("_AM_XNEWSLETTER_BMH_BOUNCETYPE","Bouncetype");
-define("_AM_XNEWSLETTER_BMH_REMOVE","Removed");
-define("_AM_XNEWSLETTER_BMH_EMAIL","Email");
-define("_AM_XNEWSLETTER_BMH_SUBJECT","Subject");
-define("_AM_XNEWSLETTER_BMH_MEASURE","Measure");
-define("_AM_XNEWSLETTER_BMH_SUBMITTER","Submitter");
-define("_AM_XNEWSLETTER_BMH_CREATED","Created");
-
-define("_AM_XNEWSLETTER_BMH_MEASURE_PENDING","Pending");
-define("_AM_XNEWSLETTER_BMH_MEASURE_NOTHING","Do nothing");
-define("_AM_XNEWSLETTER_BMH_MEASURE_QUIT","Quit this subscriber temporary");
-define("_AM_XNEWSLETTER_BMH_MEASURE_DELETE","Delete this subscriber");
-define("_AM_XNEWSLETTER_BMH_MEASURE_QUITED","Subscriber temporary quited");
-define("_AM_XNEWSLETTER_BMH_MEASURE_DELETED","Subscriber deleted");
-define("_AM_XNEWSLETTER_BMH_MEASURE_ALREADY_DELETED","Subscriber already deleted! Action not possible!");
-define("_AM_XNEWSLETTER_BMH_MEASURE_DELETE_SURE","Do you really want to delete this registration with all subscriptions?<br /><br />Reactivating by the subscriber will not be posssible later!<br/><br />");
-
-define("_AM_XNEWSLETTER_BMH_ERROR_NO_SUBSCRID","There is nor existing registration for the this email!");
-define("_AM_XNEWSLETTER_BMH_ERROR_NO_ACTIVE","Bounced mail handler isn't activated in any account");
-define("_AM_XNEWSLETTER_BMH_RSLT", "Result of checking mailbox %b<br/>Messages read: %r<br/>Action taken: %a<br/>No action taken: %n<br/>Moved: %m<br/>Deleted: %d<br/><br/><br/>");
-define("_AM_XNEWSLETTER_BMH_SUCCESSFUL","Bounced mail handler successfully finished");
-
-define("_AM_XNEWSLETTER_BMH_MEASURE_ALL","Show all");
-define("_AM_XNEWSLETTER_BMH_MEASURE_SHOW_NONE","No bmh items for measure '%s' available");
-
-define("_AM_XNEWSLETTER_MAINTENANCE_CAT","Category");
-define("_AM_XNEWSLETTER_MAINTENANCE_DESCR","Description");
-define("_AM_XNEWSLETTER_MAINTENANCE_PARAM","Params");
-
-define("_AM_XNEWSLETTER_MAINTENANCE_ERROR","Error while running maintenance");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETEDATE","Delete all registrations without confirmation, where registration was before this date.<br />Attention: there is noe undo possible! Please check date before execution!");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETEUSER","Should these <b>%s</b> unconfirmed registrations with date before %s really deleted.<br />Attention: there is noe undo possible!");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETEPROTOCOL","Delete all protocols and reset tables");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETEPROTOK","Table protocol maintained.");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETENOTHING","No action necessary.");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETEUSEROK","%s Users have been deleted");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_SUBCR","Delete subscriptions to newsletter without an existing registration");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_SUBCR_OK","%s subscriptions have been deleted");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_SUBCR_NODATA","No invalid data in table catsubsr found");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML","Compare data from newsletter cats with mailinglists and correct invalid data");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML_OK","%s wrong data in mailinglist have been corrected");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML_NODATA","No invalid data mailinglist found");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_CATNL","Compare data from newsletter cats with newsletters and correct invalid data");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_CATNL_OK","%s wrong data in newsletters have been corrected");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_CATNL_NODATA","No invalid data newsletters found");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETE_IMPORT","Delete table import and reset table");
-define("_AM_XNEWSLETTER_MAINTENANCE_DELETE_IMPORT_OK","Table import maintained.");
-
-define("_AM_XNEWSLETTER_IMPORT_SEARCH","Search available E-Mail-Addresses for import");
-define("_AM_XNEWSLETTER_IMPORT_PRESELECT_CAT","Preselect category");
-define("_AM_XNEWSLETTER_IMPORT_PLUGINS_AVAIL","Available plugins");
-define("_AM_XNEWSLETTER_IMPORT_CONTINUE","Continue");
-define("_AM_XNEWSLETTER_IMPORT_AFTER_READ","Action after reading the data");
-define("_AM_XNEWSLETTER_IMPORT_READ_CHECK","Show data for check");
-define("_AM_XNEWSLETTER_IMPORT_CHECK_LIMIT","Limit E-Mail-Addresses for import");
-define("_AM_XNEWSLETTER_IMPORT_CHECK_LIMIT_PACKAGE","Limit E-Mail-Addresses per processing step");
-define("_AM_XNEWSLETTER_IMPORT_NOLIMIT","No limit");
-define("_AM_XNEWSLETTER_IMPORT_READ_IMPORT","Import data at once without a check");
-define("_AM_XNEWSLETTER_IMPORT_SHOW","Show %s to %l of %n available E-Mail-Addresses");
-define("_AM_XNEWSLETTER_IMPORT_NODATA","No data found");
-define("_AM_XNEWSLETTER_IMPORT_EMAIL_EXIST","E-Mail already registered");
-define("_AM_XNEWSLETTER_IMPORT_CATSUBSCR_EXIST","Subscription already exist");
-define("_AM_XNEWSLETTER_IMPORT_NOIMPORT","-- no import --");
-define("_AM_XNEWSLETTER_IMPORT_EXEC","Import E-Mail-Addresses as preselected");
-define("_AM_XNEWSLETTER_IMPORT_RESULT_SKIP","Import E-Mail-Address %e skipped");
-define("_AM_XNEWSLETTER_IMPORT_RESULT_FAILED","Import E-Mail-Address %e failed");
-define("_AM_XNEWSLETTER_IMPORT_RESULT_REG_OK","Registration successful");
-define("_AM_XNEWSLETTER_IMPORT_RESULT_SUBSCR_OK","Subscription to category successful");
-define("_AM_XNEWSLETTER_IMPORT_SKIP_EXISTING","Skip existing subscriptions");
-define("_AM_XNEWSLETTER_IMPORT_FINISHED","Processing %p of %t email-addresses successful finished");
-
-define("_AM_XNEWSLETTER_IMPORT_CSV_OPT","Options for CSV-file");
-define("_AM_XNEWSLETTER_IMPORT_CSV_FILE","CSV-file:");
-define("_AM_XNEWSLETTER_IMPORT_CSV_DELIMITER","Delimiter:");
-define("_AM_XNEWSLETTER_IMPORT_CSV_HEADER","CSV-file with header");
-
-define("_AM_XNEWSLETTER_IMPORT_XOOPSUSER","Options for import/syncronisation XoopsUsers");
-define("_AM_XNEWSLETTER_IMPORT_XOOPSUSER_GROUPS","Select groups");
-
-define("_AM_XNEWSLETTER_NEWTASK","Add New task");
-define("_AM_XNEWSLETTER_TASKLIST","List task");
-define("_AM_XNEWSLETTER_TASK_ADD","Add a task");
-define("_AM_XNEWSLETTER_TASK_EDIT","Edit a task");
-define("_AM_XNEWSLETTER_TASK_DELETE","Delete a task");
-define("_AM_XNEWSLETTER_TASK_ID","Id");
-define("_AM_XNEWSLETTER_TASK_LETTER_ID","Letter");
-define("_AM_XNEWSLETTER_TASK_SUBSCR_ID","Subscriber");
-define("_AM_XNEWSLETTER_TASK_STATUS","Status");
-define("_AM_XNEWSLETTER_TASK_STARTTIME","Starttime");
-define("_AM_XNEWSLETTER_TASK_SUBMITTER","Submitter");
-define("_AM_XNEWSLETTER_TASK_CREATED","Created");
-define("_AM_XNEWSLETTER_TASK_ERROR_CREATE","Error creating item in tasklist");
-define("_AM_XNEWSLETTER_TASK_NO_DATA","No tasks waiting");
-
-//Error NoFrameworks
-define("_AM_XNEWSLETTER_NOFRAMEWORKS","Error: You do not use the Frameworks \"admin module\". Please install this Frameworks");
-define("_AM_XNEWSLETTER_MAINTAINEDBY", "is maintained by the");
-
-define("_AM_XNEWSLETTER_SEND_ERROR_NO_LETTERCONTENT","No text available for printing");
-define("_AM_XNEWSLETTER_IMPORT_INFO","Add all users of a group to a newsletter");
-define("_AM_XNEWSLETTER_IMPORT_CSV","One column ( email ) or four columns ( email | sex | firstname | lastname)<br />see sample1col.csv and sample4col.csv in /plugins");
-
-define("_AM_XNEWSLETTER_FORMSEARCH_SUBSCR_EXIST","Search existing subscription of an e-mail-address");
-
-define("_AM_XNEWSLETTER_SUBSCR_NO_CATSUBSCR","For this e-mail-address are no subscription to newsletter cats available");
-
-//version 1.2
-define("_AM_XNEWSLETTER_IMPORT_ERROR_NO_PLUGIN","Error: required file 'plugins/%p.php' not found!");
-define("_AM_XNEWSLETTER_IMPORT_ERROR_NO_FUNCTION","Error: required function 'xnewsletter_plugin_getdata_%f' doesn't exist!");
+<?php
+/**
+ * ****************************************************************************
+ * XNEWSLETTER - MODULE FOR XOOPS
+ * Copyright (c) 2007 - 2012
+ * Goffy ( wedega.com )
+ *
+ * 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 Goffy ( wedega.com )
+ * @license GPL 2.0
+ * @package xNewsletter
+ * @author Goffy ( web...@we... )
+ *
+ * Version : 1 Mon 2012/11/05 14:31:32 : Exp $
+ * ****************************************************************************
+ */
+//General
+define('_AM_XNEWSLETTER_FORMOK', "Registered successfully");
+define('_AM_XNEWSLETTER_FORMDELOK', "Deleted successfully");
+define('_AM_XNEWSLETTER_FORMDELNOTOK', "Error while deleting");
+define('_AM_XNEWSLETTER_FORMSUREDEL', "Are you sure you want to delete: <span class='bold red'>%s</span>");
+define('_AM_XNEWSLETTER_FORMSUREDEL_LIST', "Are you sure you want to delete all protocol items of: <span class='bold red'>%s</span>");
+define('_AM_XNEWSLETTER_FORMSURERENEW', "Are you sure you want renew: <span class='bold red'>%s</span>");
+define('_AM_XNEWSLETTER_FORMUPLOAD', "Upload");
+define('_AM_XNEWSLETTER_FORMIMAGE_PATH', "File presents in %s");
+define('_AM_XNEWSLETTER_FORMACTION', "Action");
+define('_AM_XNEWSLETTER_ERROR_NO_VALID_ID', "Error: no valid id!");
+define('_AM_XNEWSLETTER_OK', "Succesful");
+define('_AM_XNEWSLETTER_FAILED', "failed");
+define('_AM_XNEWSLETTER_SAVE', "Save");
+define('_AM_XNEWSLETTER_DETAILS', "Show details");
+define('_AM_XNEWSLETTER_SEARCH', "Search");
+define('_AM_XNEWSLETTER_SEARCH_EQUAL', "=");
+define('_AM_XNEWSLETTER_SEARCH_CONTAINS', "contains");
+define('_AM_ACCOUNTS_TYPE_PHPMAIL', "php mail()");
+define('_AM_ACCOUNTS_TYPE_PHPSENDMAIL', "php sendmail()");
+define('_AM_ACCOUNTS_TYPE_POP3', "pop before smtp");
+define('_AM_ACCOUNTS_TYPE_SMTP', "smtp");
+define('_AM_ACCOUNTS_TYPE_GMAIL', "gmail");
+define('_AM_ACCOUNTS_TYPE_NOTREQUIRED', "Not required");
+define('_AM_ACCOUNTS_TYPE_NAME', "My account name");
+define('_AM_ACCOUNTS_TYPE_YOURNAME', "John Doe");
+define('_AM_ACCOUNTS_TYPE_YOUREMAIL', "na...@yo...");
+define('_AM_ACCOUNTS_TYPE_USERNAME', "username");
+define('_AM_ACCOUNTS_TYPE_PWD', "password");
+define('_AM_ACCOUNTS_TYPE_POP3_SERVER_IN', "pop3.yourdomain.com");
+define('_AM_ACCOUNTS_TYPE_POP3_PORT_IN', "110");
+define('_AM_ACCOUNTS_TYPE_POP3_SERVER_OUT', "mail.yourdomain.com");
+define('_AM_ACCOUNTS_TYPE_POP3_PORT_OUT', "25");
+define('_AM_ACCOUNTS_TYPE_SMTP_SERVER_IN', "imap.yourdomain.com");
+define('_AM_ACCOUNTS_TYPE_SMTP_PORT_IN', "143");
+define('_AM_ACCOUNTS_TYPE_SMTP_SERVER_OUT', "mail.yourdomain.com");
+define('_AM_ACCOUNTS_TYPE_SMTP_PORT_OUT', "25");
+define('_AM_ACCOUNTS_TYPE_GMAIL_USERNAME', "you...@gm...");
+define('_AM_ACCOUNTS_TYPE_GMAIL_SERVER_IN', "imap.gmail.com");
+define('_AM_ACCOUNTS_TYPE_GMAIL_PORT_IN', "993");
+define('_AM_ACCOUNTS_TYPE_SECURETYPE_IN', "tls");
+define('_AM_ACCOUNTS_TYPE_GMAIL_SERVER_OUT', "smtp.gmail.com");
+define('_AM_ACCOUNTS_TYPE_GMAIL_PORT_OUT', "465");
+define('_AM_ACCOUNTS_TYPE_SECURETYPE_OUT', "ssl");
+define('_AM_ACCOUNTS_TYPE_CHECK', "Check the settings");
+define('_AM_XNEWSLETTER_LETTER_ACTION', "Action after saving");
+define('_AM_XNEWSLETTER_LETTER_ACTION_SAVED', "Saved");
+define('_AM_XNEWSLETTER_LETTER_ACTION_NO', "No action");
+define('_AM_XNEWSLETTER_LETTER_ACTION_COPYNEW', "Copy and new");
+define('_AM_XNEWSLETTER_LETTER_ACTION_PREVIEW', "Show preview");
+define('_AM_XNEWSLETTER_LETTER_ACTION_SEND', "Send newsletter to all subscribers");
+define('_AM_XNEWSLETTER_LETTER_ACTION_RESEND', "Resend newsletter to subscribers, where sending failed");
+define('_AM_XNEWSLETTER_LETTER_ACTION_SENDTEST', "Send newsletter for testing");
+define('_AM_XNEWSLETTER_LETTER_EMAIL_TEST', "E-mail for testing newsletter");
+define('_AM_XNEWSLETTER_LETTER_EMAIL_ALTBODY', "To view the message, please use an HTML compatible email viewer!");
+define('_AM_XNEWSLETTER_LETTER_ERROR_INVALID_ATT_ID', "Error deleting attachment (invalid attachment id)");
+define('_AM_XNEWSLETTER_SEND_SUCCESS', "Newsletter sent");
+define('_AM_XNEWSLETTER_SEND_SUCCESS_TEST', "Newsletter sent for test");
+define('_AM_XNEWSLETTER_SEND_SUCCESS_NUMBER', "Sending %t newsletter(s) successfully");
+define('_AM_XNEWSLETTER_SEND_SUCCESS_ML', "Handle mailinglist successfully");
+define('_AM_XNEWSLETTER_SEND_SUCCESS_ML_DETAIL', "Sending '%a' to mailinglist successfully");
+define('_AM_XNEWSLETTER_SEND_ERROR_NUMBER', "Error sending newsletter: %e of %t newsletters not sent");
+define('_AM_XNEWSLETTER_SEND_ERROR_PHPMAILER', "Error phpmailer: ");
+define('_AM_XNEWSLETTER_SEND_ERROR_NO_EMAIL', "Error: No e-mail-address available");
+define('_AM_XNEWSLETTER_SEND_ERROR_NO_LETTERID', "Error: No valid newsletter selected");
+define('_AM_XNEWSLETTER_SEND_ERROR_INALID_TEMPLATE_PATH', "Error: template path '%p' not found");
+define('_AM_XNEWSLETTER_SEND_SURE_SENT', "This newsletter was already sent to all subscribers.<br/>Do you really want to send this newsletter again to all subscribers?");
+define('_AM_XNEWSLETTER_SEND_ERROR_NO_SUBSCR', "Error: No valid subscriptions for the selected newsletter(s) found");
+//Index
+define('_AM_XNEWSLETTER_LETTER', "Newsletter Statistics");
+define('_AM_XNEWSLETTER_THEREARE_ACCOUNTS', "There are <span class='bold'>%s</span> Accounts in the Database");
+define('_AM_XNEWSLETTER_THEREARE_CAT', "There are <span class='bold'>%s</span> Categories in the Database");
+define('_AM_XNEWSLETTER_THEREARE_SUBSCR', "There are <span class='bold'>%s</span> Subscribers in the Database");
+define('_AM_XNEWSLETTER_THEREARE_CATSUBSCR', "There are <span class='bold'>%s</span> Categories-Subscribers in the Database");
+define('_AM_XNEWSLETTER_THEREARE_LETTER', "There are <span class='bold'>%s</span> Newsletter in the Database");
+define('_AM_XNEWSLETTER_THEREARE_PROTOCOL', "There are <span class='bold'>%s</span> Protocol in the Database");
+define('_AM_XNEWSLETTER_THEREARE_ATTACHMENT', "There are <span class='bold'>%s</span> Attachment in the Database");
+define('_AM_XNEWSLETTER_THEREARE_MAILINGLIST', "There are <span class='bold'>%s</span> Mailinglist in the Database");
+define('_AM_XNEWSLETTER_THEREARE_BMH', "There are <span class='bold'>%s</span> Bounce Mails in the Database");
+define('_AM_XNEWSLETTER_THEREARE_TASK', "There are <span class='bold'>%s</span> Task in the Database");
+//Buttons
+define('_AM_XNEWSLETTER_NEWACCOUNTS', "Add New Account");
+define('_AM_XNEWSLETTER_ACCOUNTSLIST', "List Accounts");
+define('_AM_XNEWSLETTER_ACCOUNTSWAIT', "Pending Accounts");
+define('_AM_XNEWSLETTER_NEWCAT', "Add New Category");
+define('_AM_XNEWSLETTER_CATLIST', "List Categories");
+define('_AM_XNEWSLETTER_CATWAIT', "Pending Categories");
+define('_AM_XNEWSLETTER_NEWSUBSCR', "Add New Subscriber");
+define('_AM_XNEWSLETTER_SUBSCRLIST', "List Subscribers");
+define('_AM_XNEWSLETTER_SUBSCRWAIT', "Pending Subscribers");
+define('_AM_XNEWSLETTER_NEWCATSUBSCR', "Add New Categories-Subscribers");
+define('_AM_XNEWSLETTER_CATSUBSCRLIST', "List Categories-Subscribers");
+define('_AM_XNEWSLETTER_CATSUBSCRWAIT', "Pending Categories-Subscribers");
+define('_AM_XNEWSLETTER_NEWLETTER', "Add New Newsletter");
+define('_AM_XNEWSLETTER_LETTERLIST', "List Newsletters");
+define('_AM_XNEWSLETTER_LETTERWAIT', "Pending Newsletters");
+define('_AM_XNEWSLETTER_LETTER_DELETE_ALL', "Delete protocol of this newsletter");
+define('_AM_XNEWSLETTER_NEWPROTOCOL', "Add New Protocol");
+define('_AM_XNEWSLETTER_PROTOCOLLIST', "List Protocol");
+define('_AM_XNEWSLETTER_PROTOCOLWAIT', "Pending Protocol");
+define('_AM_XNEWSLETTER_NEWATTACHMENT', "Add New Attachment");
+define('_AM_XNEWSLETTER_ATTACHMENTLIST', "List Attachment");
+define('_AM_XNEWSLETTER_ATTACHMENTWAIT', "Pending Attachment");
+define('_AM_XNEWSLETTER_NEWMAILINGLIST', "Add New Mailinglist");
+define('_AM_XNEWSLETTER_MAILINGLISTLIST', "List Mailinglist");
+define('_AM_XNEWSLETTER_MAILINGLISTWAIT', "Pending Mailinglist");
+define('_AM_XNEWSLETTER_RUNBMH', "Run bounced mail handler");
+define('_AM_XNEWSLETTER_BMHLIST', "List bounced mail handlers");
+define('_AM_XNEWSLETTER_BMHWAIT', "Pending bounced mail handlers");
+define('_AM_XNEWSLETTER_ACCOUNTS_ADD', "Add an Account");
+define('_AM_XNEWSLETTER_ACCOUNTS_EDIT', "Edit an Account");
+define('_AM_XNEWSLETTER_ACCOUNTS_DELETE', "Delete an Account");
+define('_AM_XNEWSLETTER_ACCOUNTS_ID', "Id");
+define('_AM_XNEWSLETTER_ACCOUNTS_TYPE', "Type");
+define('_AM_XNEWSLETTER_ACCOUNTS_NAME', "Name");
+define('_AM_XNEWSLETTER_ACCOUNTS_YOURNAME', "Your name");
+define('_AM_XNEWSLETTER_ACCOUNTS_YOURMAIL', "Your mail");
+define('_AM_XNEWSLETTER_ACCOUNTS_USERNAME', "Username");
+define('_AM_XNEWSLETTER_ACCOUNTS_PASSWORD', "Password");
+define('_AM_XNEWSLETTER_ACCOUNTS_INCOMING', "Incoming");
+define('_AM_XNEWSLETTER_ACCOUNTS_SERVER_IN', "Server incoming");
+define('_AM_XNEWSLETTER_ACCOUNTS_PORT_IN', "Port in");
+define('_AM_XNEWSLETTER_ACCOUNTS_SECURETYPE_IN', "Securetype in");
+define('_AM_XNEWSLETTER_ACCOUNTS_OUTGOING', "Outgoing");
+define('_AM_XNEWSLETTER_ACCOUNTS_SERVER_OUT', "Server outgoing");
+define('_AM_XNEWSLETTER_ACCOUNTS_PORT_OUT', "Port out");
+define('_AM_XNEWSLETTER_ACCOUNTS_SECURETYPE_OUT', "Securetype out");
+define('_AM_XNEWSLETTER_ACCOUNTS_DEFAULT', "Default account");
+define('_AM_XNEWSLETTER_ACCOUNTS_BOUNCE_INFO', "Addtional info for bounced mails handling");
+define('_AM_XNEWSLETTER_ACCOUNTS_USE_BMH', "Use bounced mails handling");
+define('_AM_XNEWSLETTER_ACCOUNTS_INBOX', "Mailbox to check for bounced mails");
+define('_AM_XNEWSLETTER_ACCOUNTS_HARDBOX', "Use this mailbox as 'hardbox'");
+define('_AM_XNEWSLETTER_ACCOUNTS_HARDBOX_DESC', "The mailboxname must start with 'INBOX.'. You can select a standard folder in your mailbox (e.g. INBOX.Trash) or create your own special folders like 'hard' and 'soft'. If you type in a new folder name, the folder will be created (this function is not available for gmail-accounts).");
+define('_AM_XNEWSLETTER_ACCOUNTS_MOVEHARD', "Move bounced mail in 'hardbox'");
+define('_AM_XNEWSLETTER_ACCOUNTS_SOFTBOX', "Use this mailbox as 'softbox'");
+define('_AM_XNEWSLETTER_ACCOUNTS_MOVESOFT', "Move bounced mail in 'softbox'");
+define('_AM_XNEWSLETTER_ACCOUNTS_SUBMITTER', "Submitter");
+define('_AM_XNEWSLETTER_ACCOUNTS_CREATED', "Created");
+define('_AM_XNEWSLETTER_ACCOUNTS_ERROR_OPEN_MAILBOX', "Error open mailbox! Please check your settings!");
+define('_AM_XNEWSLETTER_SAVE_AND_CHECK', "Save and check settings");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_OK', "succesful ");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_FAILED', "failed ");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_SKIPPED', "skipped");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK', "Check result");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_INFO', "Additional info");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_OPEN_MAILBOX', "Open mailbox ");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_OPEN_FOLDERS', "Open folders ");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH', "Bounced mail handler ");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH_INBOX', "Mailbox");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH_HARDBOX', "Hardbox");
+define('_AM_XNEWSLETTER_ACCOUNTS_CHECK_BMH_SOFTBOX', "Softbox");
+define('_AM_XNEWSLETTER_CAT_ADD', "Add a category");
+define('_AM_XNEWSLETTER_CAT_EDIT', "Edit a categories");
+define('_AM_XNEWSLETTER_CAT_DELETE', "Delete a categories");
+define('_AM_XNEWSLETTER_CAT_ID', "Id");
+define('_AM_XNEWSLETTER_CAT_NAME', "Newsletter name");
+define('_AM_XNEWSLETTER_CAT_INFO', "Additional info");
+define('_AM_XNEWSLETTER_CAT_GPERMS_CREATE', "Permissions to create");
+define('_AM_XNEWSLETTER_CAT_GPERMS_CREATE_DESC', "<br/><span style='font-weight:normal'>- Create new newsletters<br/>- Edit, delete, send of own newsletters</span>");
+define('_AM_XNEWSLETTER_CAT_GPERMS_ADMIN', "Permission to admin");
+define('_AM_XNEWSLETTER_CAT_GPERMS_ADMIN_DESC', "<br/><span style='font-weight:normal'>Edit, delete, send of all newsletters of this category</span>");
+define('_AM_XNEWSLETTER_CAT_GPERMS_READ', "Permissions to read/subscribe");
+define('_AM_XNEWSLETTER_CAT_GPERMS_LIST', "Permissions to see list of subscribers");
+define('_AM_XNEWSLETTER_CAT_SUBMITTER', "Submitter");
+define('_AM_XNEWSLETTER_CAT_CREATED', "Created");
+define('_AM_XNEWSLETTER_CAT_MAILINGLIST', "Mailinglist");
+define('_AM_XNEWSLETTER_SUBSCR_ADD', "Add a Subscriber");
+define('_AM_XNEWSLETTER_SUBSCR_EDIT', "Edit a Subscriber");
+define('_AM_XNEWSLETTER_SUBSCR_DELETE', "Delete a Subscriber");
+define('_AM_XNEWSLETTER_SUBSCR_ID', "Id");
+define('_AM_XNEWSLETTER_SUBSCR_EMAIL', "Email");
+define('_AM_XNEWSLETTER_SUBSCR_FIRSTNAME', "Firstname");
+define('_AM_XNEWSLETTER_SUBSCR_LASTNAME', "Lastname");
+define('_AM_XNEWSLETTER_SUBSCR_UID', "Membername");
+define('_AM_XNEWSLETTER_SUBSCR_SEX', "Salutation");
+define('_AM_XNEWSLETTER_SUBSCR_SEX_EMPTY', "");
+define('_AM_XNEWSLETTER_SUBSCR_SEX_MALE', "Mr.");
+define('_AM_XNEWSLETTER_SUBSCR_SEX_FEMALE', "Mrs.");
+define('_AM_XNEWSLETTER_SUBSCR_SEX_FAMILY', "Family");
+define('_AM_XNEWSLETTER_SUBSCR_SEX_COMP', "Company");
+define('_AM_XNEWSLETTER_SUBSCR_SUBMITTER', "Submitter");
+define('_AM_XNEWSLETTER_SUBSCR_CREATED', "Created");
+define('_AM_XNEWSLETTER_SUBSCR_ACTIVATED', "activated?");
+define('_AM_XNEWSLETTER_SUBSCR_SHOW_ALL', "Show all");
+define('_AM_XNEWSLETTER_CATSUBSCR_ADD', "Add a Categories-Subscribers");
+define('_AM_XNEWSLETTER_CATSUBSCR_EDIT', "Edit a Categories-Subscribers");
+define('_AM_XNEWSLETTER_CATSUBSCR_DELETE', "Delete a Categories-Subscribers");
+define('_AM_XNEWSLETTER_CATSUBSCR_ID', "Id");
+define('_AM_XNEWSLETTER_CATSUBSCR_CATID', "Cat-Id");
+define('_AM_XNEWSLETTER_CATSUBSCR_SUBSCRID', "Subscribers");
+define('_AM_XNEWSLETTER_CATSUBSCR_QUITED', "Quited");
+define('_AM_XNEWSLETTER_CATSUBSCR_SUBMITTER', "Submitter");
+define('_AM_XNEWSLETTER_CATSUBSCR_CREATED', "Created");
+define('_AM_XNEWSLETTER_CATSUBSCR_SUREDELETE', "Do you really want to delete<br />'%s'<br />from<br />'%c' ?");
+define('_AM_XNEWSLETTER_CATSUBSCR_QUIT_NONE', "None");
+define('_AM_XNEWSLETTER_CATSUBSCR_QUIT_NOW', "Quit now");
+define('_AM_XNEWSLETTER_CATSUBSCR_QUIT_REMOVE', "Remove quit date");
+define('_AM_XNEWSLETTER_LETTER_ADD', "Add a newsletter");
+define('_AM_XNEWSLETTER_LETTER_EDIT', "Edit a newsletter");
+define('_AM_XNEWSLETTER_LETTER_DELETE', "Delete a newsletter");
+define('_AM_XNEWSLETTER_LETTER_ID', "Id");
+define('_AM_XNEWSLETTER_LETTER_TITLE', "Title");
+define('_AM_XNEWSLETTER_LETTER_CONTENT', "Content");
+define('_AM_XNEWSLETTER_LETTER_TEMPLATE', "Template");
+define('_AM_XNEWSLETTER_LETTER_CATS', "Categories");
+define('_AM_XNEWSLETTER_LETTER_ATTACHMENT', "Attachments");
+define('_AM_XNEWSLETTER_LETTER_STATUS', "Status");
+define('_AM_XNEWSLETTER_LETTER_SUBMITTER', "Submitter");
+define('_AM_XNEWSLETTER_LETTER_CREATED', "Created");
+define('_AM_XNEWSLETTER_LETTER_ACCOUNTS_AVAIL', "Available accounts");
+define('_AM_XNEWSLETTER_LETTER_ACCOUNT', "Account");
+define('_AM_XNEWSLETTER_LETTER_MAILINGLIST', "Use mailing list");
+define('_AM_XNEWSLETTER_LETTER_MAILINGLIST_NO', "None");
+define('_AM_XNEWSLETTER_ATTACHMENT_ADD', "Add an attachment");
+define('_AM_XNEWSLETTER_ATTACHMENT_EDIT', "Edit an attachment");
+define('_AM_XNEWSLETTER_ATTACHMENT_DELETE', "Delete an attachment");
+define('_AM_XNEWSLETTER_ATTACHMENT_ID', "Id");
+define('_AM_XNEWSLETTER_ATTACHMENT_LETTER_ID', "Letter-Id");
+define('_AM_XNEWSLETTER_ATTACHMENT_NAME', "Name");
+define('_AM_XNEWSLETTER_ATTACHMENT_TYPE', "File type");
+define('_AM_XNEWSLETTER_ATTACHMENT_SUBMITTER', "Submitter");
+define('_AM_XNEWSLETTER_ATTACHMENT_CREATED', "Created");
+define('_AM_XNEWSLETTER_PROTOCOL_ADD', "Add a Protocol");
+define('_AM_XNEWSLETTER_PROTOCOL_EDIT', "Edit a Protocol");
+define('_AM_XNEWSLETTER_PROTOCOL_DELETE', "Delete a Protocol");
+define('_AM_XNEWSLETTER_PROTOCOL_ID', "Id");
+define('_AM_XNEWSLETTER_PROTOCOL_LETTER_ID', "Newsletter-Id");
+define('_AM_XNEWSLETTER_PROTOCOL_SUBSCRIBER_ID', "Subscriber-Id");
+define('_AM_XNEWSLETTER_PROTOCOL_STATUS', "Status");
+define('_AM_XNEWSLETTER_PROTOCOL_SUCCESS', "Success");
+define('_AM_XNEWSLETTER_PROTOCOL_SUBMITTER', "Submitter");
+define('_AM_XNEWSLETTER_PROTOCOL_CREATED', "Created");
+define('_AM_XNEWSLETTER_PROTOCOL_LAST_STATUS', "Last status");
+define('_AM_XNEWSLETTER_PROTOCOL_MISC', "Misc protocol items");
+define('_AM_XNEWSLETTER_PROTOCOL_NO_SUBSCREMAIL', "No email of recipient found");
+define('_AM_XNEWSLETTER_MAILINGLIST_ADD', "Add a Mailinglist");
+define('_AM_XNEWSLETTER_MAILINGLIST_EDIT', "Edit a Mailinglist");
+define('_AM_XNEWSLETTER_MAILINGLIST_DELETE', "Delete a Mailinglist");
+define('_AM_XNEWSLETTER_MAILINGLIST_ID', "Id");
+define('_AM_XNEWSLETTER_MAILINGLIST_NAME', "Name");
+define('_AM_XNEWSLETTER_MAILINGLIST_EMAIL', "Email");
+define('_AM_XNEWSLETTER_MAILINGLIST_EMAIL_DESC', "Email, where subscription code should be send to");
+define('_AM_XNEWSLETTER_MAILINGLIST_LISTNAME', "Listname");
+define('_AM_XNEWSLETTER_MAILINGLIST_SUBSCRIBE', "Subscribe code");
+define('_AM_XNEWSLETTER_MAILINGLIST_SUBSCRIBE_DESC', "{email} will be replaced by the email of the subscriber");
+define('_AM_XNEWSLETTER_MAILINGLIST_UNSUBSCRIBE', "Unsubscribe code");
+define('_AM_XNEWSLETTER_MAILINGLIST_SUBMITTER', "Submitter");
+define('_AM_XNEWSLETTER_MAILINGLIST_CREATED', "Created");
+define('_AM_XNEWSLETTER_BOUNCETYPE', "Bouncetype");
+define('_AM_XNEWSLETTER_BMH_EDIT', "Edit a bounced mail handler");
+define('_AM_XNEWSLETTER_BMH_DELETE', "Delete a bounced mail handler");
+define('_AM_XNEWSLETTER_BMH_ID', "Id");
+define('_AM_XNEWSLETTER_BMH_RULE_NO', "Rule no");
+define('_AM_XNEWSLETTER_BMH_RULE_CAT', "Rule cat");
+define('_AM_XNEWSLETTER_BMH_BOUNCETYPE', "Bouncetype");
+define('_AM_XNEWSLETTER_BMH_REMOVE', "Removed");
+define('_AM_XNEWSLETTER_BMH_EMAIL', "Email");
+define('_AM_XNEWSLETTER_BMH_SUBJECT', "Subject");
+define('_AM_XNEWSLETTER_BMH_MEASURE', "Measure");
+define('_AM_XNEWSLETTER_BMH_SUBMITTER', "Submitter");
+define('_AM_XNEWSLETTER_BMH_CREATED', "Created");
+define('_AM_XNEWSLETTER_BMH_MEASURE_PENDING', "Pending");
+define('_AM_XNEWSLETTER_BMH_MEASURE_NOTHING', "Do nothing");
+define('_AM_XNEWSLETTER_BMH_MEASURE_QUIT', "Quit this subscriber temporary");
+define('_AM_XNEWSLETTER_BMH_MEASURE_DELETE', "Delete this subscriber");
+define('_AM_XNEWSLETTER_BMH_MEASURE_QUITED', "Subscriber temporary quited");
+define('_AM_XNEWSLETTER_BMH_MEASURE_DELETED', "Subscriber deleted");
+define('_AM_XNEWSLETTER_BMH_MEASURE_ALREADY_DELETED', "Subscriber already deleted! Action not possible!");
+define('_AM_XNEWSLETTER_BMH_MEASURE_DELETE_SURE', "Do you really want to delete this registration with all subscriptions?<br /><br />Reactivating by the subscriber will not be posssible later!<br/><br />");
+define('_AM_XNEWSLETTER_BMH_ERROR_NO_SUBSCRID', "There is nor existing registration for the this email!");
+define('_AM_XNEWSLETTER_BMH_ERROR_NO_ACTIVE', "Bounced mail handler isn't activated in any account");
+define('_AM_XNEWSLETTER_BMH_RSLT', "Result of checking mailbox %b<br/>Messages read: %r<br/>Action taken: %a<br/>No action taken: %n<br/>Moved: %m<br/>Deleted: %d<br/><br/><br/>");
+define('_AM_XNEWSLETTER_BMH_SUCCESSFUL', "Bounced mail handler successfully finished");
+define('_AM_XNEWSLETTER_BMH_MEASURE_ALL', "Show all");
+define('_AM_XNEWSLETTER_BMH_MEASURE_SHOW_NONE', "No bmh items for measure '%s' available");
+define('_AM_XNEWSLETTER_MAINTENANCE_CAT', "Category");
+define('_AM_XNEWSLETTER_MAINTENANCE_DESCR', "Description");
+define('_AM_XNEWSLETTER_MAINTENANCE_PARAM', "Params");
+define('_AM_XNEWSLETTER_MAINTENANCE_ERROR', "Error while running maintenance");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETEDATE', "Delete all registrations without confirmation, where registration was before this date.<br />Attention: there is noe undo possible! Please check date before execution!");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETEUSER', "Should these <b>%s</b> unconfirmed registrations with date before %s really deleted.<br />Attention: there is noe undo possible!");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETEPROTOCOL', "Delete all protocols and reset tables");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETEPROTOK', "Table protocol maintained.");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETENOTHING', "No action necessary.");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETEUSEROK', "%s Users have been deleted");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_SUBCR', "Delete subscriptions to newsletter without an existing registration");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_SUBCR_OK', "%s subscriptions have been deleted");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_SUBCR_NODATA', "No invalid data in table catsubsr found");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML', "Compare data from newsletter cats with mailinglists and correct invalid data");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML_OK', "%s wrong data in mailinglist have been corrected");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML_NODATA', "No invalid data mailinglist found");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_CATNL', "Compare data from newsletter cats with newsletters and correct invalid data");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_CATNL_OK', "%s wrong data in newsletters have been corrected");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_CATNL_NODATA', "No invalid data newsletters found");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_IMPORT', "Delete table import and reset table");
+define('_AM_XNEWSLETTER_MAINTENANCE_DELETE_IMPORT_OK', "Table import maintained.");
+define('_AM_XNEWSLETTER_IMPORT_SEARCH', "Search available E-Mail-Addresses for import");
+define('_AM_XNEWSLETTER_IMPORT_PRESELECT_CAT', "Preselect category");
+define('_AM_XNEWSLETTER_IMPORT_PLUGINS_AVAIL', "Available plugins");
+define('_AM_XNEWSLETTER_IMPORT_CONTINUE', "Continue");
+define('_AM_XNEWSLETTER_IMPORT_AFTER_READ', "Action after reading the data");
+define('_AM_XNEWSLETTER_IMPORT_READ_CHECK', "Show data for check");
+define('_AM_XNEWSLETTER_IMPORT_CHECK_LIMIT', "Limit E-Mail-Addresses for import");
+define('_AM_XNEWSLETTER_IMPORT_CHECK_LIMIT_PACKAGE', "Limit E-Mail-Addresses per processing step");
+define('_AM_XNEWSLETTER_IMPORT_NOLIMIT', "No limit");
+define('_AM_XNEWSLETTER_IMPORT_READ_IMPORT', "Import data at once without a check");
+define('_AM_XNEWSLETTER_IMPORT_SHOW', "Show %s to %l of %n available E-Mail-Addresses");
+define('_AM_XNEWSLETTER_IMPORT_NODATA', "No data found");
+define('_AM_XNEWSLETTER_IMPORT_EMAIL_EXIST', "E-Mail already registered");
+define('_AM_XNEWSLETTER_IMPORT_CATSUBSCR_EXIST', "Subscription already exist");
+define('_AM_XNEWSLETTER_IMPORT_NOIMPORT', "-- no import --");
+define('_AM_XNEWSLETTER_IMPORT_EXEC', "Import E-Mail-Addresses as preselected");
+define('_AM_XNEWSLETTER_IMPORT_RESULT_SKIP', "Import E-Mail-Address %e skipped");
+define('_AM_XNEWSLETTER_IMPORT_RESULT_FAILED', "Import E-Mail-Address %e failed");
+define('_AM_XNEWSLETTER_IMPORT_RESULT_REG_OK', "Registration successful");
+define('_AM_XNEWSLETTER_IMPORT_RESULT_SUBSCR_OK', "Subscription to category successful");
+define('_AM_XNEWSLETTER_IMPORT_SKIP_EXISTING', "Skip existing subscriptions");
+define('_AM_XNEWSLETTER_IMPORT_FINISHED', "Processing %p of %t email-addresses successful finished");
+define('_AM_XNEWSLETTER_IMPORT_INFO', "Add all users of a group to a newsletter");
+define('_AM_XNEWSLETTER_IMPORT_CSV_OPT', "Options for CSV-file");
+define('_AM_XNEWSLETTER_IMPORT_CSV_FILE', "CSV-file:");
+define('_AM_XNEWSLETTER_IMPORT_CSV_DELIMITER', "Delimiter:");
+define('_AM_XNEWSLETTER_IMPORT_CSV_HEADER', "CSV-file with header");
+define('_AM_XNEWSLETTER_IMPORT_CSV', "One column ( email ) or four columns ( email | sex | firstname | lastname )<br />see sample1col.csv and sample4col.csv in /plugins");
+define('_AM_XNEWSLETTER_IMPORT_XOOPSUSER', "Options for import/syncronisation XoopsUsers");
+define('_AM_XNEWSLETTER_IMPORT_XOOPSUSER_GROUPS', "Select groups");
+define('_AM_XNEWSLETTER_NEWTASK', "Add New task");
+define('_AM_XNEWSLETTER_TASKLIST', "List task");
+define('_AM_XNEWSLETTER_TASK_ADD', "Add a task");
+define('_AM_XNEWSLETTER_TASK_EDIT', "Edit a task");
+define('_AM_XNEWSLETTER_TASK_DELETE', "Delete a task");
+define('_AM_XNEWSLETTER_TASK_ID', "Id");
+define('_AM_XNEWSLETTER_TASK_LETTER_ID', "Letter");
+define('_AM_XNEWSLETTER_TASK_SUBSCR_ID', "Subscriber");
+define('_AM_XNEWSLETTER_TASK_STATUS', "Status");
+define('_AM_XNEWSLETTER_TASK_STARTTIME', "Starttime");
+define('_AM_XNEWSLETTER_TASK_SUBMITTER', "Submitter");
+define('_AM_XNEWSLETTER_TASK_CREATED', "Created");
+define('_AM_XNEWSLETTER_TASK_ERROR_CREATE', "Error creating item in tasklist");
+define('_AM_XNEWSLETTER_TASK_NO_DATA', "No tasks waiting");
+//Error NoFrameworks
+define('_AM_XNEWSLETTER_NOFRAMEWORKS', "Error: You do not use the Frameworks \"admin module\". Please install this Frameworks");
+define('_AM_XNEWSLETTER_MAINTAINEDBY', "is maintained by the");
+define('_AM_XNEWSLETTER_SEND_ERROR_NO_LETTERCONTENT', "No text available for printing");
+define('_AM_XNEWSLETTER_FORMSEARCH_SUBSCR_EXIST', "Search existing subscription of an e-mail-address");
+define('_AM_XNEWSLETTER_SUBSCR_NO_CATSUBSCR', "For this e-mail-address are no subscription to newsletter cats available");
+//version 1.2
+define('_AM_XNEWSLETTER_IMPORT_ERROR_NO_PLUGIN', "Error: required file 'plugins/%p.php' not found!");
+define('_AM_XNEWSLETTER_IMPORT_ERROR_NO_FUNCTION', "Error: required function 'xnewsletter_plugin_getdata_%f' doesn't exist!");
?>
\ No newline at end of file
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/blocks.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/blocks.php 2013-10-17 23:40:19 UTC (rev 12184)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/blocks.php 2013-10-20 12:27:39 UTC (rev 12185)
@@ -1,32 +1,30 @@
-<?php
-/**
- * ****************************************************************************
- * XNEWSLETTER - MODULE FOR XOOPS
- * Copyright (c) 2007 - 2012
- * Goffy ( wedega.com )
- *
- * 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 Goffy ( wedega.com )
- * @license GPL 2.0
- * @package xNewsletter
- * @author Goffy ( web...@we... )
- *
- * Version : 1 Mon 2012/11/05 14:31:32 : Exp $
- * ****************************************************************************
- */
-
-define("_MB_XNEWSLETTER_CATSUBSCR_ALLCAT","All categories");
-define("_MB_XNEWSLETTER_LETTER_DISPLAY","Number of items");
-define("_MB_XNEWSLETTER_LETTER_TITLELENGTH","Length of email and newsletter name (0 means no limit)");
-define("_MB_XNEWSLETTER_LETTER_CATTODISPLAY","Select the categories to display");
-
+<?php
+/**
+ * ****************************************************************************
+ * XNEWSLETTER - MODULE FOR XOOPS
+ * Copyright (c) 2007 - 2012
+ * Goffy ( wedega.com )
+ *
+ * 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 Goffy ( wedega.com )
+ * @license GPL 2.0
+ * @package xNewsletter
+ * @author Goffy ( web...@we... )
+ *
+ * Version : 1 Mon 2012/11/05 14:31:32 : Exp $
+ * ****************************************************************************
+ */
+define('_MB_XNEWSLETTER_CATSUBSCR_ALLCAT', "All categories");
+define('_MB_XNEWSLETTER_LETTER_DISPLAY', "Number of items");
+define('_MB_XNEWSLETTER_LETTER_TITLELENGTH', "Length of email and newsletter name (0 means no limit)");
+define('_MB_XNEWSLETTER_LETTER_CATTODISPLAY', "Select the categories to display");
?>
\ No newline at end of file
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/activate.tpl
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/activate.tpl 2013-10-17 23:40:19 UTC (rev 12184)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/activate.tpl 2013-10-20 12:27:39 UTC (rev 12185)
@@ -1,13 +1,15 @@
Dear {SEX} {FIRSTNAME} {LASTNAME}
-You have registered with your Email Address
+You have, with the email address
{EMAIL} from the IP: {IP}
-in our Newsletter / Mailing list.
+subscribed to our newsletter/mailing list.
-To confirm, this click to following link:
+To complete the application, click
+the following link:
{ACTLINK}
+If you have not registered, please ignore this email.
-----------------------
{X_SITENAME}
({X_SITEURL})
-Webmaster {X_ADMINMAIL}
\ No newline at end of file
+Webmaster {X_ADMINMAIL}
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/delete.tpl
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/delete.tpl 2013-10-17 23:40:19 UTC (rev 12184)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/delete.tpl 2013-10-20 12:27:39 UTC (rev 12185)
@@ -1,16 +1,18 @@
Dear {SEX} {FIRSTNAME} {LASTNAME}
-You want to unsubscribe your Newsletter:
+You asked to unsubscribe your Newsletter
+with the email address:
{EMAIL}
-Send from the IP: {IP}
+(Send from the IP: {IP})
-To confirm this click the following link:
+To complete the deletion, click
+on the following link:
{ACTLINK}
-Will you not unsubscribe, ignore this Email.
+If you don't want this, simply ignore the email.
-----------------------
{X_SITENAME}
({X_SITEURL})
-Webmaster {X_ADMINMAIL}
\ No newline at end of file
+Webmaster {X_ADMINMAIL}
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/info_change.html
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/info_change.html 2013-10-17 23:40:19 UTC (rev 12184)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/info_change.html 2013-10-20 12:27:39 UTC (rev 12185)
@@ -1,4 +1,4 @@
-<p>Hallo {SEX} {FIRSTNAME} {LASTNAME}</p>
+<p>Dear {SEX} {FIRSTNAME} {LASTNAME}</p>
<p>Your subscription to email-address
{EMAIL} have been changed by <a href="{USERLINK}">{USERNAME}</a> with IP-address {IP}.</p>
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/update.tpl
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/update.tpl 2013-10-17 23:40:19 UTC (rev 12184)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/mail_template/update.tpl 2013-10-20 12:27:39 UTC (rev 12185)
@@ -10,4 +10,4 @@
-----------------------
{X_SITENAME}
({X_SITEURL})
-Webmaster {X_ADMINMAIL}
\ No newline at end of file
+Webmaster {X_ADMINMAIL}
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php 2013-10-17 23:40:19 UTC (rev 12184)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php 2013-10-20 12:27:39 UTC (rev 12185)
@@ -1,104 +1,89 @@
-<?php
-/**
- * ****************************************************************************
- * - A Project by Developers TEAM For Xoops - ( http://www.xoops.org )
- * ****************************************************************************
- * XNEWSLETTER - MODULE FOR XOOPS
- * Copyright (c) 2007 - 2012
- * Goffy ( wedega.com )
- *
- * 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 (...
[truncated message content] |
|
From: <txm...@us...> - 2013-10-17 23:40:22
|
Revision: 12184
http://sourceforge.net/p/xoops/svn/12184
Author: txmodxoops
Date: 2013-10-17 23:40:19 +0000 (Thu, 17 Oct 2013)
Log Message:
-----------
Deleted unnecessary parameters
Added new line code in same files
Deleted duplicated code for table_fields, table_parameters
Modified Paths:
--------------
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/building.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_admin_pages.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_class.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_templates_pages.php
Modified: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/building.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/building.php 2013-10-17 23:19:32 UTC (rev 12183)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/building.php 2013-10-17 23:40:19 UTC (rev 12184)
@@ -95,7 +95,7 @@
}
// Creation of classes
if ( $table_admin == 1 || $table_user == 1) {
- const_class($modules, $table_name, $table_fieldname, $table_category, $table_fields, $table_parameters, $table_permissions);
+ const_class($modules, $table_name, $table_fieldname, $table_fields, $table_parameters, $table_permissions);
}
// Creation of pages admin
if ( $table_admin == 1 ) {
Modified: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_admin_pages.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_admin_pages.php 2013-10-17 23:19:32 UTC (rev 12183)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_admin_pages.php 2013-10-17 23:40:19 UTC (rev 12184)
@@ -28,10 +28,19 @@
$stu_mod_name = strtoupper($mod_name);
$stu_table_name = strtoupper($table_name);
$file = $table_name.'.php';
- $tdmcreate_path = TDM_CREATE_MURL.'/'.$mod_name.'/admin/'.$file;
- $root_path = XOOPS_URL.'/modules/'.$mod_name.'/admin/'.$file;
+ $tdmcreate_path = TDM_CREATE_MURL.'/'.$stl_mod_name.'/admin/'.$file;
+ $root_path = XOOPS_URL.'/modules/'.$stl_mod_name.'/admin/'.$file;
+
+ //fields
+ $fields_total = explode('|', $table_fields);
+ $nb_fields = count($fields_total);
+ list($fpif, $fpe, $fpda, $fpdu, $fpdb, $fpmf, $fpds, $fprf) = table_fields($table_fields, $table_parameters);
+
+ //$field_id = $fields[0];
+ //$field_name = $fields[1];
+
$text = '<?php'.const_header($modules, $file);
-$text .= <<<EOT
+ $text .= <<<EOT
\ninclude_once 'header.php';
//It recovered the value of argument op in URL$
\$op = {$mod_name}_CleanVars(\$_REQUEST, 'op', 'list', 'string');
@@ -44,36 +53,7 @@
\${$table_fieldname}_waiting = \${$table_name}Handler->getCount(\$criteria);
EOT;
}
-//fields
-$fields_total = explode('|', $table_fields);
-$nb_fields = count($fields_total);
-//parameters
-$parameters_total = explode('|', $table_parameters);
-
-//Recuperation des noms des tables
-for($i=0; $i<$nb_fields; $i++)
-{
- //Nom des fields
- $fields1 = explode(':', $fields_total[$i]);
- $fields[$i] = $fields1[0];
- //Afficher dans l'admin
- if( $i == 0 ) {
- $fpa[$i] = '0';
- } else {
- $param = explode(':', $parameters_total[$i-1]);
- $fpt[$i] = $param[0]; // fpt = fields parameters type
- $fpa[$i] = $param[2]; // fpa = fields parameters admin
- $fprf[$i] = $param[6]; // fprf = fields parameters required field
- if ( $param[4] == 1 ) {
- $fpmf = $fields[0]; // fpmf = fields parameters main field
- }
- }
-}
-
-$field_id = $fields[0];
-$field_name = $fields[1];
-
$text .= <<<EOT
\n\necho \$adminMenu->addNavigation('{$table_name}.php');
switch (\$op)
@@ -83,17 +63,17 @@
\$adminMenu->addItemButton({$language}_ADD_{$stu_table_name}, '{$table_name}.php?op=new', 'add');
echo \$adminMenu->renderButton();
\$criteria = new CriteriaCompo();
- \$criteria->setSort('{$field_id} ASC, {$fpmf}');
+ \$criteria->setSort('{$fpif} ASC, {$fpmf}');
\$criteria->setOrder('ASC');
- \$numrows = \${$table_name}Handler->getCount();
+ \${$table_name}_rows = \${$table_name}Handler->getCount();
\${$table_name}_arr = \${$table_name}Handler->getAll(\$criteria);
EOT;
- $fcn = const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $field_id, $nb_fields, $fields, $fpa, $fpt, $fpmf, $language, '', 0);
+ $fcn = const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $nb_fields, $fields_total, $fpif, $fpda, $fpe, $fpmf, $language, '', 0);
if ( $table_category != 1 )
{
$text .= <<<EOT
\n\t\t// Table view
- if (\$numrows>0)
+ if (\${$table_name}_rows > 0)
{
echo "<table width='100%' cellspacing='1' class='outer'>
<tr>
@@ -110,13 +90,13 @@
echo "<tr class='".\$class."'>";
\$class = (\$class == "even") ? "odd" : "even";\n
EOT;
- $fields_data = const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $field_id, $nb_fields, $fields, $fpa, $fpt, $fpmf, $language, '', 1);
+ $fields_data = const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $nb_fields, $fields_total, $fpif, $fpda, $fpe, $fpmf, $language, '', 1);
$text .= $fields_data;
$text .= <<<EOT
- \n\t\t\t\t\techo "<td class='center width5'>
- <a href='{$table_name}.php?op=edit&{$field_id}=".\$i."'><img src=".\$sysPathIcon16."/edit.png alt='"._EDIT."' title='"._EDIT."'></a>
- <a href='{$table_name}.php?op=delete&{$field_id}=".\$i."'><img src=".\$sysPathIcon16."/delete.png alt='"._DELETE."' title='"._DELETE."'></a>
+\n\t\t\t\t\techo "<td class='center width5'>
+ <a href='{$table_name}.php?op=edit&{$fpif}=".\$i."'><img src=".\$sysPathIcon16."/edit.png alt='"._EDIT."' title='"._EDIT."'></a>
+ <a href='{$table_name}.php?op=delete&{$fpif}=".\$i."'><img src=".\$sysPathIcon16."/delete.png alt='"._DELETE."' title='"._DELETE."'></a>
</td>";
echo "</tr>";
}
@@ -127,14 +107,14 @@
EOT;
$text .= $fcn;
$text .= <<<EOT
- \n\t\t\t\t\t<th class='center width5'>".{$language}_FORMACTION."</th>
+\n\t\t\t\t\t<th class='center width5'>".{$language}_FORMACTION."</th>
</tr><tr><td class='errorMsg' colspan='{$nb_fields}'>There are no {$table_name}</td></tr>";
echo "</table><br /><br />";
}
EOT;
} else {
$text .= <<<EOT
- \n\t\t// Display function that allows children categories
+\n\t\t// Display function that allows children categories
function {$mod_name}_children(\$cat_id = 0, \${$table_name}_arr, \$prefix = "", \$order = "", &\$class)
{
global \$pathIcon16;
@@ -148,11 +128,11 @@
\$cat_weight = \$categories_arr[\$i]->getVar('cat_weight');
echo "<tr class='".\$class."'>";\n
EOT;
- $text .= const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $field_id, $nb_fields, $fields, $fpa, $fpt, $fpmf, $language, '', 1);
+ $text .= const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $nb_fields, $fields_total, $fpif, $fpda, $fpe, $fpmf, $language, '', 1);
$text .= <<<EOT
- \n\t\t\t\t\techo "<td class='center width5'>
- <a href='{$table_name}.php?op=edit&{$field_id}=".\$i"'><img src=".\$sysPathIcon16."/edit.png alt='"._EDIT."' title='"._EDIT."'></a>
- <a href='{$table_name}.php?op=delete&{$field_id}=".\$i"'><img src=".\$sysPathIcon16."/delete.png alt='"._DELETE."' title='"._DELETE."'></a>
+\n\t\t\t\t\techo "<td class='center width5'>
+ <a href='{$table_name}.php?op=edit&{$fpif}=".\$i"'><img src=".\$sysPathIcon16."/edit.png alt='"._EDIT."' title='"._EDIT."'></a>
+ <a href='{$table_name}.php?op=delete&{$fpif}=".\$i"'><img src=".\$sysPathIcon16."/delete.png alt='"._DELETE."' title='"._DELETE."'></a>
</td>
</tr>";
\$class = (\$class == "even") ? "odd" : "even";
@@ -170,15 +150,15 @@
}
// Table view
- if (\$numrows>0)
+ if (\${$table_name}_rows > 0)
{
echo "<table width='100%' cellspacing='1' class='outer'>
<tr>
EOT;
- $fcn = const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $field_id, $nb_fields, $fields, $fpa, $fpt, $fpmf, $language, '', 0);
+ $fcn = const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $nb_fields, $fields_total, $fpif, $fpda, $fpe, $fpmf, $language, '', 0);
$text .= $fcn;
$text .= <<<EOT
- \n\t\t\t\t\t<th class='center width5'>".{$language}_FORMACTION."</th>
+\n\t\t\t\t\t<th class='center width5'>".{$language}_FORMACTION."</th>
</tr>";
\$class = "odd";
\$icon = "<img src='".{$stu_mod_name}_URL."/images/icons/16/arrow.gif'>";
@@ -192,13 +172,13 @@
\$category_weight = \${$table_name}_arr[\$i]->getVar('{$table_fieldname}_weight');
echo "<tr class='".\$class."'>";\n
EOT;
- $fields_data = const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $field_id, $nb_fields, $fields, $fpa, $fpt, $fpmf, $language, 1, 1);
+ $fields_data = const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $nb_fields, $fields_total, $fpif, $fpda, $fpe, $fpmf, $language, 1, 1);
$text .= $fields_data;
$text .= <<<EOT
- \n\t\t\t\t\techo "<td class='center width5'>
- <a href='{$table_name}.php?op=edit&{$field_id}=".\$i"'><img src=".\$sysPathIcon16."/edit.png alt='"._EDIT."' title='"._EDIT."'></a>
- <a href='{$table_name}.php?op=delete&{$field_id}=".\$i"'><img src=".\$sysPathIcon16."/delete.png alt='"._DELETE."' title='"._DELETE."'></a>
+\n\t\t\t\t\techo "<td class='center width5'>
+ <a href='{$table_name}.php?op=edit&{$fpif}=".\$i"'><img src=".\$sysPathIcon16."/edit.png alt='"._EDIT."' title='"._EDIT."'></a>
+ <a href='{$table_name}.php?op=delete&{$fpif}=".\$i"'><img src=".\$sysPathIcon16."/delete.png alt='"._DELETE."' title='"._DELETE."'></a>
</td>
</tr>";
\$class = (\$class == "even") ? "odd" : "even";
@@ -220,10 +200,10 @@
echo "<table width='100%' cellspacing='1' class='outer'>
<tr>
EOT;
- $fcn = const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $field_id, $nb_fields, $fields, $fpa, $fpt, $fpmf, $language, '', 0);
+ $fcn = const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $nb_fields, $fields_total, $fpif, $fpda, $fpe, $fpmf, $language, '', 0);
$text .= $fcn;
$text .= <<<EOT
- \n\t\t\t\t\t<th class='center width5'>".{$language}_FORMACTION."</th>
+\n\t\t\t\t\t<th class='center width5'>".{$language}_FORMACTION."</th>
</tr>
<tr><td class='errorMsg' colspan='{$nb_fields}'>There are no {$table_name}</td></tr>";
echo "</table><br /><br />";
@@ -237,8 +217,8 @@
\$adminMenu->addItemButton({$language}_{$stu_table_name}_LIST, '{$table_name}.php', 'list');
echo \$adminMenu->renderButton();
- \$obj =& \${$table_name}Handler->create();
- \$form = \$obj->getForm();
+ \${$table_name}_obj =& \${$table_name}Handler->create();
+ \$form = \${$table_name}_obj->getForm();
\$form->display();
break;
@@ -246,21 +226,21 @@
if ( !\$GLOBALS['xoopsSecurity']->check() ) {
redirect_header('{$table_name}.php', 3, implode(',', \$GLOBALS['xoopsSecurity']->getErrors()));
}
- if (isset(\$_REQUEST['{$field_id}'])) {
- \$obj =& \${$table_name}Handler->get(\$_REQUEST['{$field_id}']);
+ if (isset(\$_REQUEST['{$fpif}'])) {
+ \${$table_name}_obj =& \${$table_name}Handler->get(\$_REQUEST['{$fpif}']);
} else {
- \$obj =& \${$table_name}Handler->create();
+ \${$table_name}_obj =& \${$table_name}Handler->create();
}
EOT;
- $text .= const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $field_id, $nb_fields, $fields, $fpa, $fpt, $fpmf, $language, '', 2);
+ $text .= const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $nb_fields, $fields_total, $fpif, $fpda, $fpe, $fpmf, $language, '', 2);
$text .= <<<EOT
- \n\t\tif (\${$table_name}Handler->insert(\$obj)) {
+\n\t\tif (\${$table_name}Handler->insert(\${$table_name}_obj)) {
redirect_header('{$table_name}.php?op=list', 2, {$language}_FORMOK);
}
- echo \$obj->getHtmlErrors();
- \$form =& \$obj->getForm();
+ echo \${$table_name}_obj->getHtmlErrors();
+ \$form =& \${$table_name}_obj->getForm();
\$form->display();
break;
@@ -268,38 +248,38 @@
\$adminMenu->addItemButton({$language}_ADD_{$stu_table_name}, '{$table_name}.php?op=new', 'add');
\$adminMenu->addItemButton({$language}_{$stu_table_name}_LIST, '{$table_name}.php', 'list');
echo \$adminMenu->renderButton();
- \$obj = \${$table_name}Handler->get(\$_REQUEST['{$field_id}']);
- \$form = \$obj->getForm();
+ \${$table_name}_obj = \${$table_name}Handler->get(\$_REQUEST['{$fpif}']);
+ \$form = \${$table_name}_obj->getForm();
\$form->display();
break;
case 'delete':
- \$obj =& \${$table_name}Handler->get(\$_REQUEST['{$field_id}']);
+ \${$table_name}_obj =& \${$table_name}Handler->get(\$_REQUEST['{$fpif}']);
if (isset(\$_REQUEST['ok']) && \$_REQUEST['ok'] == 1) {
if ( !\$GLOBALS['xoopsSecurity']->check() ) {
redirect_header('{$table_name}.php', 3, implode(', ', \$GLOBALS['xoopsSecurity']->getErrors()));
}
- if (\${$table_name}Handler->delete(\$obj)) {
+ if (\${$table_name}Handler->delete(\${$table_name}_obj)) {
redirect_header('{$table_name}.php', 3, {$language}_FORMDELOK);
} else {
- echo \$obj->getHtmlErrors();
+ echo \${$table_name}_obj->getHtmlErrors();
}
} else {
- xoops_confirm(array('ok' => 1, '{$field_id}' => \$_REQUEST['{$field_id}'], 'op' => 'delete'), \$_SERVER['REQUEST_URI'], sprintf({$language}_FORMSUREDEL, \$obj->getVar('{$fpmf}')));
+ xoops_confirm(array('ok' => 1, '{$fpif}' => \$_REQUEST['{$fpif}'], 'op' => 'delete'), \$_SERVER['REQUEST_URI'], sprintf({$language}_FORMSUREDEL, \${$table_name}_obj->getVar('{$fpmf}')));
}
break;
EOT;
if(isset($_REQUEST['table_online']) == 1) {
$text .= <<<EOT
\ncase 'update_online':
- if (isset(\$_REQUEST['{$field_id}'])) {
- \$obj =& \${$table_name}Handler->get(\$_REQUEST['{$field_id}']);
+ if (isset(\$_REQUEST['{$fpif}'])) {
+ \${$table_name}_obj =& \${$table_name}Handler->get(\$_REQUEST['{$fpif}']);
}
- \$obj->setVar('{$table_fieldname}_online', \$_REQUEST['{$table_fieldname}_online']);
- if (\${$table_name}Handler->insert(\$obj)) {
+ \${$table_name}_obj->setVar('{$table_fieldname}_online', \$_REQUEST['{$table_fieldname}_online']);
+ if (\${$table_name}Handler->insert(\${$table_name}_obj)) {
redirect_header('{$table_name}.php', 3, {$language}_FORMOK);
}
- echo \$obj->getHtmlErrors();
+ echo \${$table_name}_obj->getHtmlErrors();
break;
EOT;
}
Modified: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_class.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_class.php 2013-10-17 23:19:32 UTC (rev 12183)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_class.php 2013-10-17 23:40:19 UTC (rev 12184)
@@ -19,46 +19,20 @@
* @version $Id: const_class.php 11084 2013-02-23 15:44:20Z timgno $
*/
include_once XOOPS_ROOT_PATH.'/modules/TDMCreate/include/functions_const.php';
-function const_class($modules, $table_name, $table_fieldname, $table_category, $table_fields, $table_parameters, $table_permissions)
+function const_class($modules, $table_name, $table_fieldname, $table_fields, $table_parameters, $table_permissions)
{
$mod_name = $modules->getVar('mod_name');
+ $stl_mod_name = strtolower($mod_name);
$language = '_AM_'.strtoupper($mod_name).'_';
$file = $table_name. '.php';
- $tdmcreate_path = TDM_CREATE_MURL.'/'.$mod_name.'/class/'.$file;
- $root_path = XOOPS_URL.'/modules/'.$mod_name.'/class/'.$file;
- $constructor = const_fields($mod_name, $table_name, $table_fieldname, $table_category, $table_fields, $language, 0, 0, 0, 0);
- //fields
- $fields_total = explode('|', $table_fields);
- $nb_fields = count($fields_total);
- //print_r($fields_total);
- //parameters
- $parameters_total = explode('|', $table_parameters);
-
- //Recuperation des parameters affichage dans le formulaire
- for($i=0; $i<$nb_fields; $i++)
- {
- $fields = explode(':', $fields_total[$i]);
- //$fields[$i] = $fields1[0];
- //Afficher dans les elements du formulaire et choisir le type
- if( $i == 0 ) {
- $fpe[$i] = '0';
- $fpdf[$i] = '0';
- $fpif = $fields[0]; // fpif = fields parameters auto_increment field
- } else {
- $param = explode(':', $parameters_total[$i-1]);
- //print_r($param);
- $fpdf[$i] = $param[3]; // fpdf = fields parameters display form
- $fpe[$i] = $param[0]; // fpe = fields parameters elements
- $fprf[$i] = $param[6]; // fprf = fields parameters required field
- if ( $param[4] == 1 ) {
- $fpmf = $fields[0]; // fpmf = fields parameters main field
- }
- }
- }
+ $tdmcreate_path = TDM_CREATE_MURL.'/'.$stl_mod_name.'/class/'.$file;
+ $root_path = XOOPS_URL.'/modules/'.$stl_mod_name.'/class/'.$file;
+ $constructor = const_fields($mod_name, $table_name, $table_fieldname, $table_fields, $language, 0, 0, 0, 0);
+ list($fpif, $fpe, $fpda, $fpdu, $fpdb, $fpmf, $fpds, $fprf) = table_fields($table_fields, $table_parameters);
//$field_id = $fields[0];
//$field_name = $fields[1];
//table_fields($table_fields);
- $form = const_fields($mod_name, $table_name, $table_fieldname, $table_category, $table_fields, $language, $fpdf, $fpe, $fprf, 1);
+ $form = const_fields($mod_name, $table_name, $table_fieldname, $table_fields, $language, $fpda, $fpe, $fprf, 1);
$ucf_mod_name_table_name = ucfirst($mod_name).ucfirst($table_name);
$lang_add = $language.strtoupper($table_fieldname).'_ADD';
$lang_edit = $language.strtoupper($table_fieldname).'_EDIT';
@@ -119,7 +93,7 @@
\$gperm_handler = &xoops_gethandler ( 'groupperm' );
\$full_list = array_keys ( \$group_list );
global \$xoopsModule;
- if (! \$this->isNew ()) {
+ if ( !\$this->isNew() ) {
\$groups_ids_approve = \$gperm_handler->getGroupIds ( '{$mod_name}_approve', \$this->getVar ( '{$fpif}' ), \$xoopsModule->getVar ( 'mid' ) );
\$groups_ids_submit = \$gperm_handler->getGroupIds ( '{$mod_name}_submit', \$this->getVar ( '{$fpif}' ), \$xoopsModule->getVar ( 'mid' ) );
\$groups_ids_view = \$gperm_handler->getGroupIds ( '{$mod_name}_view', \$this->getVar ( '{$fpif}' ), \$xoopsModule->getVar ( 'mid' ) );
Modified: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_templates_pages.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_templates_pages.php 2013-10-17 23:19:32 UTC (rev 12183)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_templates_pages.php 2013-10-17 23:40:19 UTC (rev 12184)
@@ -22,41 +22,17 @@
function const_templates_pages($modules, $table_name, $table_fieldname, $table_fields, $table_parameters)
{
$mod_name = $modules->getVar('mod_name');
+ $stl_mod_name = strtolower($mod_name);
$language = '_MA_'.strtoupper($mod_name).'_';
$file = $mod_name.'_'.$table_name.'.html';
- $tdmcreate_path = TDM_CREATE_MURL.'/'.$mod_name.'/templates/'.$file;
- $root_path = XOOPS_URL.'/modules/'.$mod_name.'/templates/'.$file;
+ $tdmcreate_path = TDM_CREATE_MURL.'/'.$stl_mod_name.'/templates/'.$file;
+ $root_path = XOOPS_URL.'/modules/'.$stl_mod_name.'/templates/'.$file;
//fields
$fields_total = explode('|', $table_fields);
$nb_fields = count($fields_total);
- //print_r($fields_total);
- //parameters
- $parameters_total = explode('|', $table_parameters);
-
- //Recuperation des parameters affichage dans le formulaire
- for($i=0; $i<$nb_fields; $i++)
- {
- $fields = explode(':', $fields_total[$i]);
- //$fields[$i] = $fields1[0];
- //Afficher dans les elements du formulaire et choisir le type
- if( $i == 0 ) {
- $fpe[$i] = '0';
- $fpdf[$i] = '0';
- $fpif = $fields[0]; // fpif = fields parameters auto_increment field
- } else {
- $param = explode(':', $parameters_total[$i-1]);
- //print_r($param);
- $fpdf[$i] = $param[3]; // fpdf = fields parameters display form
- $fpe[$i] = $param[0]; // fpe = fields parameters elements
- $fprf[$i] = $param[6]; // fprf = fields parameters required field
- if ( $param[4] == 1 ) {
- $fpmf = $fields[0]; // fpmf = fields parameters main field
- }
- }
- }
- //table_fields($table_fields);
+ list($fpif, $fpe, $fpda, $fpdu, $fpdb, $fpmf, $fpds, $fprf) = table_fields($table_fields, $table_parameters);
- $text = '<{include file="db:'.$mod_name.'_header.html"}>';
+ $text = '<{include file="db:'.$stl_mod_name.'_header.html"}>';
if($table_name != null)
{
$text .= '
@@ -66,7 +42,7 @@
';
for ($i = 0; $i < $nb_fields; $i++)
{
- $structure_fields = explode(':', $fields[$i]);
+ $structure_fields = explode(':', $fields_total[$i]);
$text .= ' <th class="center"><{$smarty.const.'.$language.strtoupper($structure_fields[0]).'}></th>
';
}
@@ -76,7 +52,7 @@
';
for ($i = 0; $i < $nb_fields; $i++)
{
- $structure_fields = explode(':', $fields[$i]);
+ $structure_fields = explode(':', $fields_total[$i]);
if( $fpe[$i] == 'XoopsFormUploadImage' ) {
$text .= ' <td class="center"><img src="<{$xoops_url}>/uploads/'.$mod_name.'/images/'.$table_name.'/<{$'.$table_fieldname.'.'.$structure_fields[0].'}>" alt="'.$table_name.'"></td>
';
|
|
From: <txm...@us...> - 2013-10-17 23:19:37
|
Revision: 12183
http://sourceforge.net/p/xoops/svn/12183
Author: txmodxoops
Date: 2013-10-17 23:19:32 +0000 (Thu, 17 Oct 2013)
Log Message:
-----------
Added function table_fields($table_fields, $table_parameters)
for delete all duplicated code in const_ files
Modified Paths:
--------------
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/include/functions_const.php
Modified: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/include/functions_const.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/include/functions_const.php 2013-10-16 20:08:52 UTC (rev 12182)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/include/functions_const.php 2013-10-17 23:19:32 UTC (rev 12183)
@@ -25,9 +25,11 @@
include_once XOOPS_ROOT_PATH.'/modules/TDMCreate/include/common.php';
include_once TDM_CREATE_URL.'/const/const_header.php';
-function const_fields($mod_name, $table_name, $table_fieldname, $table_category, $table_fields, $lng, $fpdf = 0, $fpe = 0, $fprf = 0, $option = 0)
+function const_fields($mod_name, $table_name, $table_fieldname, $table_fields, $lng, $fpda = 0, $fpe = 0, $fprf = 0, $option = 0)
{
- // fpdf = fields_param_display_form
+ // fpda = fields parameter display admin
+ // fpe = fields parameter element
+ // fprf = fields parameter required field
$mod_name = strtolower($mod_name);
$table_name = strtolower($table_name);
$table_fieldname = strtolower($table_fieldname);
@@ -76,12 +78,12 @@
}
} else if ( $option == 1 ) {
// Creation form
- for ($i=0; $i<$nb_fields; $i++)
+ for ($i=0; $i < $nb_fields; $i++)
{
if ( $i != 0 ) {
$struct = explode(':', $fields[$i]);
$lng_form = $lng.strtoupper($struct[0]);
- $text .= form_elements($i, $mod_name, $table_name, $table_fieldname, $table_category, $fpe, $fprf, $lng_form, $struct[0]);
+ $text .= form_elements($i, $mod_name, $table_name, $table_fieldname, $fpe, $fprf, $lng_form, $struct[0]);
}
}
} else if ( $option == 2 ) {
@@ -201,12 +203,12 @@
}
//
-function const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $fields_id, $nb_fields, $fields, $fpda, $fpt, $fpmf, $lng, $prefix = '', $option = 0)
+function const_show_fields_parameters($mod_name, $table_name, $table_fieldname, $nb_fields, $fields, $fields_id, $fpda, $fpe, $fpmf, $lng, $prefix = '', $option = 0)
{
$text = '';
- $mod_name = strtolower($mod_name);
- $table_name = strtolower($table_name);
- $table_fieldname = strtolower($table_fieldname);
+ $stl_mod_name = strtolower($mod_name);
+ $stl_table_name = strtolower($table_name);
+ $stl_table_fieldname = strtolower($table_fieldname);
if ( $option == 0 ) {
// Name column of the table
for($i = 0; $i < $nb_fields; $i++)
@@ -241,43 +243,43 @@
$text .= 'echo "<td class=\'left\'><img src=\'".'.strtoupper($mod_name).'_URL."/images/icons/16/arrow.gif\'> ".$'.$table_name.'_arr[$i]->getVar(\''.$fields[$i].'\')."</td>";
';
}
- } else if ( $fpt[$i] == 'XoopsFormUploadImage' ) {
+ } else if ( $fpe[$i] == 'XoopsFormUploadImage' ) {
$text .= '$image = XOOPS_UPLOAD_URL."/'.$mod_name.'/images/'.$table_name.'/".$'.$table_name.'_arr[$i]->getVar(\''.$fields[$i].'\');
echo "<td class=\'center\'><img src=\'".$image."\' height=\'30px\' alt=\''.$fields[$i].'\'></td>";
';
- } else if ( $fpt[$i] == 'XoopsFormUploadFile' )
+ } else if ( $fpe[$i] == 'XoopsFormUploadFile' )
{
$text .= 'echo "<td class=\'center\'>".$'.$table_name.'_arr[$i]->getVar(\''.$fields[$i].'\')."</td>";
';
- } else if ( $fpt[$i] == 'XoopsFormColorPicker' )
+ } else if ( $fpe[$i] == 'XoopsFormColorPicker' )
{
$text .= 'echo "<td class=\'center\'><span style=\'background-color:".$'.$table_name.'_arr[$i]->getVar(\''.$fields[$i].'\')."\'> </span> -> ".$'.$table_name.'_arr[$i]->getVar(\''.$fields[$i].'\')."</td>";
';
- } else if ( $fpt[$i] == 'XoopsFormTextDateSelect' )
+ } else if ( $fpe[$i] == 'XoopsFormTextDateSelect' )
{
$text .= 'echo "<td class=\'center\'>".formatTimeStamp($'.$table_name.'_arr[$i]->getVar(\''.$fields[$i].'\'),"S")."</td>";
';
- } else if ( $fpt[$i] == 'XoopsFormCategory' )
+ } else if ( $fpe[$i] == 'XoopsFormCategory' )
{
$text .= '$'.$table_fieldname.'1 = $categoriesHandler->get($'.$table_name.'_arr[$i]->getVar(\''.$fields[$i].'\'));
$'.$table_fieldname.'_categories1 = $'.$table_fieldname.'1->getVar(\''.$table_fieldname.'_title\');
echo "<td class=\'center\'>".$'.$table_fieldname.'_categories1."</td>";
';
- } else if ( $fpt[$i] == 'XoopsFormSelectUser' )
+ } else if ( $fpe[$i] == 'XoopsFormSelectUser' )
{
$text .= 'echo "<td class=\'center\'>".XoopsUser::getUnameFromId($'.$table_name.'_arr[$i]->getVar(\''.$fields[$i].'\'),"S")."</td>";
';
- } else if ( $fpt[$i] == 'XoopsFormText' ) {
+ } else if ( $fpe[$i] == 'XoopsFormText' ) {
$text .= 'echo "<td class=\'center\'>".$'.$table_name.'_arr[$i]->getVar(\''.$fields[$i].'\')."</td>";
';
- } else if ( $fpt[$i] == 'XoopsFormDhtmlTextArea' || $fpt[$i] == 'XoopsFormTextArea' ) {
+ } else if ( $fpe[$i] == 'XoopsFormDhtmlTextArea' || $fpe[$i] == 'XoopsFormTextArea' ) {
$text .= 'echo "<td class=\'center\'>".strip_tags($'.$table_name.'_arr[$i]->getVar(\''.$fields[$i].'\'))."</td>";
';
- } else if ( $fpt[$i] == 'XoopsFormCheckBox' || $fpt[$i] == 'XoopsFormRadioYN' ) {
+ } else if ( $fpe[$i] == 'XoopsFormCheckBox' || $fpe[$i] == 'XoopsFormRadioYN' ) {
$text .= 'echo "<td class=\'center\'>".( ($'.$table_name.'_arr[$i]->getVar(\''.$fields[$i].'\') == 1 ) ? _YES : _NO)."</td>";
';
} else {
- $data = explode("-", $fpt[$i]);
+ $data = explode("-", $fpe[$i]);
// Handler select table
$tablesHandler =& xoops_getModuleHandler('tables', 'TDMCreate');
$criteria = new CriteriaCompo();
@@ -324,18 +326,18 @@
{
if ( $i != 0 )
{
- if ( $fpt[$i] == 'XoopsFormTextDateSelect' )
+ if ( $fpe[$i] == 'XoopsFormTextDateSelect' )
{
$text .= '
- $obj->setVar(\''.$fields[$i].'\', strtotime($_REQUEST[\''.$fields[$i].'\']));';
- } else if ( $fpt[$i] == 'XoopsFormCheckBox' || $fpt[$i] == 'XoopsFormRadioYN' ) {
+ $'.$table_name.'_obj->setVar(\''.$fields[$i].'\', strtotime($_REQUEST[\''.$fields[$i].'\']));';
+ } else if ( $fpe[$i] == 'XoopsFormCheckBox' || $fpe[$i] == 'XoopsFormRadioYN' ) {
$text .= '
- $obj->setVar(\''.$fields[$i].'\', (($_REQUEST[\''.$fields[$i].'\'] == 1) ? \'1\' : \'0\'));';
- } else if ( $fpt[$i] == 'XoopsFormUploadImage' ) {
+ $'.$table_name.'_obj->setVar(\''.$fields[$i].'\', (($_REQUEST[\''.$fields[$i].'\'] == 1) ? \'1\' : \'0\'));';
+ } else if ( $fpe[$i] == 'XoopsFormUploadImage' ) {
$text .= '
include_once XOOPS_ROOT_PATH.\'/class/uploader.php\';
- $uploaddir = XOOPS_UPLOAD_PATH.\'/'.$mod_name.'/images/'.$table_name.'/\';
+ $uploaddir = XOOPS_UPLOAD_PATH.\'/'.$stl_mod_name.'/images/'.$stl_table_name.'/\';
$uploader = new XoopsMediaUploader($uploaddir, xoops_getModuleOption(\'mimetypes\', \''.$mod_name.'\'),
xoops_getModuleOption(\'maxsize\', \''.$mod_name.'\'), null, null);
if ($uploader->fetchMedia($_POST[\'xoops_upload_file\'][0])) {
@@ -345,16 +347,16 @@
$errors = $uploader->getErrors();
redirect_header(\'javascript:history.go(-1)\', 3, $errors);
} else {
- $obj->setVar(\''.$fields[$i].'\', $uploader->getSavedFileName());
+ $'.$table_name.'_obj->setVar(\''.$fields[$i].'\', $uploader->getSavedFileName());
}
} else {
- $obj->setVar(\''.$fields[$i].'\', $_REQUEST[\''.$fields[$i].'\']);
+ $'.$table_name.'_obj->setVar(\''.$fields[$i].'\', $_REQUEST[\''.$fields[$i].'\']);
}
';
- } else if ( $fpt[$i] == 'XoopsFormUploadFile' ) {
+ } else if ( $fpe[$i] == 'XoopsFormUploadFile' ) {
$text .= '
include_once XOOPS_ROOT_PATH.\'/class/uploader.php\';
- $uploaddir = XOOPS_UPLOAD_PATH.\'/'.$mod_name.'/files/'.$table_name.'/\';
+ $uploaddir = XOOPS_UPLOAD_PATH.\'/'.$stl_mod_name.'/files/'.$stl_table_name.'/\';
$uploader = new XoopsMediaUploader($uploaddir, xoops_getModuleOption(\'mimetypes\', \''.$mod_name.'\'),
xoops_getModuleOption(\'maxsize\', \''.$mod_name.'\'), null, null);
if ($uploader->fetchMedia($_POST[\'xoops_upload_file\'][0])) {
@@ -364,13 +366,13 @@
$errors = $uploader->getErrors();
redirect_header(\'javascript:history.go(-1)\', 3, $errors);
} else {
- $obj->setVar("'.$fields[$i].'", $uploader->getSavedFileName());
+ $'.$table_name.'_obj->setVar("'.$fields[$i].'", $uploader->getSavedFileName());
}
}
';
} else {
$text .= '
- $obj->setVar(\''.$fields[$i].'\', $_REQUEST[\''.$fields[$i].'\']);';
+ $'.$table_name.'_obj->setVar(\''.$fields[$i].'\', $_REQUEST[\''.$fields[$i].'\']);';
}
}
}
@@ -378,33 +380,24 @@
return $text;
}
-function form_elements($i, $mod_name, $table_name, $table_fieldname, $table_category, $fpe, $fprf, $lng_form, $struct0)
+function form_elements($i, $mod_name, $table_name, $table_fieldname, $fpe, $fprf, $lng_form, $struct0)
{
- $mod_name = strtolower($mod_name);
- $table_name = strtolower($table_name);
- $table_fieldname = strtolower($table_fieldname);
+ $stl_mod_name = strtolower($mod_name);
+ $stl_table_name = strtolower($table_name);
+ $stl_table_fieldname = strtolower($table_fieldname);
$lng = '_AM_'.strtoupper($mod_name).'_';
$required_field = ( $fprf[$i] == 1) ? 'true' : 'false';
$text = '';
- switch ($fpe[$i])
- {
- case "0":
- break;
-
- case "XoopsFormText":
- $text .= '// '.ucfirst($struct0).'
+ if ($fpe[$i] == "XoopsFormText") {
+ $text .= '// '.ucfirst($struct0).'
$form->addElement(new XoopsFormText('.$lng_form.', \''.$struct0.'\', 50, 255, $this->getVar(\''.$struct0.'\')), '.$required_field.');
';
- break;
-
- case "XoopsFormTextArea":
- $text .= '// '.ucfirst($struct0).'
+ } else if ($fpe[$i] == "XoopsFormTextArea") {
+ $text .= '// '.ucfirst($struct0).'
$form->addElement(new XoopsFormTextArea('.$lng_form.', \''.$struct0.'\', $this->getVar(\''.$struct0.'\'), 4, 47), '.$required_field.');
';
- break;
-
- case "XoopsFormDhtmlTextArea":
- $text .= '// '.ucfirst($struct0).'
+ } else if ($fpe[$i] == "XoopsFormDhtmlTextArea") {
+ $text .= '// '.ucfirst($struct0).'
$editor_configs = array();
$editor_configs[\'name\'] = \''.$struct0.'\';
$editor_configs[\'value\'] = $this->getVar(\''.$struct0.'\', \'e\');
@@ -412,31 +405,25 @@
$editor_configs[\'cols\'] = 40;
$editor_configs[\'width\'] = \'100%\';
$editor_configs[\'height\'] = \'400px\';
- $editor_configs[\'editor\'] = xoops_getModuleOption(\''.$mod_name.'_editor\', \''.$mod_name.'\');
+ $editor_configs[\'editor\'] = xoops_getModuleOption(\''.$stl_mod_name.'_editor\', \''.$mod_name.'\');
$form->addElement( new XoopsFormEditor('.$lng_form.', \''.$struct0.'\', $editor_configs), true );
';
- break;
-
- case "XoopsFormCheckBox":
+ } else if ($fpe[$i] == "XoopsFormCheckBox") {
$text .= '// '.ucfirst($struct0).'
$'.$struct0.' = $this->isNew() ? 0 : $this->getVar(\''.$struct0.'\');
$check_'.$struct0.' = new XoopsFormCheckBox('.$lng_form.', \''.$struct0.'\', $'.$struct0.');
$check_'.$struct0.'->addOption(1, " ");
$form->addElement($check_'.$struct0.');
';
- break;
-
- case "XoopsFormHidden":
- $text .= '// '.ucfirst($struct0).'
+ } else if ($fpe[$i] == "XoopsFormHidden") {
+ $text .= '// '.ucfirst($struct0).'
$form->addElement(new XoopsFormHidden(\''.$struct0.'\', $this->getVar(\''.$struct0.'\')));
';
- break;
-
- case "XoopsFormUploadImage":
- $text .= '// '.ucfirst($struct0).'
+ } else if ($fpe[$i] == "XoopsFormUploadImage") {
+ $text .= '// '.ucfirst($struct0).'
$'.$struct0.' = $this->getVar(\''.$struct0.'\') ? $this->getVar(\''.$struct0.'\') : \'blank.gif\';
- $uploadir = \'/uploads/'.$mod_name.'/images/'.$table_name.'\';
+ $uploadir = \'/uploads/'.$stl_mod_name.'/images/'.$stl_table_name.'\';
$imgtray = new XoopsFormElementTray('.$lng_form.',\'<br />\');
$imgpath = sprintf('.$lng.'FORMIMAGE_PATH, $uploadir);
$imageselect = new XoopsFormSelect($imgpath, \''.$struct0.'\', $'.$struct0.');
@@ -453,28 +440,20 @@
$imgtray->addElement($fileseltray);
$form->addElement($imgtray);
';
- break;
-
- case "XoopsFormUploadFile":
- $text .= '// '.ucfirst($struct0).'
+ } else if ($fpe[$i] == "XoopsFormUploadFile") {
+ $text .= '// '.ucfirst($struct0).'
$form->addElement(new XoopsFormFile('.$lng_form.', \''.$struct0.'\', $xoopsModuleConfig[\'maxsize\']), '.$required_field.');
';
- break;
-
- case "XoopsFormColorPicker":
- $text .= '// '.ucfirst($struct0).'
+ } else if ($fpe[$i] == "XoopsFormColorPicker") {
+ $text .= '// '.ucfirst($struct0).'
$form->addElement(new XoopsFormColorPicker('.$lng_form.', \''.$struct0.'\', $this->getVar(\''.$struct0.'\')), '.$required_field.');
';
- break;
-
- case "XoopsFormSelectUser":
- $text .= '// '.ucfirst($struct0).'
+ } else if ($fpe[$i] == "XoopsFormSelectUser") {
+ $text .= '// '.ucfirst($struct0).'
$form->addElement(new XoopsFormSelectUser('.$lng_form.', \''.$struct0.'\', false, $this->getVar(\''.$struct0.'\'), 1, false), '.$required_field.');
';
- break;
-
- case "XoopsFormCategory":
- $text .= '// '.ucfirst($struct0).'
+ } else if ($fpe[$i] == "XoopsFormCategory") {
+ $text .= '// '.ucfirst($struct0).'
include_once(XOOPS_ROOT_PATH . \'/class/tree.php\');
$categoriesHandler = xoops_getModuleHandler(\'categories\', \''.$mod_name.'\' );
$criteria = new CriteriaCompo();
@@ -485,32 +464,23 @@
$form->addElement( new XoopsFormLabel ( '.$lng_form.', $cat_pid ) );
}
';
- break;
-
- case "XoopsFormRadioYN":
- $text .= '// '.ucfirst($struct0).'
+ } else if ($fpe[$i] == "XoopsFormRadioYN") {
+ $text .= '// '.ucfirst($struct0).'
$'.$struct0.' = $this->isNew() ? 0 : $this->getVar(\''.$struct0.'\');
$form->addElement(new XoopsFormRadioYN('.$lng_form.', \''.$struct0.'\', $'.$struct0.'), '.$required_field.');
';
- break;
-
- case "XoopsFormTextDateSelect":
- $text .= '// '.ucfirst($struct0).'
+ } else if ($fpe[$i] == "XoopsFormTextDateSelect") {
+ $text .= '// '.ucfirst($struct0).'
$form->addElement(new XoopsFormTextDateSelect('.$lng_form.', \''.$struct0.'\', \'\', $this->getVar(\''.$struct0.'\')));
';
- break;
-
- case "default":
- case "XoopsFormTables-".$table_name:
- default:
- $data = explode('-', $fpe[$i]);
+ } else if ($fpe[$i] == "XoopsFormTables-".$stl_table_name) {
+ $data = explode('-', $fpe[$i]);
$text .= '// '.ucfirst($struct0).'
$'.$data[1].'Handler =& xoops_getModuleHandler(\''.$data[1].'\', \''.$mod_name.'\');
$'.$data[1].'_id_select = new XoopsFormSelect('.$lng_form.', \''.$struct0.'\', $this->getVar(\''.$struct0.'\'));
$'.$data[1].'_id_select->addOptionArray($'.$data[1].'Handler->getList());
$form->addElement($'.$data[1].'_id_select, true);
';
- break;
}
return $text;
}
@@ -524,27 +494,48 @@
//parameters
$parameters_total = explode('|', $table_parameters);
- //Recuperation des parameters affichage dans le formulaire
- for($i=0; $i<$nb_fields; $i++)
+ // Recovery of parameters display in the form
+ for($i = 0; $i < $nb_fields; $i++)
{
$fields = explode(':', $fields_total[$i]);
- //$fields[$i] = $fields1[0];
- //Afficher dans les elements du formulaire et choisir le type
+ // $fields[$i] = $fields1[0];
+ // View in the elements of the form and choose the type
if( $i == 0 ) {
+ $fpif = $fields[0]; // fpif = fields parameters auto_increment field
$fpe[$i] = '0';
- $fpdf[$i] = '0';
- $fpif = $fields[0]; // fpif = fields parameters auto_increment field
+ $fpda[$i] = '0';
+ $fpdu[$i] = '0';
+ $fpdb[$i] = '0';
+ $fpds[$i] = '0';
+ $fprf[$i] = '0';
} else {
$param = explode(':', $parameters_total[$i-1]);
- //print_r($param);
- $fpdf[$i] = $param[3]; // fpdf = fields parameters display form
- $fpe[$i] = $param[0]; // fpe = fields parameters elements
- $fprf[$i] = $param[6]; // fprf = fields parameters required field
- if ( $param[4] == 1 ) {
- $fpmf = $fields[0]; // fpmf = fields parameters main field
+ if(isset($param[0])) {
+ $fpe[$i] = $param[0]; // fpe = fields parameters elements
+ }
+ if(isset($param[1])) {
+ $fpda[$i] = $param[1]; // fpdf = fields parameters display admin
}
+ if(isset($param[2])) {
+ $fpdu[$i] = $param[2]; // fpdf = fields parameters display user
+ }
+ if(isset($param[3])) {
+ $fpdb[$i] = $param[3]; // fpdf = fields parameters display block
+ }
+ if(isset($param[4])) {
+ if ( $param[4] == 1 ) {
+ $fpmf = $fields[0]; // fpmf = fields parameters main field
+ }
+ }
+ if(isset($param[5])) {
+ $fpds[$i] = $param[5]; // fpdf = fields parameters display search
+ }
+ if(isset($param[0])) {
+ $fprf[$i] = $param[6]; // fprf = fields parameters required field
+ }
}
}
+ return array($fpif, $fpe, $fpda, $fpdu, $fpdb, $fpmf, $fpds, $fprf);
}
function search_field($fpsf, $options)
|
|
From: <luc...@us...> - 2013-10-16 20:08:56
|
Revision: 12182
http://sourceforge.net/p/xoops/svn/12182
Author: luciorota
Date: 2013-10-16 20:08:52 +0000 (Wed, 16 Oct 2013)
Log Message:
-----------
changed image position in templates
Modified Paths:
--------------
XoopsModules/wfdownloads/trunk/wfdownloads/docs/changelog.txt
XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_index.html
XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_viewcat.html
XoopsModules/wfdownloads/trunk/wfdownloads/xoops_version.php
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/docs/changelog.txt
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/docs/changelog.txt 2013-10-16 16:24:12 UTC (rev 12181)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/docs/changelog.txt 2013-10-16 20:08:52 UTC (rev 12182)
@@ -1,4 +1,4 @@
-<b><u>=> Version 3.23 Beta (2013-10-15)</u></b>
+<b><u>=> Version 3.23 Beta (2013-10-16)</u></b>
- standardization of English language files (cesag)
- fixed: typos in english folder (cesag)
- module standardization: header.php, admin/admin_header.php, xoops_version.php
@@ -14,6 +14,7 @@
- fixed: html errors in templates (luciorota)
- fixed: deprecated XoopsTree (mamba)
- fixed: English translations (mamba)
+- added: admin can upload images directly form category/indexpage form (luciorota)
- added: updating to XOOPS 2.5.7 Multi-page help (mamba)
- added: enable/disable reviews system (luciorota)
- added: enable/disable ratings system (luciorota)
@@ -23,7 +24,6 @@
- added: new auto summary option: auto summary if summary field is empty (luciorota)
- added: new auto summary option: plain text or html auto summary (luciorota)
- added: xoops/xlanguage/html tags compatible auto summary generator (luciorota)
-
- added: sort subcategories by cid or title or weight (luciorota)
- added: improved by letters choice bar (luciorota)
- added: wfdownloads_submit.html template for submit.php (luciorota)
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_index.html
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_index.html 2013-10-16 16:24:12 UTC (rev 12181)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_index.html 2013-10-16 20:08:52 UTC (rev 12182)
@@ -3,14 +3,12 @@
<{if count($categories) gt 0}>
<div>
<h3><{$smarty.const._MD_WFDOWNLOADS_MAINLISTING}></h3>
- <br/>
+ <br />
<!-- Start category loop -->
<{foreach item=category from=$categories}>
<div>
<div>
- <a href="viewcat.php?cid=<{$category.id}>">
- <img src="<{$category.image_URL}>" alt="<{$category.alttext}>" title="<{$category.alttext}>"/>
- <b><{$category.title}></b></a> (<{$category.downloads_count}>)
+ <a href="viewcat.php?cid=<{$category.id}>"><b><{$category.title}></b></a> (<{$category.downloads_count}>)
<{if $isAdmin == true}>
<a href="admin/categories.php?op=category.edit&cid=<{$category.cid}>"><img src="<{xoModuleIcons16 edit.png}>"
title="<{$smarty.const._EDIT}>"
@@ -24,6 +22,8 @@
alt="<{$smarty.const._MD_WFDOWNLOADS_SUBMITDOWNLOAD}>"/></a>
<{/if}>
</div>
+ <img src="<{$category.image_URL}>" alt="<{$category.alttext}>" title="<{$category.alttext}>"/><br />
+
<div title="<{$smarty.const._MD_WFDOWNLOADS_CSUMMARY}>">
<{$category.summary}>
</div>
@@ -37,18 +37,18 @@
</div>
<{/if}>
</div>
- <br/>
+ <br />
<{/foreach}>
<!-- End category loop -->
</div>
-<br/>
+<br />
<div>
<small><{$lang_thereare}></small>
</div>
-<br/>
+<br />
<div>
<small>
@@ -66,12 +66,12 @@
</a>
<{/if}>
-<br/>
+<br />
<div align="<{$catarray.indexfooteralign}>">
<{$catarray.indexfooter}>
</div>
-<br/>
+<br />
<{include file='db:wfdownloads_footer.html'}>
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_viewcat.html
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_viewcat.html 2013-10-16 16:24:12 UTC (rev 12181)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_viewcat.html 2013-10-16 20:08:52 UTC (rev 12182)
@@ -40,9 +40,7 @@
<{foreach item=subcategory from=$subcategories}>
<div>
<div>
- <a href="viewcat.php?cid=<{$subcategory.cid}>">
- <{if $subcategory.image_URL != ''}><img src="<{$subcategory.image_URL}>" alt="<{$subcategory.title}>" title="<{$subcategory.title}>"/> <{/if}>
- <b><{$subcategory.title}></b></a> (<{$subcategory.downloads_count}>)
+ <a href="viewcat.php?cid=<{$subcategory.cid}>"><b><{$subcategory.title}></b></a> (<{$subcategory.downloads_count}>)
<{if $isAdmin == true}>
<a href="admin/categories.php?op=category.edit&cid=<{$subcategory.cid}>"><img src="<{xoModuleIcons16 edit.png}>"
title="<{$smarty.const._EDIT}>"
@@ -57,6 +55,7 @@
alt="<{$smarty.const._MD_WFDOWNLOADS_SUBMITDOWNLOAD}>"/></a>
<{/if}>
</div>
+ <{if $subcategory.image_URL != ''}><img src="<{$subcategory.image_URL}>" alt="<{$subcategory.title}>" title="<{$subcategory.title}>"/><br /><{/if}>
<div title="<{$smarty.const._MD_WFDOWNLOADS_CSUMMARY}>">
<{$subcategory.summary}>
</div>
@@ -244,7 +243,7 @@
</div>
</div>
<{/if}>
- <br/>
+ <br />
<{$pagenav}>
<!-- Start link loop -->
<{foreach item=download from=$downloads}>
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/xoops_version.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/xoops_version.php 2013-10-16 16:24:12 UTC (rev 12181)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/xoops_version.php 2013-10-16 20:08:52 UTC (rev 12182)
@@ -42,9 +42,9 @@
$modversion['onUpdate'] = 'include/module.php';
$modversion['onUninstall'] = 'include/module.php';
-$modversion['date'] = '2013-10-15';
-$modversion['release_date'] = '2013/10/15';
-$modversion['releasedate'] = '2013-10-15';
+$modversion['date'] = '2013-10-16';
+$modversion['release_date'] = '2013/10/16';
+$modversion['releasedate'] = '2013-10-16';
$modversion['status'] = 'BETA 1';
$modversion['teammembers'] = "Bender, David, FrankBlack, Xpider, M0nty, Mithrandir, Marcan, felix[fx2024], Sudhaker, Jegelstaff";
|
|
From: <go...@us...> - 2013-10-16 16:24:15
|
Revision: 12181
http://sourceforge.net/p/xoops/svn/12181
Author: goffy
Date: 2013-10-16 16:24:12 +0000 (Wed, 16 Oct 2013)
Log Message:
-----------
transfered error text to language file (feichtl/goffy)
Modified Paths:
--------------
XoopsModules/xnewsletter/trunk/xNewsletter/admin/import.php
XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt
XoopsModules/xnewsletter/trunk/xNewsletter/docs/lang_diff.txt
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/import.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/import.php 2013-10-16 15:02:14 UTC (rev 12180)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/import.php 2013-10-16 16:24:12 UTC (rev 12181)
@@ -353,7 +353,7 @@
$pluginFile = XNEWSLETTER_PATH . "/plugins/" . $plugin . '.php';
if ( !file_exists($pluginFile) ) {
- echo "Error: File ".$plugin."' doesn't exist";
+ echo str_replace("%p", $plugin, _AM_XNEWSLETTER_IMPORT_ERROR_NO_PLUGIN);
break;
}
require_once($pluginFile);
@@ -361,6 +361,7 @@
$function = 'xnewsletter_plugin_getdata_' . $plugin;
if (!function_exists($function)) {
echo "Error: require function 'xnewsletter_plugin_getdata_".$plugin."' doesn't exist";
+ echo str_replace("%f", $plugin, _AM_XNEWSLETTER_IMPORT_ERROR_NO_FUNCTION);
break;
}
@@ -404,14 +405,14 @@
$pluginFile = XNEWSLETTER_PATH . "/plugins/" . $plugin . '.php';
if ( !file_exists($pluginFile) ) {
- echo "Error: File ".$plugin."' doesn't exist";
+ echo str_replace("%p", $plugin, _AM_XNEWSLETTER_IMPORT_ERROR_NO_PLUGIN);
break;
}
require_once($pluginFile);
$function = 'xnewsletter_plugin_getform_' . $plugin;
if (!function_exists($function) ) {
- echo "Error: require function 'xnewsletter_plugin_getform_".$plugin."' doesn't exist";
+ echo str_replace("%f", $plugin, _AM_XNEWSLETTER_IMPORT_ERROR_NO_FUNCTION);
break;
}
//$form = $function( $cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist );
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt 2013-10-16 15:02:14 UTC (rev 12180)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt 2013-10-16 16:24:12 UTC (rev 12181)
@@ -1,5 +1,6 @@
Version 1.2
--------------
+ - transfered error text to language file (feichtl/goffy)
- fixed bug when filter subscribers in admin/subscr.php (feichtl/goffy)
- french translation (pierredelu)
- corrected english language files (cesag)
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/docs/lang_diff.txt
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/docs/lang_diff.txt 2013-10-16 15:02:14 UTC (rev 12180)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/docs/lang_diff.txt 2013-10-16 16:24:12 UTC (rev 12181)
@@ -7,4 +7,11 @@
admin.php
----------
define("_AM_XNEWSLETTER_IMPORT_INFO","Add all users of a group to a newsletter");
-define("_AM_XNEWSLETTER_IMPORT_CSV","One column ( email ) or four columns ( email | sex | firstname | lastname)<br />see sample1col.csv and sample4col.csv in /plugins");
\ No newline at end of file
+define("_AM_XNEWSLETTER_IMPORT_CSV","One column ( email ) or four columns ( email | sex | firstname | lastname)<br />see sample1col.csv and sample4col.csv in /plugins");
+
+Version 1.2
+----------------
+admin.php
+----------
+define("_AM_XNEWSLETTER_IMPORT_ERROR_NO_PLUGIN","Error: required file 'plugins/%p.php' not found!");
+define("_AM_XNEWSLETTER_IMPORT_ERROR_NO_FUNCTION","Error: required function 'xnewsletter_plugin_getdata_%f' doesn't exist!");
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php 2013-10-16 15:02:14 UTC (rev 12180)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php 2013-10-16 16:24:12 UTC (rev 12181)
@@ -403,4 +403,7 @@
define("_AM_XNEWSLETTER_SUBSCR_NO_CATSUBSCR","For this e-mail-address are no subscription to newsletter cats available");
+//version 1.2
+define("_AM_XNEWSLETTER_IMPORT_ERROR_NO_PLUGIN","Error: required file 'plugins/%p.php' not found!");
+define("_AM_XNEWSLETTER_IMPORT_ERROR_NO_FUNCTION","Error: required function 'xnewsletter_plugin_getdata_%f' doesn't exist!");
?>
\ No newline at end of file
|
|
From: <go...@us...> - 2013-10-16 15:02:17
|
Revision: 12180
http://sourceforge.net/p/xoops/svn/12180
Author: goffy
Date: 2013-10-16 15:02:14 +0000 (Wed, 16 Oct 2013)
Log Message:
-----------
updated changelog.txt
fixed bug when filter subscribers in admin/subscr.php (feichtl/goffy)
Modified Paths:
--------------
XoopsModules/xnewsletter/trunk/xNewsletter/admin/subscr.php
XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/subscr.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/subscr.php 2013-10-16 12:02:34 UTC (rev 12179)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/subscr.php 2013-10-16 15:02:14 UTC (rev 12180)
@@ -106,7 +106,6 @@
$limit = $GLOBALS['xoopsModuleConfig']['adminperpage'];
$crit_subscr = new CriteriaCompo();
-
if ($op == 'apply_filter') {
if ($filter_subscr_firstname != '')
$crit_subscr->add(new Criteria("subscr_firstname",$filter_subscr_firstname,$filter_subscr));
@@ -124,7 +123,11 @@
$subscr_arr = $subscrHandler->getall($crit_subscr);
if ( $numrows > $limit ) {
include_once XOOPS_ROOT_PATH . "/class/pagenav.php";
- $pagenav = new XoopsPageNav($numrows, $limit, $start, 'start', 'op=list');
+ $linklist = "op=$op&filter_subscr=$filter_subscr";
+ $linklist .= "&filter_subscr_firstname=$filter_subscr_firstname";
+ $linklist .= "&filter_subscr_lastname=$filter_subscr_lastname";
+ $linklist .= "&filter_subscr_email=$filter_subscr_email";
+ $pagenav = new XoopsPageNav($numrows, $limit, $start, 'start', $linklist);
$pagenav = $pagenav->renderNav(4);
} else {
$pagenav = '';
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt 2013-10-16 12:02:34 UTC (rev 12179)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt 2013-10-16 15:02:14 UTC (rev 12180)
@@ -1,5 +1,20 @@
Version 1.2
--------------
+ - fixed bug when filter subscribers in admin/subscr.php (feichtl/goffy)
+ - french translation (pierredelu)
+ - corrected english language files (cesag)
+ - added plugin for import from module 'subscribers' (cesag/goffy)
+ - changed english language file from ansi to utf8 without bom, corrected translation errors (cesag/goffy)
+ - changed redirect_header from subscription.php to index.php after successful deleting a subscription (cesag/goffy)
+ - added plugin for module 'evennews' (tatane/goffy)
+ - added the possibility to show a list of subscriptions for each subscriber in admin/tab subscriber (goffy)
+ - updated help file concerning import tool (goffy)
+ - changed query to queryF to solve problems while running imports (goffy)
+ - Fix error $protocolHandler (alfred)
+ - added the possibility to search for subscriptions concerning an email, if the current user have the right to see/edit subscriptions of other persons (goffy)
+ - resize images to xoops standard 16x16 (mamba/goffy)
+ - fixed bug in showing tasklist, if email is deleted between creation of task and execution (goffy)
+ - fix sql-injection (alfred)
- Update Adminindex (alfred)
- fix userinput (alfred)
|
|
From: <go...@us...> - 2013-10-16 12:02:35
|
Revision: 12179
http://sourceforge.net/p/xoops/svn/12179
Author: goffy
Date: 2013-10-16 12:02:34 +0000 (Wed, 16 Oct 2013)
Log Message:
-----------
deleted german language files
Removed Paths:
-------------
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/
|
|
From: <go...@us...> - 2013-10-16 05:28:21
|
Revision: 12178
http://sourceforge.net/p/xoops/svn/12178
Author: goffy
Date: 2013-10-16 05:28:13 +0000 (Wed, 16 Oct 2013)
Log Message:
-----------
update to version 1.1
Modified Paths:
--------------
XoopsModules/xnewsletter/trunk/xNewsletter/admin/about.php
XoopsModules/xnewsletter/trunk/xNewsletter/admin/accounts.php
XoopsModules/xnewsletter/trunk/xNewsletter/admin/admin_header.php
XoopsModules/xnewsletter/trunk/xNewsletter/admin/bmh.php
XoopsModules/xnewsletter/trunk/xNewsletter/admin/index.php
XoopsModules/xnewsletter/trunk/xNewsletter/admin/letter.php
XoopsModules/xnewsletter/trunk/xNewsletter/admin/maintenance.php
XoopsModules/xnewsletter/trunk/xNewsletter/admin/menu.php
XoopsModules/xnewsletter/trunk/xNewsletter/admin/protocol.php
XoopsModules/xnewsletter/trunk/xNewsletter/admin/sendletter.php
XoopsModules/xnewsletter/trunk/xNewsletter/admin/subscr.php
XoopsModules/xnewsletter/trunk/xNewsletter/blocks/blocks_catsubscr.php
XoopsModules/xnewsletter/trunk/xNewsletter/blocks/blocks_letter.php
XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_accounts.php
XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_attachment.php
XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_bmh.php
XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_cat.php
XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_catsubscr.php
XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_letter.php
XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_mailinglist.php
XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_protocol.php
XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_subscr.php
XoopsModules/xnewsletter/trunk/xNewsletter/docs/changelog.txt
XoopsModules/xnewsletter/trunk/xNewsletter/docs/install.txt
XoopsModules/xnewsletter/trunk/xNewsletter/docs/lang_diff.txt
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_attachment_del.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_catsubscr_temp.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_check.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_copy.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_delete.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_details.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_edit.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_failed.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_nothing.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_ok.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_preview.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_quit.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_resend.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_send.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_sendtest.png
XoopsModules/xnewsletter/trunk/xNewsletter/include/config.php
XoopsModules/xnewsletter/trunk/xNewsletter/include/functions.php
XoopsModules/xnewsletter/trunk/xNewsletter/include/mailinglist.php
XoopsModules/xnewsletter/trunk/xNewsletter/include/onupdate.php
XoopsModules/xnewsletter/trunk/xNewsletter/include/search.inc.php
XoopsModules/xnewsletter/trunk/xNewsletter/index.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/admin.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/blocks.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/help/help.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/main.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/modinfo.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/templates/basic.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/english/templates/xoops.html
XoopsModules/xnewsletter/trunk/xNewsletter/letter.php
XoopsModules/xnewsletter/trunk/xNewsletter/protocol.php
XoopsModules/xnewsletter/trunk/xNewsletter/sendletter.php
XoopsModules/xnewsletter/trunk/xNewsletter/sql/mysql.sql
XoopsModules/xnewsletter/trunk/xNewsletter/subscription.php
XoopsModules/xnewsletter/trunk/xNewsletter/templates/blocks/xnewsletter_letter_block_day.html
XoopsModules/xnewsletter/trunk/xNewsletter/templates/blocks/xnewsletter_letter_block_random.html
XoopsModules/xnewsletter/trunk/xNewsletter/templates/blocks/xnewsletter_letter_block_recent.html
XoopsModules/xnewsletter/trunk/xNewsletter/xoops_version.php
Added Paths:
-----------
XoopsModules/xnewsletter/trunk/xNewsletter/admin/import.php
XoopsModules/xnewsletter/trunk/xNewsletter/admin/task.php
XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_import.php
XoopsModules/xnewsletter/trunk/xNewsletter/class/xNewsletter_task.php
XoopsModules/xnewsletter/trunk/xNewsletter/cron.php
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_delete_2.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_edit_2.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_import.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/icons/xn_task.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/letter_template/kletterfreaks.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/letter_template/nf_bg_green.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/letter_template/nf_bg_red.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/letter_template/nf_logo.png
XoopsModules/xnewsletter/trunk/xNewsletter/images/letter_template/nf_logo_trans.png
XoopsModules/xnewsletter/trunk/xNewsletter/include/task.inc.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/admin.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/blocks.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/help/
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/help/help.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/help/index.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/index.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/mail_template/
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/mail_template/activate.tpl
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/mail_template/delete.tpl
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/mail_template/index.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/mail_template/info_change.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/mail_template/update.tpl
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/main.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/modinfo.php
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/templates/
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/templates/basic.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/templates/index.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/templates/kletterfreaks.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/templates/naturfreunde_gruen.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/templates/naturfreunde_rot.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/templates/naturfreunde_weiss.html
XoopsModules/xnewsletter/trunk/xNewsletter/language/german/templates/xoops.html
XoopsModules/xnewsletter/trunk/xNewsletter/plugins/
XoopsModules/xnewsletter/trunk/xNewsletter/plugins/csv.php
XoopsModules/xnewsletter/trunk/xNewsletter/plugins/csv.png
XoopsModules/xnewsletter/trunk/xNewsletter/plugins/evennews.php
XoopsModules/xnewsletter/trunk/xNewsletter/plugins/rmbulletin.php
XoopsModules/xnewsletter/trunk/xNewsletter/plugins/sample1col.csv
XoopsModules/xnewsletter/trunk/xNewsletter/plugins/sample4col.csv
XoopsModules/xnewsletter/trunk/xNewsletter/plugins/smartpartner.php
XoopsModules/xnewsletter/trunk/xNewsletter/plugins/subscribers.php
XoopsModules/xnewsletter/trunk/xNewsletter/plugins/system_user.png
XoopsModules/xnewsletter/trunk/xNewsletter/plugins/weblinks.php
XoopsModules/xnewsletter/trunk/xNewsletter/plugins/xoopsuser.php
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/about.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/about.php 2013-10-15 22:20:13 UTC (rev 12177)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/about.php 2013-10-16 05:28:13 UTC (rev 12178)
@@ -31,7 +31,7 @@
//global $indexAdmin;
echo $indexAdmin->addNavigation("about.php");
-echo $indexAdmin->renderabout('6KJ7RW5DR3VTJ', false);
+echo $indexAdmin->renderabout('9P3B3FXKF868J', false);
include "admin_footer.php";
?>
\ No newline at end of file
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/accounts.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/accounts.php 2013-10-15 22:20:13 UTC (rev 12177)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/accounts.php 2013-10-16 05:28:13 UTC (rev 12178)
@@ -297,7 +297,7 @@
global $xoopsDB;
$verif_accounts_default = "1";
//reset old accounts_default
- $sql = "UPDATE `".$xoopsDB->prefix("xnewsletter_accounts")."` SET `accounts_default` = '0'";
+ $sql = "UPDATE `".$xoopsDB->prefix("mod_xnewsletter_accounts")."` SET `accounts_default` = '0'";
$result= $xoopsDB->query($sql) or die ("MySQL-Error: " . mysql_error());
} else {
$verif_accounts_default = "0";
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/admin_header.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/admin_header.php 2013-10-15 22:20:13 UTC (rev 12177)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/admin_header.php 2013-10-16 05:28:13 UTC (rev 12178)
@@ -68,6 +68,8 @@
$protocolHandler =& xoops_getModuleHandler('xNewsletter_protocol', $dirname);
$mailinglistHandler =& xoops_getModuleHandler('xNewsletter_mailinglist', $dirname);
$bmhHandler =& xoops_getModuleHandler('xNewsletter_bmh', $dirname);
+$importHandler =& xoops_getModuleHandler('xNewsletter_import', $dirname);
+$taskHandler =& xoops_getModuleHandler('xNewsletter_task', $dirname);
$myts = MyTextSanitizer::getInstance();
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/bmh.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/bmh.php 2013-10-15 22:20:13 UTC (rev 12177)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/bmh.php 2013-10-16 05:28:13 UTC (rev 12178)
@@ -46,7 +46,7 @@
$obj_bmh =& $bmhHandler->get($bmh_id);
$bmh_email = $obj_bmh->getVar("bmh_email");
- $sql = "SELECT subscr_id FROM " . $xoopsDB->prefix("xnewsletter_subscr") . " WHERE (";
+ $sql = "SELECT subscr_id FROM " . $xoopsDB->prefix("mod_xnewsletter_subscr") . " WHERE (";
$sql .= "subscr_email='" . $bmh_email . "'";
$sql .= ") LIMIT 1;";
if ( $user = $xoopsDB->query($sql) ) {
@@ -54,6 +54,10 @@
$subscr_id = intval($row_user[0]);
}
if ($subscr_id == 0) {
+ //set bmh_measure for all entries in bmh with this email
+ $sql_upd_measure = "UPDATE ".$xoopsDB->prefix("mod_xnewsletter_bmh")." SET `bmh_measure` = '"._AM_XNEWSLETTER_BMH_MEASURE_VAL_NOTHING."'";
+ $sql_upd_measure .=" WHERE ((`".$xoopsDB->prefix("mod_xnewsletter_bmh")."`.`bmh_email` ='".$bmh_email."') AND (`".$xoopsDB->prefix("mod_xnewsletter_bmh")."`.`bmh_measure` ='0'))";
+ $xoopsDB->query($sql_upd_measure);
redirect_header("bmh.php?op=list", 5, _AM_XNEWSLETTER_BMH_ERROR_NO_SUBSCRID);
}
$obj_subscr =& $subscrHandler->get($subscr_id);
@@ -63,11 +67,11 @@
$actionprot_err = $obj_subscr->getHtmlErrors()."<br/><br/><br/>";
$count_err++;
}
+
//delete subscription
$crit_catsubscr = new CriteriaCompo();
$crit_catsubscr->add(new Criteria('catsubscr_subscrid', $subscr_id));
$numrows_catsubscr = $catsubscrHandler->getCount($crit_catsubscr);
-
if ($numrows_catsubscr > 0) {
$catsubscr_arr = $catsubscrHandler->getall($crit_catsubscr);
foreach (array_keys($catsubscr_arr) as $cat) {
@@ -87,14 +91,14 @@
}
}
}
-
+
if ($count_err == 0) {
- redirect_header("bmh.php?op=handle_bmh&bmh_id=".$bmh_id."&bmh_measure="._AM_XNEWSLETTER_BMH_MEASURE_VAL_DELETE."&filter=".$filter."'", 3, _AM_XNEWSLETTER_FORMDELOK);
+ redirect_header("bmh.php?op=handle_bmh&bmh_id=".$bmh_id."&bmh_measure="._AM_XNEWSLETTER_BMH_MEASURE_VAL_DELETE."&filter=".$filter, 3, _AM_XNEWSLETTER_FORMDELOK);
} else {
echo $actionprot_err;
}
} else {
- xoops_confirm(array("ok" => 1, "bmh_id" => $bmh_id, "op" => "bmh_delsubscr", "filter" => $filter), "bmh.php", sprintf(_AM_XNEWSLETTER_BMH_MEASURE_DELETE_SURE));
+ xoops_confirm(array("ok" => 1, "bmh_id" => $bmh_id, "op" => "bmh_delsubscr", "filter" => $filter), "bmh.php", sprintf(_AM_XNEWSLETTER_BMH_MEASURE_DELETE_SURE));
}
break;
@@ -108,25 +112,25 @@
redirect_header("bmh.php?op=list&filter=".$filter."'", 3, _AM_XNEWSLETTER_BMH_MEASURE_ALREADY_DELETED);
}
+ $bmh_email = $obj_bmh->getVar("bmh_email");
+
if ($bmh_measure == _AM_XNEWSLETTER_BMH_MEASURE_VAL_QUIT) {
- $bmh_email = $obj_bmh->getVar("bmh_email");
-
- $sql = "UPDATE `".$xoopsDB->prefix("xnewsletter_subscr")."` INNER JOIN `";
- $sql .= $xoopsDB->prefix("xnewsletter_catsubscr")."` ON `subscr_id` = `catsubscr_subscrid` ";
+ $sql = "UPDATE `".$xoopsDB->prefix("mod_xnewsletter_subscr")."` INNER JOIN `";
+ $sql .= $xoopsDB->prefix("mod_xnewsletter_catsubscr")."` ON `subscr_id` = `catsubscr_subscrid` ";
$sql .= "SET `catsubscr_quited` = ".time()." WHERE (((`subscr_email`)='";
$sql .= $bmh_email. "'))";
$result= $xoopsDB->queryF($sql) or die ("MySQL-Error: " . mysql_error());
}
- //Form bmh_measure
- $obj_bmh->setVar("bmh_measure", $bmh_measure);
- //Form bmh_submitter
- $obj_bmh->setVar("bmh_submitter", $xoopsUser->uid());
- //Form bmh_created
- $obj_bmh->setVar("bmh_created", time());
+ //set bmh_measure for all entries in bmh with this email
+ $sql_upd = "UPDATE ".$xoopsDB->prefix("mod_xnewsletter_bmh")." SET ";
+ $sql_upd .="`bmh_measure` = '".$bmh_measure."'";
+ $sql_upd .=", `bmh_submitter` = '".$xoopsUser->uid()."'";
+ $sql_upd .=", `bmh_created` = '".time()."'";
+ $sql_upd .=" WHERE ((`".$xoopsDB->prefix("mod_xnewsletter_bmh")."`.`bmh_email` ='".$bmh_email."') AND (`".$xoopsDB->prefix("mod_xnewsletter_bmh")."`.`bmh_measure` ='0'))";
+ $result= $xoopsDB->queryF($sql_upd) or die ("MySQL-Error: " . mysql_error());
- if ($bmhHandler->insert($obj_bmh)) {
- redirect_header("bmh.php?op=list&filter=".$filter, 3, _AM_XNEWSLETTER_FORMOK);
- }
+ redirect_header("bmh.php?op=list&filter=".$filter, 3, _AM_XNEWSLETTER_FORMOK);
+
echo $obj_bmh->getHtmlErrors();
break;
@@ -149,7 +153,7 @@
$bmh = new BounceMailHandler();
$bmh->verbose = VERBOSE_SIMPLE; //VERBOSE_REPORT; //VERBOSE_DEBUG; //VERBOSE_QUIET; // default is VERBOSE_SIMPLE
//$bmh->use_fetchstructure = true; // true is default, no need to speficy
- //$bmh->testmode = false; // false is default, no need to specify
+ //$bmh->testmode = true; // false is default, no need to specify
//$bmh->debug_body_rule = false; // false is default, no need to specify
//$bmh->debug_dsn_rule = false; // false is default, no need to specify
//$bmh->purge_unprocessed = false; // false is default, no need to specify
Added: XoopsModules/xnewsletter/trunk/xNewsletter/admin/import.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/import.php (rev 0)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/import.php 2013-10-16 05:28:13 UTC (rev 12178)
@@ -0,0 +1,440 @@
+<?php
+/**
+ * ****************************************************************************
+ * - A Project by Developers TEAM For Xoops - ( http://www.xoops.org )
+ * ****************************************************************************
+ * XNEWSLETTER - MODULE FOR XOOPS
+ * Copyright (c) 2007 - 2012
+ * Goffy ( wedega.com )
+ *
+ * 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 Goffy ( wedega.com )
+ * @license GPL 2.0
+ * @package xNewsletter
+ * @author Goffy ( web...@we... )
+ *
+ * Version : $Id $
+ * ****************************************************************************
+ */
+
+include "admin_header.php";
+xoops_cp_header();
+
+global $xoopsUser, $xoopsDB;
+
+$basic_limit_import_checked = 100;
+$basic_limit_import_at_once = 10;
+
+$op = xNewsletter_CleanVars($_REQUEST, 'op', 'default', 'string');
+$plugin = xNewsletter_CleanVars($_REQUEST, 'plugin', 'csv', 'string');
+$cat_id = xNewsletter_CleanVars($_REQUEST, 'cat_id', 0, 'int');
+$action_after_read = xNewsletter_CleanVars($_REQUEST, 'action_after_read', 1, 'int');
+$start = xNewsletter_CleanVars($_REQUEST, 'start', 0, 'int' );
+$limitcheck = xNewsletter_CleanVars($_REQUEST, 'limitcheck', $basic_limit_import_checked, 'int' );
+$skipcatsubscrexist = xNewsletter_CleanVars($_REQUEST, 'skipcatsubscrexist', 1, 'int' );
+$check_import = xNewsletter_CleanVars($_REQUEST, 'check_import', 0, 'int');
+
+// echo "<br/>op:$op plugin:$plugin cat_id:$cat_id action_after_read:$action_after_read start:$start limitcheck:$limitcheck skipcatsubscrexist:$skipcatsubscrexist<br/><br/>";
+
+echo $indexAdmin->addNavigation("import.php");
+
+switch ($op)
+{
+ case "show_formcheck":
+
+ $indexAdmin->addItemButton(_AM_XNEWSLETTER_IMPORT_PLUGINS_AVAIL, 'import.php?op=default', 'list');
+ echo $indexAdmin->renderButton();
+
+ $importHandler =& xoops_getModuleHandler("xNewsletter_import", "xNewsletter");
+ $crit_import = new CriteriaCompo();
+ $crit_import->setSort("import_id");
+ $crit_import->setOrder("ASC");
+ $numrows = $importHandler->getCount($crit_import);
+
+ $crit_import->setStart($start);
+ $crit_import->setLimit($limitcheck);
+ $import_arr = $importHandler->getall($crit_import);
+
+ if ($numrows > 0) {
+ include_once(XOOPS_ROOT_PATH."/class/xoopsformloader.php");
+
+ $action = $_SERVER["REQUEST_URI"];
+ $unique_id = uniqid(mt_rand());
+ $form = "<br/><form name=\"form_import_".$unique_id."\" id=\"form_import_".$unique_id."\" action=\"import.php\" method=\"post\" enctype=\"multipart/form-data\">";
+
+ $showlimit = str_replace("%s", $start+1, _AM_XNEWSLETTER_IMPORT_SHOW);
+ if ($limitcheck < $numrows) {
+ $showlimit = str_replace("%l", $limitcheck, $showlimit);
+ } else {
+ $showlimit = str_replace("%l", $numrows, $showlimit);
+ }
+ $showlimit = str_replace("%n", $numrows, $showlimit);
+
+ $form .="<table width=\"100%\" cellspacing=\"1\" class=\"outer\">
+ <tr>
+ <td align=\"left\" colspan='8'>".$showlimit."</td>
+ </tr>";
+
+ $class = "odd";
+ $form .="
+ <tr>
+ <th align=\"center\"> </th>
+ <th align=\"center\">"._AM_XNEWSLETTER_SUBSCR_EMAIL."</th>
+ <th align=\"center\">"._AM_XNEWSLETTER_SUBSCR_SEX."</th>
+ <th align=\"center\">"._AM_XNEWSLETTER_SUBSCR_FIRSTNAME."</th>
+ <th align=\"center\">"._AM_XNEWSLETTER_SUBSCR_LASTNAME."</th>
+ <th align=\"center\">"._AM_XNEWSLETTER_IMPORT_EMAIL_EXIST."</th>
+ <th align=\"center\">"._AM_XNEWSLETTER_IMPORT_CATSUBSCR_EXIST."</th>
+ <th align=\"center\">"._AM_XNEWSLETTER_CAT_NAME."</th>
+ </tr>";
+
+ $class = "odd";
+ $counter = 0;
+
+ //get data for dropdown with cats
+ $catHandler =& xoops_getModuleHandler("xNewsletter_cat", "xNewsletter");
+ $criteria = new CriteriaCompo();
+ $criteria->setSort('cat_id ASC, cat_name');
+ $criteria->setOrder('ASC');
+ $cat_arr=$catHandler->getall($criteria);
+
+ foreach (array_keys($import_arr) as $i) {
+ $counter++;
+ $form .= "<tr class=\"".$class."\">";
+ $class = ($class == "even") ? "odd" : "even";
+ $form .= "<td align=\"center\">".$counter;
+ $form .= "<input type='hidden' name='import_id_".$counter."' title='import_id_".$counter."' id='import_id_".$counter."' value='".$import_arr[$i]->getVar("import_id")."' />";
+ $form .= "</td>";
+ $form .= "<td align=\"center\">";
+ $form .= "<input type='text' disabled=disabled name='email_".$counter."' title='"._AM_XNEWSLETTER_SUBSCR_EMAIL."' id='email_".$counter."' value='".$import_arr[$i]->getVar("import_email")."' />";
+ $form .= "</td>";
+
+ $form .= "<td align=\"center\">";
+ $sex = $import_arr[$i]->getVar("import_sex");
+ $form .= "<select size=\"1\" name=\"sex_".$counter."\" id=\"sex_".$counter."\" title=\""._AM_XNEWSLETTER_SUBSCR_SEX."\" ";
+ $form .= "value=\"".$sex."\">";
+ $form .= "<option value=\"\"";
+ if ($sex==_AM_XNEWSLETTER_SUBSCR_SEX_EMPTY) $form .= " selected=\"selected\"";
+ $form .= ">"._AM_XNEWSLETTER_SUBSCR_SEX_EMPTY."</option>";
+ $form .= "<option value=\""._AM_XNEWSLETTER_SUBSCR_SEX_FEMALE."\"";
+ if ($sex==_AM_XNEWSLETTER_SUBSCR_SEX_FEMALE) $form .= " selected=\"selected\"";
+ $form .= ">"._AM_XNEWSLETTER_SUBSCR_SEX_FEMALE."</option>";
+ $form .= "<option value=\""._AM_XNEWSLETTER_SUBSCR_SEX_MALE."\"";
+ if ($sex==_AM_XNEWSLETTER_SUBSCR_SEX_MALE) $form .= " selected=\"selected\"";
+ $form .= ">"._AM_XNEWSLETTER_SUBSCR_SEX_MALE."</option>";
+ $form .= "<option value=\""._AM_XNEWSLETTER_SUBSCR_SEX_COMP."\"";
+ if ($sex==_AM_XNEWSLETTER_SUBSCR_SEX_COMP) $form .= " selected=\"selected\"";
+ $form .= ">"._AM_XNEWSLETTER_SUBSCR_SEX_COMP."</option>";
+ $form .= "<option value=\""._AM_XNEWSLETTER_SUBSCR_SEX_FAMILY."\"";
+ if ($sex==_AM_XNEWSLETTER_SUBSCR_SEX_FAMILY) $form .= " selected=\"selected\"";
+ $form .= ">"._AM_XNEWSLETTER_SUBSCR_SEX_FAMILY."</option>";
+ $form .= "</select>\n";
+ $form .= "</td>";
+
+ $form .= "<td align=\"center\">";
+ $form .= "<input type='text' name='firstname_".$counter."' title='"._AM_XNEWSLETTER_SUBSCR_FIRSTNAME."' id='firstname_".$counter."' value='".$import_arr[$i]->getVar("import_firstname")."' />";
+ $form .= "</td>";
+ $form .= "<td align=\"center\">";
+ $form .= "<input type='text' name='lastname_".$counter."' title='"._AM_XNEWSLETTER_SUBSCR_LASTNAME."' id='lastname_".$counter."' value='".$import_arr[$i]->getVar("import_lastname")."' />";
+ $form .= "</td>";
+ $form .= "<td align=\"center\">";
+ $subscr_id = $import_arr[$i]->getVar("import_subscr_id");
+ $form .= "<input type='hidden' name='subscr_id_".$counter."' title='subscr_id' id='subscr_id_".$counter."' value='".$subscr_id."' />";
+ if ($subscr_id > 0) $form .= "<img src='".XNEWSLETTER_ICON."/xn_ok.png' alt='"._AM_XNEWSLETTER_IMPORT_EMAIL_EXIST."' title='"._AM_XNEWSLETTER_IMPORT_EMAIL_EXIST."' />";
+ $form .= "</td>";
+ $form .= "<td align=\"center\">";
+ $catsubscr_id = $import_arr[$i]->getVar("import_catsubscr_id");
+ $form .= "<input type='hidden' name='catsubscr_id_".$counter."' title='catsubscr_id' id='catsubscr_id_".$counter."' value='".$catsubscr_id."' />";
+ if ($catsubscr_id > 0) $form .= "<img src='".XNEWSLETTER_ICON."/xn_ok.png' alt='"._AM_XNEWSLETTER_IMPORT_CATSUBSCR_EXIST."' title='"._AM_XNEWSLETTER_IMPORT_CATSUBSCR_EXIST."' />";
+ $form .= "</td>";
+ $form .= "</td>";
+ $form .= "<td align=\"center\">";
+
+ $curr_cat_id =$import_arr[$i]->getVar("import_cat_id");
+ $form .= "<select size=\"1\" name=\"cat_id_".$counter."\" id=\"cat_id_".$counter."\" title=\"cat\" ";
+ $form .= "value=\"".$curr_cat_id."\">";
+ $cat_select = "<option value=\"0\"";
+ $cat_select .= ">"._AM_XNEWSLETTER_IMPORT_NOIMPORT."</option>";
+ foreach (array_keys($cat_arr) as $j)
+ {
+ $cat_select .= "<option value=\"".$j."\"";
+ if ($curr_cat_id == $j) $cat_select .= " selected=\"selected\"";
+ $cat_select .= ">".$cat_arr[$j]->getVar("cat_name")."</option>";
+ }
+
+ $form .= $cat_select;
+ $form .= "</select>\n";
+
+ $form .= "</td>";
+ $form .= "</tr>";
+ }
+ $form .= "<tr class=\"".$class."\">";
+ $class = ($class == "even") ? "odd" : "even";
+ $form .= "<td colspan=\"8\"align=\"center\">";
+ $form .= "<input type='hidden' name='counter' title='counter' id='counter' value='".$counter."' />";
+ $form .= "<input type='hidden' name='limitcheck' title='limitcheck' id='limitcheck' value='".$limitcheck."' />";
+ $form .= "<input type='hidden' name='op' title='op' id='op' value='apply_import_form' />";
+ $form .= "<input type='submit' class='formButton' name='submit' id='submit' value='"._AM_XNEWSLETTER_IMPORT_EXEC."' title='"._AM_XNEWSLETTER_IMPORT_EXEC."' />";
+ $form .= "</td></tr>";
+
+ $form .= "</table></form>";
+ echo $form;
+ }
+ break;
+
+ case "apply_import_form":
+ //update mod_xnewsletter with settings form_import
+ $counter = xNewsletter_CleanVars($_REQUEST, 'counter', 0, 'int');
+
+ for ($i=1; $i < ($counter+1); $i++) {
+ $import_id = xNewsletter_CleanVars($_REQUEST, 'import_id_'.$i, 'default', 'string');
+ $subscr_firstname = xNewsletter_CleanVars($_REQUEST, 'firstname_'.$i, '', 'string');
+ $subscr_lastname = xNewsletter_CleanVars($_REQUEST, 'lastname_'.$i, '', 'string');
+ $subscr_sex = xNewsletter_CleanVars($_REQUEST, 'sex_'.$i, '', 'string');
+ $cat_id = xNewsletter_CleanVars($_REQUEST, 'cat_id_'.$i, 0, 'int');
+
+ if ($cat_id > 0) {
+ if ($subscr_id==0) {
+ //update sex, firstname, lastname
+ $sql = "UPDATE ".$xoopsDB->prefix('mod_xnewsletter_import')." SET `import_sex`='$subscr_sex', `import_firstname`='$subscr_firstname', `import_lastname`='$subscr_lastname' WHERE `import_id`=$import_id";
+ $result=$xoopsDB->queryF($sql);
+ }
+ }
+ //update cat_id and import_status
+ $sql = "UPDATE ".$xoopsDB->prefix('mod_xnewsletter_import')." SET `import_cat_id`='$cat_id', `import_status`=1 WHERE `import_id`=$import_id";
+ $result=$xoopsDB->queryF($sql);
+ }
+
+ redirect_header("import.php?op=exec_import_final&check_import=1&limitcheck=".$limitcheck, 0, "");
+ break;
+
+ case "exec_import_final":
+
+ //execute final import of all data from mod_xnewsletter_import, where import_status = 1
+ //delete data from mod_xnewsletter_import, when imported (successful or not)
+ $indexAdmin->addItemButton(_AM_XNEWSLETTER_IMPORT_PLUGINS_AVAIL, 'import.php?op=default', 'list');
+ echo $indexAdmin->renderButton();
+
+ $ip = xoops_getenv("REMOTE_ADDR");
+ $submitter = $xoopsUser->uid();
+
+ $crit_import = new CriteriaCompo();
+ $crit_import->add(new Criteria('import_status', "1"));
+ $numrows_total = $importHandler->getCount();
+ $numrows_act = $importHandler->getCount($crit_import);
+ if ( $numrows_act > 0 ) {
+ $sql = "SELECT * FROM ".$xoopsDB->prefix("mod_xnewsletter_import")." WHERE ((import_status)=1)";
+ $sql .= " ORDER BY `import_id` ASC";
+ $counter = 0;
+ $users_import = $xoopsDB->queryF($sql) or die ("MySQL-Error: " . mysql_error());
+ while ($user_import = mysql_fetch_assoc($users_import)) {
+ $import_id = $user_import["import_id"];
+ $subscr_email = $user_import["import_email"];
+ $subscr_firstname = $user_import["import_firstname"];
+ $subscr_lastname = $user_import["import_lastname"];
+ $subscr_sex = $user_import["import_sex"];
+ $cat_id = $user_import["import_cat_id"];
+ $subscr_id = $user_import["import_subscr_id"];
+ $catsubscr_id = $user_import["import_catsubscr_id"];
+ $subscribe = 0;
+
+ if ($cat_id == 0) {
+ create_prot ( str_replace("%e", $subscr_email, _AM_XNEWSLETTER_IMPORT_RESULT_SKIP), 1, $submitter);
+ } else {
+ //register email
+ if ($subscr_id==0) {
+ $subscr_uid = 0;
+ $sql = "SELECT `uid` FROM ".$xoopsDB->prefix("users")." WHERE (`email`='";
+ $sql .= $subscr_email;
+ $sql .= "') LIMIT 1";
+ if ( $user = $xoopsDB->queryF($sql) ) {
+ $row_user = mysql_fetch_array($user);
+ $subscr_uid = $row_user[0];
+ }
+ unset($row_user);
+ unset($user);
+
+ $sql = "INSERT INTO `".$xoopsDB->prefix('mod_xnewsletter_subscr')."` (`subscr_email`, `subscr_firstname`, `subscr_lastname`, `subscr_uid`, `subscr_sex`, `subscr_submitter`, `subscr_created`, `subscr_ip`, `subscr_activated`, `subscr_actoptions`) VALUES ('".$subscr_email."','".$subscr_firstname."','".$subscr_lastname."',".intval($subscr_uid).",'".$subscr_sex."',".$submitter.",".time().",'".$ip."','1','')";
+ if (!$xoopsDB->queryF($sql)) {
+ create_prot ( str_replace("%e", $subscr_email, _AM_XNEWSLETTER_IMPORT_RESULT_FAILED), 0, $submitter);
+ } else {
+ //register email successful
+ $resulttext = $subscr_email.": "._AM_XNEWSLETTER_IMPORT_RESULT_REG_OK." | ";
+ $subscr_id = $xoopsDB->getInsertId();
+ $subscribe=1;
+ }
+
+ } else {
+ //email already registered
+ $resulttext = $subscr_email.": "._AM_XNEWSLETTER_IMPORT_EMAIL_EXIST." | ";
+ $subscribe=1;
+ }
+ if ($subscribe == 1) {
+ if ($catsubscr_id==0) {
+ //add subscription of this email
+ $sql = "INSERT INTO `".$xoopsDB->prefix('mod_xnewsletter_catsubscr')."` (`catsubscr_catid`, `catsubscr_subscrid`, `catsubscr_submitter`, `catsubscr_created`) VALUES (".$cat_id.",".$subscr_id.",".$submitter.",".time().")";
+ if ($xoopsDB->queryF($sql)) {
+ create_prot ( $resulttext._AM_XNEWSLETTER_IMPORT_RESULT_SUBSCR_OK, 1, $submitter);
+ //handle mailinglists
+ $cat_mailinglist = 0;
+ $sql = "SELECT `cat_mailinglist` FROM ".$xoopsDB->prefix("mod_xnewsletter_cat")." WHERE (`cat_id`=";
+ $sql .= $cat_id;
+ $sql .= ") LIMIT 1";
+ if ( $cat_mls = $xoopsDB->queryF($sql) ) {
+ $cat_ml = mysql_fetch_array($cat_mls);
+ $cat_mailinglist = $cat_ml[0];
+ }
+ unset($cat_ml);
+ unset($cat_mls);
+
+ if ($cat_mailinglist > 0) {
+ require_once( XOOPS_ROOT_PATH."/modules/xNewsletter/include/mailinglist.php" );
+ subscribingMLHandler(1, $subscr_id, $cat_mailinglist);
+ }
+ } else {
+ create_prot ( str_replace("%e", $subscr_email, _AM_XNEWSLETTER_IMPORT_RESULT_FAILED), 0, $submitter);
+ }
+ } else {
+ create_prot ( $resulttext._AM_XNEWSLETTER_IMPORT_CATSUBSCR_EXIST, 1, $submitter);
+ }
+ }
+ }
+ $sql_del = "DELETE FROM ".$xoopsDB->prefix('mod_xnewsletter_import')." WHERE `import_id`=".$import_id;
+ $result = $xoopsDB->queryF($sql_del);
+ }
+
+ echo "<div style='margin-top:20px;margin-bottom:20px;color:#ff0000;font-weight:bold;font-size:14px'>";
+ $img_ok = "<img src='".XNEWSLETTER_ICON."/xn_ok.png' alt='"._AM_XNEWSLETTER_OK."' title='"._AM_XNEWSLETTER_OK."' /> ";
+ $resulttext = str_replace("%p", $numrows_act ,_AM_XNEWSLETTER_IMPORT_FINISHED);
+ $resulttext = str_replace("%t", $numrows_total ,$resulttext);
+ echo $img_ok.$resulttext;
+ echo "</div>";
+
+ $numrows_pend = $importHandler->getCount();
+ if ($numrows_pend > 0) {
+ $form_continue = "<form id='form_continue' enctype='multipart/form-data' method='post' action='import.php' name='form_continue'>";
+ $form_continue .= "<input id='submit' class='formButton' type='submit' title='"._AM_XNEWSLETTER_IMPORT_CONTINUE."' value='"._AM_XNEWSLETTER_IMPORT_CONTINUE."' name='submit'>";
+ $form_continue .= '<input id="limitcheck" type="hidden" value="'.$limitcheck.'" name="limitcheck">';
+ if ($check_import==1) {
+ //show next form for check settings
+ $form_continue .= '<input id="op" type="hidden" value="show_formcheck" name="op">';
+ } else {
+ // set import_status = 1 for next package
+ $sql_update = "UPDATE ".$xoopsDB->prefix("mod_xnewsletter_import")." SET `import_status`=1 ORDER BY import_id LIMIT ".$limitcheck;
+ $xoopsDB->queryF($sql_update);
+ //execute import for the next package
+ $form_continue .= '<input id="op" type="hidden" value="exec_import_final" name="op">';
+ }
+ $form_continue .= '<input id="action_after_read" type="hidden" value="'.$action_after_read.'" name="action_after_read">';
+ $form_continue .= '<input id="limitcheck" type="hidden" value="'.$limitcheck.'" name="limitcheck">';
+ $form_continue .= '<input id="plugin" type="hidden" value="'.$plugin.'" name="plugin">';
+ $form_continue .= '<input id="check_import" type="hidden" value="'.$check_import.'" name="check_import">';
+ $form_continue .= "</form>";
+ echo $form_continue;
+ }
+ } else {
+ echo _AM_XNEWSLETTER_IMPORT_NODATA;
+ }
+ break;
+
+ case "searchdata":
+ //delete all existing data, import data into mod_xnewsletter_import with plugin
+ //set cat_id as preselected, update information about existing registration/subscriptions
+ //if ($action_after_read==1) execute import else show form for check before executing import
+
+ $pluginFile = XNEWSLETTER_PATH . "/plugins/" . $plugin . '.php';
+ if ( !file_exists($pluginFile) ) {
+ echo "Error: File ".$plugin."' doesn't exist";
+ break;
+ }
+ require_once($pluginFile);
+
+ $function = 'xnewsletter_plugin_getdata_' . $plugin;
+ if (!function_exists($function)) {
+ echo "Error: require function 'xnewsletter_plugin_getdata_".$plugin."' doesn't exist";
+ break;
+ }
+
+ //delete all existing data
+ $sql = "TRUNCATE TABLE ".$xoopsDB->prefix('mod_xnewsletter_import');
+ $result=$xoopsDB->queryF($sql);
+
+ //import data into mod_xnewsletter_import with plugin
+ if ($plugin == 'csv') {
+ $csv_file = $_FILES['csv_file']['tmp_name'];
+ $csv_header = xNewsletter_CleanVars($_REQUEST, 'csv_header', 0, 'int');
+ $csv_delimiter = xNewsletter_CleanVars($_REQUEST, 'csv_delimiter', ',', 'string');
+ //$numData = $function($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist, $csv_file, $csv_delimiter, $csv_header);
+ $numData = call_user_func($function, $cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist, $csv_file, $csv_delimiter, $csv_header);
+ } else if ($plugin == 'xoopsuser') {
+ $arr_groups = $_POST["xoopsuser_group"];
+ //$numData = $function($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist, $arr_groups);
+ $numData = call_user_func($function, $cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist, $arr_groups);
+ } else {
+ //$numData = $function($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist);
+ $numData = call_user_func($function, $cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist);
+ }
+
+ if ($numData > 0) {
+ if ($action_after_read==0) {
+ //execute import without check
+ redirect_header("import.php?op=exec_import_final&action_after_read=0&limitcheck=".$limitcheck, 0, "");
+ } else {
+ //show form for check before executing import
+ redirect_header("import.php?op=show_formcheck&action_after_read=1&plugin=".$plugin."&limitcheck=".$limitcheck, 0, "");
+ }
+ } else {
+ redirect_header("import.php", 3, _AM_XNEWSLETTER_IMPORT_NODATA);
+ }
+ break;
+
+ case "form_additional":
+ //show form for additional settings
+ $indexAdmin->addItemButton(_AM_XNEWSLETTER_IMPORT_PLUGINS_AVAIL, 'import.php?op=default', 'list');
+ echo $indexAdmin->renderButton();
+
+ $pluginFile = XNEWSLETTER_PATH . "/plugins/" . $plugin . '.php';
+ if ( !file_exists($pluginFile) ) {
+ echo "Error: File ".$plugin."' doesn't exist";
+ break;
+ }
+ require_once($pluginFile);
+
+ $function = 'xnewsletter_plugin_getform_' . $plugin;
+ if (!function_exists($function) ) {
+ echo "Error: require function 'xnewsletter_plugin_getform_".$plugin."' doesn't exist";
+ break;
+ }
+ //$form = $function( $cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist );
+ $form = call_user_func($function, $cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist );
+ $form->display();
+ break;
+
+ case "default":
+ default:
+ //show basic search form
+ $objImport =& $importHandler->create();
+ $form = $objImport->getFormSearch($plugin, $action_after_read, $limitcheck);
+ $form->display();
+ break;
+}
+include "admin_footer.php";
+
+function create_prot ( $prot_text, $success, $submitter) {
+ global $xoopsDB;
+
+ $sql = "INSERT INTO `".$xoopsDB->prefix('mod_xnewsletter_protocol')."` (`protocol_letter_id`, `protocol_subscriber_id`, `protocol_status`, `protocol_success`, `protocol_submitter`, `protocol_created`) VALUES (0,0,'".$prot_text."',".$success.", ".$submitter.",".time().")";
+ $xoopsDB->queryF($sql) or die ("MySQL-Error: " . mysql_error());
+
+}
+
+?>
\ No newline at end of file
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/index.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/index.php 2013-10-15 22:20:13 UTC (rev 12177)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/index.php 2013-10-16 05:28:13 UTC (rev 12178)
@@ -32,67 +32,46 @@
//global $indexAdmin;
global $xoopsModuleConfig;
- //count "total"
+ //count "total"
$count_accounts = $accountsHandler->getCount();
-
- //count "total"
$count_cat = $catHandler->getCount();
-
- //count "total"
$count_subscr = $subscrHandler->getCount();
-
- //count "total"
$count_catsubscr = $catsubscrHandler->getCount();
-
- //count "total"
$count_letter = $letterHandler->getCount();
-
- //count "total"
$count_protocol = $protocolHandler->getCount();
-
- //count "total"
$count_attachment = $attachmentHandler->getCount();
-
if (isset($xoopsModuleConfig['xn_use_mailinglist']) && $xoopsModuleConfig['xn_use_mailinglist'] == 1) {
- //count "total"
$count_mailinglist = $mailinglistHandler->getCount();
}
-
- //count "total"
$count_bmh = $bmhHandler->getCount();
+ if (isset($xoopsModuleConfig['xn_send_in_packages']) && $xoopsModuleConfig['xn_send_in_packages'] > 0) {
+ $count_task = $taskHandler->getCount();
+ }
+
$r = '#FF0000'; // Red
$g = '#00AA00'; // Green
- $indexAdmin->addInfoBox(_AM_XNEWSLETTER_ACCOUNTS);
- $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_ACCOUNTS,_AM_XNEWSLETTER_THEREARE_ACCOUNTS, $count_accounts, ($count_accounts == 0) ? $r : $g);
-
- $indexAdmin->addInfoBox(_AM_XNEWSLETTER_CAT);
- $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_CAT,_AM_XNEWSLETTER_THEREARE_CAT, $count_cat, ($count_cat == 0) ? $r : $g);
-
- $indexAdmin->addInfoBox(_AM_XNEWSLETTER_SUBSCR);
- $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_SUBSCR,_AM_XNEWSLETTER_THEREARE_SUBSCR, $count_subscr, ($count_subscr == 0) ? $r : $g);
-
- $indexAdmin->addInfoBox(_AM_XNEWSLETTER_CATSUBSCR);
- $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_CATSUBSCR,_AM_XNEWSLETTER_THEREARE_CATSUBSCR, $count_catsubscr, ($count_catsubscr == 0) ? $r : $g);
-
- $indexAdmin->addInfoBox(_AM_XNEWSLETTER_LETTER);
- $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_LETTER,_AM_XNEWSLETTER_THEREARE_LETTER, $count_letter, ($count_letter == 0) ? $r : $g);
+ $indexAdmin->addInfoBox(_AM_XNEWSLETTER_LETTER);
- $indexAdmin->addInfoBox(_AM_XNEWSLETTER_ATTACHMENT);
- $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_ATTACHMENT,_AM_XNEWSLETTER_THEREARE_ATTACHMENT, $count_attachment, ($count_attachment == 0) ? $r : $g);
-
- $indexAdmin->addInfoBox(_AM_XNEWSLETTER_PROTOCOL);
- $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_PROTOCOL,_AM_XNEWSLETTER_THEREARE_PROTOCOL, $count_protocol, ($count_protocol == 0) ? $r : $g);
+ $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_LETTER,_AM_XNEWSLETTER_THEREARE_ACCOUNTS, $count_accounts, ($count_accounts == 0) ? $r : $g);
+ $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_LETTER,_AM_XNEWSLETTER_THEREARE_CAT, $count_cat, ($count_cat == 0) ? $r : $g);
+ $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_LETTER,_AM_XNEWSLETTER_THEREARE_SUBSCR, $count_subscr, ($count_subscr == 0) ? $r : $g);
+ $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_LETTER,_AM_XNEWSLETTER_THEREARE_CATSUBSCR, $count_catsubscr, ($count_catsubscr == 0) ? $r : $g);
+ $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_LETTER,_AM_XNEWSLETTER_THEREARE_LETTER, $count_letter, ($count_letter == 0) ? $r : $g);
+ $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_LETTER,_AM_XNEWSLETTER_THEREARE_ATTACHMENT, $count_attachment, ($count_attachment == 0) ? $r : $g);
+ $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_LETTER,_AM_XNEWSLETTER_THEREARE_PROTOCOL, $count_protocol, ($count_protocol == 0) ? $r : $g);
if (isset($xoopsModuleConfig['xn_use_mailinglist']) && $xoopsModuleConfig['xn_use_mailinglist'] == 1) {
- $indexAdmin->addInfoBox(_AM_XNEWSLETTER_MAILINGLIST);
- $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_MAILINGLIST,_AM_XNEWSLETTER_THEREARE_MAILINGLIST, $count_mailinglist, ($count_mailinglist == 0) ? $r : $g);
+ $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_LETTER,_AM_XNEWSLETTER_THEREARE_MAILINGLIST, $count_mailinglist, ($count_mailinglist == 0) ? $r : $g);
}
+
+ if (isset($xoopsModuleConfig['xn_send_in_packages']) && $xoopsModuleConfig['xn_send_in_packages'] > 0) {
+ $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_LETTER,_AM_XNEWSLETTER_THEREARE_TASK, $count_task, ($count_task == 0) ? $r : $g);
+ }
- $indexAdmin->addInfoBox(_AM_XNEWSLETTER_BMH);
- $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_BMH,_AM_XNEWSLETTER_THEREARE_BMH, $count_bmh, ($count_bmh == 0) ? $r : $g);
-
+ $indexAdmin->addInfoBoxLine(_AM_XNEWSLETTER_LETTER,_AM_XNEWSLETTER_THEREARE_BMH, $count_bmh, ($count_bmh == 0) ? $r : $g);
+
echo $indexAdmin->addNavigation("index.php") ;
echo $indexAdmin->renderIndex();
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/letter.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/letter.php 2013-10-15 22:20:13 UTC (rev 12177)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/letter.php 2013-10-16 05:28:13 UTC (rev 12178)
@@ -411,7 +411,7 @@
if ($letterHandler->delete($obj_letter)) {
//delete protocol
- $sql = "DELETE FROM `".$xoopsDB->prefix("xnewsletter_protocol")."` WHERE `protocol_letter_id`=".$letter_id;
+ $sql = "DELETE FROM `".$xoopsDB->prefix("mod_xnewsletter_protocol")."` WHERE `protocol_letter_id`=".$letter_id;
$result = $xoopsDB->query($sql) or die("MySQL-Error: " . mysql_error());
//delete attachments
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/maintenance.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/maintenance.php 2013-10-15 22:20:13 UTC (rev 12177)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/maintenance.php 2013-10-16 05:28:13 UTC (rev 12178)
@@ -99,31 +99,50 @@
// check module preference xn_use_mailinglist with values in cat_mailinglist
// and check cat_mailinglist versus table mailinglist
+ global $xoopsModuleConfig;
+ if (isset($xoopsModuleConfig['xn_use_mailinglist']) && $xoopsModuleConfig['xn_use_mailinglist'] == 1) {
+ echo " <tr class='".$class."'>";
+ $class = ($class == "even") ? "odd" : "even";
+ echo " <form action='maintenance.php' method='post'>";
+ echo " <td align='center' valign='middle'>ml</td>";
+ echo " <td align='left' valign='middle'>" . _AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML . "</td>";
+ echo " <td valign='middle' align='center'> ";
+ echo " </td><td valign='middle' align='left'>";
+ $cal_tray = new XoopsFormElementTray(" ",' ');
+ $cal_tray->addElement(new XoopsFormHidden("op", "del_invalid_ml"));
+ $cal_tray->addElement(new XoopsFormButton("", "post", _SUBMIT, "submit"));
+ echo $cal_tray->render();
+ echo " </td>";
+ echo " </form>";
+ echo " </tr>";
+ }
+
+ // delete invalid cat
echo " <tr class='".$class."'>";
$class = ($class == "even") ? "odd" : "even";
echo " <form action='maintenance.php' method='post'>";
- echo " <td align='center' valign='middle'>ml</td>";
- echo " <td align='left' valign='middle'>" . _AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_ML . "</td>";
+ echo " <td align='center' valign='middle'>cat</td>";
+ echo " <td align='left' valign='middle'>" . _AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_CATNL . "</td>";
echo " <td valign='middle' align='center'> ";
echo " </td><td valign='middle' align='left'>";
$cal_tray = new XoopsFormElementTray(" ",' ');
- $cal_tray->addElement(new XoopsFormHidden("op", "del_invalid_ml"));
+ $cal_tray->addElement(new XoopsFormHidden("op", "del_invalid_cat"));
$cal_tray->addElement(new XoopsFormButton("", "post", _SUBMIT, "submit"));
echo $cal_tray->render();
echo " </td>";
echo " </form>";
echo " </tr>";
- // delete invalid cat
+ // delete import
echo " <tr class='".$class."'>";
$class = ($class == "even") ? "odd" : "even";
echo " <form action='maintenance.php' method='post'>";
- echo " <td align='center' valign='middle'>cat</td>";
- echo " <td align='left' valign='middle'>" . _AM_XNEWSLETTER_MAINTENANCE_DELETE_INVALID_CATNL . "</td>";
+ echo " <td align='center' valign='middle'>import</td>";
+ echo " <td align='left' valign='middle'>" . _AM_XNEWSLETTER_MAINTENANCE_DELETE_IMPORT . "</td>";
echo " <td valign='middle' align='center'> ";
echo " </td><td valign='middle' align='left'>";
$cal_tray = new XoopsFormElementTray(" ",' ');
- $cal_tray->addElement(new XoopsFormHidden("op", "del_invalid_cat"));
+ $cal_tray->addElement(new XoopsFormHidden("op", "del_import"));
$cal_tray->addElement(new XoopsFormButton("", "post", _SUBMIT, "submit"));
echo $cal_tray->render();
echo " </td>";
@@ -133,6 +152,40 @@
echo "</table>";
break;
+ case 'del_import':
+
+ if (isset($_POST["ok"]) && $_POST["ok"] == "1") {
+ $sql = "TRUNCATE TABLE `".$xoopsDB->prefix('mod_xnewsletter_import')."`";
+ $result = $xoopsDB->queryF($sql);
+ $sql = "REPAIR TABLE `".$xoopsDB->prefix('mod_xnewsletter_import')."`";
+ $result = $xoopsDB->queryF($sql);
+ $sql = "OPTIMIZE TABLE `".$xoopsDB->prefix('mod_xnewsletter_import')."`";
+ $result = $xoopsDB->queryF($sql);
+ $sql = "ALTER TABLE `".$xoopsDB->prefix('mod_xnewsletter_import')."` AUTO_INCREMENT =1";
+ $result = $xoopsDB->queryF($sql);
+
+ $obj =& $protocolHandler->create();
+ //Form protocol_letter_id
+ $obj->setVar("protocol_letter_id", 0);
+ //Form protocol_subscriber_id
+ $obj->setVar("protocol_subscriber_id", 0);
+ //Form protocol_status
+ $obj->setVar("protocol_status", "[" . _MI_XNEWSLETTER_ADMENU11 . " import] " . _AM_XNEWSLETTER_MAINTENANCE_DELETE_IMPORT_OK);
+ //Form protocol_success
+ $obj->setVar("protocol_success", 1);
+ //Form protocol_submitter
+ $obj->setVar("protocol_submitter", $GLOBALS['xoopsUser']->uid());
+ //Form protocol_created
+ $obj->setVar("protocol_created", time());
+
+ if (!$protocolHandler->insert($obj)) {
+ }
+ redirect_header("maintenance.php", 2,_AM_XNEWSLETTER_MAINTENANCE_DELETE_IMPORT_OK);
+ } else {
+ xoops_confirm(array("ok" => 1, "", "op" => "del_import"), "maintenance.php", _AM_XNEWSLETTER_MAINTENANCE_DELETE_IMPORT);
+ }
+ break;
+
case 'del_olduser':
$time = strtotime($_POST['del_date']);
if ( $time >= time() || $time == 0) {
@@ -150,11 +203,11 @@
$delusers = $subscrHandler->getall($criteria, array('subscr_id'), false, false);
foreach ($delusers as $id => $user) {
$obj =& $subscrHandler->get(intval($user['subscr_id']));
- $sql = "DELETE FROM `".$xoopsDB->prefix('xnewsletter_subscr')."` WHERE subscr_id=" . $user['subscr_id'];
+ $sql = "DELETE FROM `".$xoopsDB->prefix('mod_xnewsletter_subscr')."` WHERE subscr_id=" . $user['subscr_id'];
$result = $xoopsDB->queryF($sql);
if ($result) {
// Newsletterlist delete
- $sql = "DELETE FROM `".$xoopsDB->prefix('xnewsletter_catsubscr')."` WHERE catsubscr_subscrid=" . $user['subscr_id'];
+ $sql = "DELETE FROM `".$xoopsDB->prefix('mod_xnewsletter_catsubscr')."` WHERE catsubscr_subscrid=" . $user['subscr_id'];
$result = $xoopsDB->queryF($sql);
if (!$result) {
$error[] = "Error CAT-Subscr-ID: " . $user['subscr_id'] . " / " . $result->getHtmlErrors();
@@ -203,13 +256,13 @@
case 'del_oldprotocol':
if (isset($_POST["ok"]) && $_POST["ok"] == "1") {
- $sql = "TRUNCATE TABLE `".$xoopsDB->prefix('xnewsletter_protocol')."`";
+ $sql = "TRUNCATE TABLE `".$xoopsDB->prefix('mod_xnewsletter_protocol')."`";
$result = $xoopsDB->queryF($sql);
- $sql = "REPAIR TABLE `".$xoopsDB->prefix('xnewsletter_protocol')."`";
+ $sql = "REPAIR TABLE `".$xoopsDB->prefix('mod_xnewsletter_protocol')."`";
$result = $xoopsDB->queryF($sql);
- $sql = "OPTIMIZE TABLE `".$xoopsDB->prefix('xnewsletter_protocol')."`";
+ $sql = "OPTIMIZE TABLE `".$xoopsDB->prefix('mod_xnewsletter_protocol')."`";
$result = $xoopsDB->queryF($sql);
- $sql = "ALTER TABLE `".$xoopsDB->prefix('xnewsletter_protocol')."` AUTO_INCREMENT =1";
+ $sql = "ALTER TABLE `".$xoopsDB->prefix('mod_xnewsletter_protocol')."` AUTO_INCREMENT =1";
$result = $xoopsDB->queryF($sql);
$obj =& $protocolHandler->create();
@@ -241,13 +294,13 @@
$number_ids = 0;
$delete = 0;
$error = array();
- $sql = "SELECT Count(`catsubscr_id`) AS `nb_ids` FROM `".$xoopsDB->prefix("xnewsletter_catsubscr")."` LEFT JOIN `".$xoopsDB->prefix("xnewsletter_subscr")."` ON `catsubscr_subscrid` = `subscr_id` WHERE (`subscr_id` Is Null)";
+ $sql = "SELECT Count(`catsubscr_id`) AS `nb_ids` FROM `".$xoopsDB->prefix("mod_xnewsletter_catsubscr")."` LEFT JOIN `".$xoopsDB->prefix("mod_xnewsletter_subscr")."` ON `catsubscr_subscrid` = `subscr_id` WHERE (`subscr_id` Is Null)";
if ( $result = $xoopsDB->query($sql) ) {
$row_result = $xoopsDB->fetchRow($result);
$number_ids = $row_result[0];
}
if ($number_ids > 0) {
- $sql = "DELETE FROM `".$xoopsDB->prefix("xnewsletter_catsubscr")."` LEFT JOIN `".$xoopsDB->prefix("xnewsletter_subscr")."` ON `catsubscr_subscrid` = `subscr_id` WHERE (`subscr_id` Is Null)";
+ $sql = "DELETE `".$xoopsDB->prefix("mod_xnewsletter_catsubscr")."` FROM `".$xoopsDB->prefix("mod_xnewsletter_catsubscr")."` LEFT JOIN `".$xoopsDB->prefix("mod_xnewsletter_subscr")."` ON `catsubscr_subscrid` = `subscr_id` WHERE (`subscr_id` Is Null)";
$result = $xoopsDB->query($sql);
if ($result = $xoopsDB->query($sql)) {
$delete++;
@@ -299,13 +352,13 @@
$error = array();
if ($use_mailinglist == 0 || $use_mailinglist == '0') {
//set cat_mailinglist = 0, if use mailinglist = false (if someone changed module preferences later)
- $sql = "SELECT Count(`cat_id`) AS `nb_ids` FROM `".$xoopsDB->prefix("xnewsletter_cat")."` WHERE (`cat_mailinglist` > 0)";
+ $sql = "SELECT Count(`cat_id`) AS `nb_ids` FROM `".$xoopsDB->prefix("mod_xnewsletter_cat")."` WHERE (`cat_mailinglist` > 0)";
if ( $result = $xoopsDB->query($sql) ) {
$row_result = $xoopsDB->fetchRow($result);
$number_ids = $row_result[0];
}
if ($number_ids > 0) {
- $sql = "UPDATE `".$xoopsDB->prefix("xnewsletter_cat")."` SET `cat_mailinglist` = 0";
+ $sql = "UPDATE `".$xoopsDB->prefix("mod_xnewsletter_cat")."` SET `cat_mailinglist` = 0";
if ($result = $xoopsDB->query($sql)) {
$update++;
} else {
@@ -314,13 +367,13 @@
}
} else {
//set cat_mailinglist = 0, if mailinglist_id is no more existing in table mailinglist
- $sql = "SELECT Count(`cat_mailinglist`) AS `nb_ids` FROM `".$xoopsDB->prefix("xnewsletter_cat")."` LEFT JOIN `".$xoopsDB->prefix("xnewsletter_mailinglist")."` ON `cat_mailinglist` = `mailinglist_id` WHERE (((`mailinglist_id`) Is Null) AND ((`cat_mailinglist`)>0)) HAVING (((Count(`cat_mailinglist`))>0));";
+ $sql = "SELECT Count(`cat_mailinglist`) AS `nb_ids` FROM `".$xoopsDB->prefix("mod_xnewsletter_cat")."` LEFT JOIN `".$xoopsDB->prefix("mod_xnewsletter_mailinglist")."` ON `cat_mailinglist` = `mailinglist_id` WHERE (((`mailinglist_id`) Is Null) AND ((`cat_mailinglist`)>0)) HAVING (((Count(`cat_mailinglist`))>0));";
if ( $result = $xoopsDB->query($sql) ) {
$row_result = $xoopsDB->fetchRow($result);
$number_ids = $row_result[0];
}
if ($number_ids > 0) {
- $sql = "UPDATE `".$xoopsDB->prefix("xnewsletter_cat")."` LEFT JOIN `".$xoopsDB->prefix("xnewsletter_mailinglist")."` ON `cat_mailinglist` = `mailinglist_id` SET `cat_mailinglist` = 0 WHERE (((`cat_mailinglist`)>0) AND ((`mailinglist_id`) Is Null));";
+ $sql = "UPDATE `".$xoopsDB->prefix("mod_xnewsletter_cat")."` LEFT JOIN `".$xoopsDB->prefix("mod_xnewsletter_mailinglist")."` ON `cat_mailinglist` = `mailinglist_id` SET `cat_mailinglist` = 0 WHERE (((`cat_mailinglist`)>0) AND ((`mailinglist_id`) Is Null));";
if ($result = $xoopsDB->query($sql)) {
$update++;
} else {
@@ -370,6 +423,7 @@
if (isset($_POST["ok"]) && $_POST["ok"] == "1") {
$update = 0;
$error = array();
+ $number_ids = 0;
$letter_arr = $letterHandler->getall();
foreach (array_keys($letter_arr) as $letter_id)
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/menu.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/menu.php 2013-10-15 22:20:13 UTC (rev 12177)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/menu.php 2013-10-16 05:28:13 UTC (rev 12178)
@@ -72,6 +72,12 @@
$adminmenu[$i]["link"] = "admin/mailinglist.php";
$adminmenu[$i]["icon"] = $pathImageAdmin."/xn_mailinglist.png";
}
+if (isset($xoopsModuleConfig['xn_send_in_packages']) && $xoopsModuleConfig['xn_send_in_packages'] > 0) {
+ $i++;
+ $adminmenu[$i]["title"] = _MI_XNEWSLETTER_ADMENU13;
+ $adminmenu[$i]["link"] = "admin/task.php";
+ $adminmenu[$i]["icon"] = $pathImageAdmin."/xn_task.png";
+}
$i++;
$adminmenu[$i]["title"] = _MI_XNEWSLETTER_ADMENU10;
$adminmenu[$i]["link"] = "admin/bmh.php";
@@ -81,6 +87,10 @@
$adminmenu[$i]["link"] = "admin/maintenance.php";
$adminmenu[$i]["icon"] = $pathImageAdmin."/xn_maintenance.png";
$i++;
+$adminmenu[$i]["title"] = _MI_XNEWSLETTER_ADMENU12;
+$adminmenu[$i]["link"] = "admin/import.php";
+$adminmenu[$i]["icon"] = $pathImageAdmin."/xn_import.png";
+$i++;
$adminmenu[$i]["title"] = _MI_XNEWSLETTER_ADMENU99;
$adminmenu[$i]["link"] = "admin/about.php";
$adminmenu[$i]["icon"] = $pathImageAdmin."/about.png";
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/protocol.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/protocol.php 2013-10-15 22:20:13 UTC (rev 12177)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/protocol.php 2013-10-16 05:28:13 UTC (rev 12178)
@@ -316,7 +316,7 @@
if ( !$GLOBALS["xoopsSecurity"]->check() ) {
redirect_header("protocol.php", 3, implode(",", $GLOBALS["xoopsSecurity"]->getErrors()));
}
- $sql = "DELETE FROM `".$xoopsDB->prefix("xnewsletter_protocol")."` WHERE `protocol_letter_id`=$letter_id;";
+ $sql = "DELETE FROM `".$xoopsDB->prefix("mod_xnewsletter_protocol")."` WHERE `protocol_letter_id`=$letter_id;";
$result = $xoopsDB->query($sql);
if ($result) {
redirect_header("protocol.php", 3, _AM_XNEWSLETTER_FORMDELOK);
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/sendletter.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/sendletter.php 2013-10-15 22:20:13 UTC (rev 12177)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/sendletter.php 2013-10-16 05:28:13 UTC (rev 12178)
@@ -27,8 +27,23 @@
*/
include "admin_header.php";
+include XOOPS_ROOT_PATH."/modules/xNewsletter/include/task.inc.php";
-include XOOPS_ROOT_PATH."/modules/xNewsletter/include/sendletter.php";
+$op = xNewsletter_CleanVars($_REQUEST, 'op', 'list', 'string');
+$letter_id = xNewsletter_CleanVars($_REQUEST, 'letter_id', 0, 'int');
+$xn_send_in_packages = $xoopsModuleConfig['xn_send_in_packages'];
+if ($xn_send_in_packages > 0 && $op != "send_test") {
+ $xn_send_in_packages_time = $xoopsModuleConfig['xn_send_in_packages_time'];
+} else {
+ $xn_send_in_packages_time = 0;
+}
+
+$result = Create_Tasklist( $op, $letter_id, $xn_send_in_packages, $xn_send_in_packages_time );
+
+$result_exec = Execute_Tasks( $xn_send_in_packages, $letter_id );
+
+redirect_header("letter.php", 3, $result_exec);
+
include "admin_footer.php";
?>
\ No newline at end of file
Modified: XoopsModules/xnewsletter/trunk/xNewsletter/admin/subscr.php
===================================================================
--- XoopsModules/xnewsletter/trunk/xNewsletter/admin/subscr.php 2013-10-15 22:20:13 UTC (rev 12177)
+++ XoopsModules/xnewsletter/trunk/xNewsletter/admin/subscr.php 2013-10-16 05:28:13 UTC (rev 12178)
@@ -48,7 +48,55 @@
$subscrAdmin = new ModuleAdmin();
switch ($op)
{
- case "list":
+ case "show_catsubscr":
+ echo $subscrAdmin->addNavigation('subscr.php');
+ $apply_filter = xNewsletter_CleanVars($_REQUEST, 'apply_filter', 'list', 'string');
+ $linklist = "subscr.php?op=$apply_filter&filter_subscr=$filter_subscr";
+ $linklist .= "&filter_subscr_firstname=$filter_subscr_firstname";
+ $linklist .= "&filter_subscr_lastname=$filter_subscr_lastname";
+ $linklist .= "&filter_subscr_email=$filter_subscr_email";
+ $subscrAdmin->addItemButton(_AM_XNEWSLETTER_SUBSCR_SHOW_ALL, $linklist, 'view_detailed');
+...
[truncated message content] |
|
From: <luc...@us...> - 2013-10-15 22:20:15
|
Revision: 12177
http://sourceforge.net/p/xoops/svn/12177
Author: luciorota
Date: 2013-10-15 22:20:13 +0000 (Tue, 15 Oct 2013)
Log Message:
-----------
small improvements in categories and indexpage forms
Modified Paths:
--------------
XoopsModules/wfdownloads/trunk/wfdownloads/admin/categories.php
XoopsModules/wfdownloads/trunk/wfdownloads/admin/indexpage.php
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/admin/categories.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/admin/categories.php 2013-10-15 21:25:44 UTC (rev 12176)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/admin/categories.php 2013-10-15 22:20:13 UTC (rev 12177)
@@ -88,7 +88,6 @@
$uploader = new XoopsMediaUploader($uploadDirectory, $allowedMimetypes, $maxFileSize, $maxImgWidth, $maxImgHeight);
if ($uploader->fetchMedia($_POST['xoops_upload_file'][0])) {
$uploader->setTargetFileName('wfdownloads_' . uniqid(time()) . '--' . strtolower($_FILES['uploadfile']['name']));
- //$uploader->setPrefix('wfdownloads_' . uniqid(time()) . '--');
$uploader->fetchMedia($_POST['xoops_upload_file'][0]);
if (!$uploader->upload()) {
$errors = $uploader->getErrors();
@@ -97,7 +96,7 @@
$imgurl = $uploader->getSavedFileName();
}
} else {
- $imgurl = ($_POST["imgurl"] && $_POST["imgurl"] != "blank.png") ? $myts -> addslashes($_POST["imgurl"]) : "";
+ $imgurl = (isset($_POST["imgurl"]) && $_POST["imgurl"] != "blank.png") ? $myts -> addslashes($_POST["imgurl"]) : "";
}
// Formulize module support (2006/05/04) jpc
if (wfdownloads_checkModule('formulize') < 300) {
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/admin/indexpage.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/admin/indexpage.php 2013-10-15 21:25:44 UTC (rev 12176)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/admin/indexpage.php 2013-10-15 22:20:13 UTC (rev 12177)
@@ -24,10 +24,29 @@
$op = WfdownloadsRequest::getString('op', 'indexpage.form');
switch ($op) {
case "indexpage.save":
+ // Get post parameters
$indexheading = $myts->addslashes($_POST['indexheading']);
$indexheader = $myts->addslashes($_POST['indexheader']);
$indexfooter = $myts->addslashes($_POST['indexfooter']);
- $indeximage = $myts->addslashes($_POST['indeximage']);
+ include_once XOOPS_ROOT_PATH.'/class/uploader.php';
+ $allowedMimetypes = array('image/gif', 'image/jpeg', 'image/pjpeg', 'image/x-png', 'image/png');
+ $maxFileSize = $wfdownloads->getConfig('maxfilesize');
+ $maxImgWidth = $wfdownloads->getConfig('maximgwidth');
+ $maxImgHeight = $wfdownloads->getConfig('maximgheight');
+ $uploadDirectory = XOOPS_ROOT_PATH . '/' . $wfdownloads->getConfig('mainimagedir');
+ $uploader = new XoopsMediaUploader($uploadDirectory, $allowedMimetypes, $maxFileSize, $maxImgWidth, $maxImgHeight);
+ if ($uploader->fetchMedia($_POST['xoops_upload_file'][0])) {
+ $uploader->setTargetFileName('wfdownloads_' . uniqid(time()) . '--' . strtolower($_FILES['uploadfile']['name']));
+ $uploader->fetchMedia($_POST['xoops_upload_file'][0]);
+ if (!$uploader->upload()) {
+ $errors = $uploader->getErrors();
+ redirect_header("javascript:history.go(-1)",3, $errors);
+ } else {
+ $indeximage = $uploader->getSavedFileName();
+ }
+ } else {
+ $indeximage = (isset($_POST["indeximage"]) && $_POST["indeximage"] != "blank.png") ? $myts->addslashes($_POST['indeximage']) : "";
+ }
$nohtml = isset($_POST['nohtml']);
$nosmiley = isset($_POST['nosmiley']);
$noxcodes = isset($_POST['noxcodes']);
@@ -35,12 +54,20 @@
$nobreak = isset($_POST['nobreak']);
$indexheaderalign = $_POST['indexheaderalign'];
$indexfooteralign = $_POST['indexfooteralign'];
-
- $xoopsDB->query(
- "update " . $xoopsDB->prefix("wfdownloads_indexpage") . " set indexheading='$indexheading', indexheader='$indexheader', indexfooter='$indexfooter', indeximage='$indeximage', indexheaderalign='$indexheaderalign', indexfooteralign='$indexfooteralign', nohtml='"
- . intval($nohtml) . "', nosmiley='" . intval($nosmiley) . "', noxcodes='" . intval($noxcodes) . "', noimages='" . intval($noimages)
- . "', nobreak='" . intval($nobreak) . "' "
- );
+ // Update db
+ $sql = "update {$xoopsDB->prefix("wfdownloads_indexpage")} set";
+ $sql.= " indexheading='{$indexheading}',";
+ $sql.= " indexheader='{$indexheader}',";
+ $sql.= " indexfooter='{$indexfooter}',";
+ $sql.= " indeximage='{$indeximage}',";
+ $sql.= " indexheaderalign='{$indexheaderalign}',";
+ $sql.= " indexfooteralign='{$indexfooteralign}',";
+ $sql.= " nohtml='{$nohtml}',";
+ $sql.= " nosmiley='{$nosmiley}',";
+ $sql.= " noxcodes='{$noxcodes}',";
+ $sql.= " noimages='{$noimages}',";
+ $sql.= " nobreak='{$nobreak}' ";
+ $xoopsDB->query($sql);
redirect_header(WFDOWNLOADS_URL . '/admin/indexpage.php', 1, _AM_WFDOWNLOADS_IPAGE_UPDATED);
exit();
@@ -51,10 +78,9 @@
include_once WFDOWNLOADS_ROOT_PATH . '/class/wfdownloads_lists.php';
include XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
- $result = $xoopsDB->query(
- "SELECT indeximage, indexheading, indexheader, indexfooter, nohtml, nosmiley, noxcodes, noimages, nobreak, indexheaderalign, indexfooteralign FROM "
- . $xoopsDB->prefix('wfdownloads_indexpage') . " "
- );
+ $sql = "SELECT indeximage, indexheading, indexheader, indexfooter, nohtml, nosmiley, noxcodes, noimages, nobreak, indexheaderalign, indexfooteralign";
+ $sql.= " FROM {$xoopsDB->prefix('wfdownloads_indexpage')} ";
+ $result = $xoopsDB->query($sql);
list($indeximage, $indexheading, $indexheader, $indexfooter, $nohtml, $nosmiley, $noxcodes, $noimages, $nobreak, $indexheaderalign,
$indexfooteralign)
= $xoopsDB->fetchrow($result);
@@ -68,63 +94,59 @@
echo "</fieldset>\n";
$sform = new XoopsThemeForm(_AM_WFDOWNLOADS_IPAGE_MODIFY, "op", xoops_getenv('PHP_SELF'));
+ $sform->setExtra('enctype="multipart/form-data"');
+ // indexpage: indexheading
$sform->addElement(new XoopsFormText(_AM_WFDOWNLOADS_IPAGE_CTITLE, 'indexheading', 60, 60, $indexheading), false);
- $graph_array = WfsLists::getListTypeAsArray(XOOPS_ROOT_PATH . '/' . $wfdownloads->getConfig('mainimagedir'), $type = "images");
- $indeximage_select = new XoopsFormSelect('', 'indeximage', $indeximage);
- $indeximage_select->addOptionArray($graph_array);
- $indeximage_select->setExtra(
- "onchange='showImgSelected(\"image\", \"indeximage\", \"" . $wfdownloads->getConfig('mainimagedir') . "\", \"\", \"" . XOOPS_URL . "\")'"
- );
- $indeximage_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_IPAGE_CIMAGE, ' ');
- $indeximage_tray->addElement($indeximage_select);
- if (!empty($indeximage)) {
- $indeximage_tray->addElement(
- new XoopsFormLabel('', "<br /><br /><img src='" . XOOPS_URL . '/' . $wfdownloads->getConfig('mainimagedir') . '/' . $indeximage
- . "' name='image' id='image' alt='' title='image' />")
- );
- } else {
- $indeximage_tray->addElement(
- new XoopsFormLabel('', "<br /><br /><img src='" . XOOPS_URL . "/uploads/blank.gif' name='image' id='image' alt='' title='image' />")
- );
- }
+ // indexpage: indeximage
+ $indeximage_path = $indeximage ? $wfdownloads->getConfig('mainimagedir') . '/' . $indeximage : WFDOWNLOADS_IMAGES_URL . '/blank.gif';
+ $indeximage_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_IPAGE_CIMAGE, '<br />');
+ $indeximage_tray->addElement(new XoopsFormLabel(_AM_WFDOWNLOADS_DOWN_FUPLOADPATH, XOOPS_ROOT_PATH . '/' . $wfdownloads->getConfig('mainimagedir')));
+ $indeximage_tray->addElement(new XoopsFormLabel(_AM_WFDOWNLOADS_DOWN_FUPLOADURL, XOOPS_URL . '/' . $wfdownloads->getConfig('mainimagedir')));
+ $graph_array = & WfsLists::getListTypeAsArray(XOOPS_ROOT_PATH . '/' . $wfdownloads->getConfig('mainimagedir'), $type = "images");
+ $indeximage_select = new XoopsFormSelect('', 'indeximage', $indeximage);
+ $indeximage_select->addOptionArray($graph_array);
+ $indeximage_select->setExtra(
+ "onchange='showImgSelected(\"image\", \"indeximage\", \"" . $wfdownloads->getConfig('mainimagedir') . "\", \"\", \"" . XOOPS_URL . "\")'"
+ );
+ $indeximage_tray->addElement($indeximage_select, false);
+ $indeximage_tray->addElement( new XoopsFormLabel( '', "<img src='" . XOOPS_URL . "/" . $indeximage_path . "' name='image' id='image' alt='' />" ) );
+ $indeximage_tray->addElement(new XoopsFormFile(_AM_WFDOWNLOADS_BUPLOAD , 'uploadfile', 0), false);
$sform->addElement($indeximage_tray);
-
+ // indexpage: indexheader
$sform->addElement(new XoopsFormDhtmlTextArea(_AM_WFDOWNLOADS_IPAGE_CHEADING, 'indexheader', $indexheader, 15, 60));
+ // indexpage: indexheaderalign
$headeralign_select = new XoopsFormSelect(_AM_WFDOWNLOADS_IPAGE_CHEADINGA, "indexheaderalign", $indexheaderalign);
$headeralign_select->addOptionArray(
array("left" => _AM_WFDOWNLOADS_IPAGE_CLEFT, "right" => _AM_WFDOWNLOADS_IPAGE_CRIGHT, "center" => _AM_WFDOWNLOADS_IPAGE_CCENTER)
);
$sform->addElement($headeralign_select);
+ // indexpage: indexfooter
$sform->addElement(new XoopsFormDhtmlTextArea(_AM_WFDOWNLOADS_IPAGE_CFOOTER, 'indexfooter', $indexfooter, 15, 60));
+ // indexpage: indexfooteralign
$footeralign_select = new XoopsFormSelect(_AM_WFDOWNLOADS_IPAGE_CFOOTERA, "indexfooteralign", $indexfooteralign);
$footeralign_select->addOptionArray(
array("left" => _AM_WFDOWNLOADS_IPAGE_CLEFT, "right" => _AM_WFDOWNLOADS_IPAGE_CRIGHT, "center" => _AM_WFDOWNLOADS_IPAGE_CCENTER)
);
$sform->addElement($footeralign_select);
-
+ // indexpage: nohtml, nosmailey, noxcodes, noimages, nobreak
$options_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_TEXTOPTIONS, '<br />');
-
$html_checkbox = new XoopsFormCheckBox('', 'nohtml', $nohtml);
$html_checkbox->addOption(1, _AM_WFDOWNLOADS_ALLOWHTML);
$options_tray->addElement($html_checkbox);
-
$smiley_checkbox = new XoopsFormCheckBox('', 'nosmiley', $nosmiley);
$smiley_checkbox->addOption(1, _AM_WFDOWNLOADS_ALLOWSMILEY);
$options_tray->addElement($smiley_checkbox);
-
$xcodes_checkbox = new XoopsFormCheckBox('', 'noxcodes', $noxcodes);
$xcodes_checkbox->addOption(1, _AM_WFDOWNLOADS_ALLOWXCODE);
$options_tray->addElement($xcodes_checkbox);
-
$noimages_checkbox = new XoopsFormCheckBox('', 'noimages', $noimages);
$noimages_checkbox->addOption(1, _AM_WFDOWNLOADS_ALLOWIMAGES);
$options_tray->addElement($noimages_checkbox);
-
$breaks_checkbox = new XoopsFormCheckBox('', 'nobreak', $nobreak);
$breaks_checkbox->addOption(1, _AM_WFDOWNLOADS_ALLOWBREAK);
$options_tray->addElement($breaks_checkbox);
$sform->addElement($options_tray);
-
+ // form: button try
$button_tray = new XoopsFormElementTray('', '');
$hidden = new XoopsFormHidden('op', 'indexpage.save');
$button_tray->addElement($hidden);
|
|
From: <luc...@us...> - 2013-10-15 21:25:48
|
Revision: 12176
http://sourceforge.net/p/xoops/svn/12176
Author: luciorota
Date: 2013-10-15 21:25:44 +0000 (Tue, 15 Oct 2013)
Log Message:
-----------
fixed: thumbnails generator error
change options order in preferences menu
Modified Paths:
--------------
XoopsModules/wfdownloads/trunk/wfdownloads/admin/categories.php
XoopsModules/wfdownloads/trunk/wfdownloads/admin/downloads.php
XoopsModules/wfdownloads/trunk/wfdownloads/admin/reportsmodifications.php
XoopsModules/wfdownloads/trunk/wfdownloads/class/category.php
XoopsModules/wfdownloads/trunk/wfdownloads/class/download.php
XoopsModules/wfdownloads/trunk/wfdownloads/class/multicolumnsthemeform.php
XoopsModules/wfdownloads/trunk/wfdownloads/class/wfdownloads.php
XoopsModules/wfdownloads/trunk/wfdownloads/docs/changelog.txt
XoopsModules/wfdownloads/trunk/wfdownloads/include/functions.php
XoopsModules/wfdownloads/trunk/wfdownloads/language/english/admin.php
XoopsModules/wfdownloads/trunk/wfdownloads/language/english/modinfo.php
XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_viewcat.html
XoopsModules/wfdownloads/trunk/wfdownloads/xoops_version.php
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/admin/categories.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/admin/categories.php 2013-10-15 17:41:43 UTC (rev 12175)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/admin/categories.php 2013-10-15 21:25:44 UTC (rev 12176)
@@ -72,19 +72,37 @@
case "category.save" :
case "addCat" :
$cid = WfdownloadsRequest::getInt('cid', 0, 'POST');
+ $pid = WfdownloadsRequest::getInt('pid', 0, 'POST');
+ $weight = (isset($_POST["weight"]) && $_POST["weight"] > 0) ? (int)$_POST["weight"] : 0;
$down_groups = isset($_POST['groups']) ? $_POST['groups'] : array();
$up_groups = isset($_POST['up_groups']) ? $_POST['up_groups'] : array();
- $pid = (isset($_POST["pid"])) ? (int)$_POST["pid"] : 0;
- $weight = (isset($_POST["weight"]) && $_POST["weight"] > 0) ? (int)$_POST["weight"] : 0;
$spotlighthis = (isset($_POST["lid"])) ? (int)$_POST["lid"] : 0;
$spotlighttop = (isset($_POST["spotlighttop"]) && ($_POST["spotlighttop"] == 1)) ? 1 : 0;
- $imgurl = ($_POST["imgurl"] && $_POST["imgurl"] != "blank.png") ? $myts -> addslashes($_POST["imgurl"]) : "";
- $dohtml = isset($_POST['dohtml']);
- $dosmiley = isset($_POST['dosmiley']);
- $doxcode = isset($_POST['doxcode']);
- $doimage = isset($_POST['doimage']);
- $dobr = isset($_POST['dobr']);
+ include_once XOOPS_ROOT_PATH.'/class/uploader.php';
+ $allowedMimetypes = array('image/gif', 'image/jpeg', 'image/pjpeg', 'image/x-png', 'image/png');
+ $maxFileSize = $wfdownloads->getConfig('maxfilesize');
+ $maxImgWidth = $wfdownloads->getConfig('maximgwidth');
+ $maxImgHeight = $wfdownloads->getConfig('maximgheight');
+ $uploadDirectory = XOOPS_ROOT_PATH . '/' . $wfdownloads->getConfig('catimage');
+ $uploader = new XoopsMediaUploader($uploadDirectory, $allowedMimetypes, $maxFileSize, $maxImgWidth, $maxImgHeight);
+ if ($uploader->fetchMedia($_POST['xoops_upload_file'][0])) {
+ $uploader->setTargetFileName('wfdownloads_' . uniqid(time()) . '--' . strtolower($_FILES['uploadfile']['name']));
+ //$uploader->setPrefix('wfdownloads_' . uniqid(time()) . '--');
+ $uploader->fetchMedia($_POST['xoops_upload_file'][0]);
+ if (!$uploader->upload()) {
+ $errors = $uploader->getErrors();
+ redirect_header("javascript:history.go(-1)",3, $errors);
+ } else {
+ $imgurl = $uploader->getSavedFileName();
+ }
+ } else {
+ $imgurl = ($_POST["imgurl"] && $_POST["imgurl"] != "blank.png") ? $myts -> addslashes($_POST["imgurl"]) : "";
+ }
+ // Formulize module support (2006/05/04) jpc
+ if (wfdownloads_checkModule('formulize') < 300) {
+ $formulize_fid = (isset($_POST["formulize_fid"])) ? (int)$_POST["formulize_fid"] : 0;
+ }
if (!$cid) {
$category = $wfdownloads->getHandler('category')->create();
@@ -96,31 +114,25 @@
}
}
- // Added Formulize module support (2006/05/04) jpc - start
- if (wfdownloads_checkModule('formulize') < 300) {
- $formulize_fid = (isset($_POST["formulize_fid"])) ? (int)$_POST["formulize_fid"] : 0;
- }
- // Added Formulize module support (2006/05/04) jpc - end
$category->setVar('title', $_POST["title"]);
- $category->setVar('description', $_POST["description"]);
- $category->setVar('summary', $_POST["summary"]);
- $category->setVar('dohtml', $dohtml);
- $category->setVar('dosmiley', $dosmiley);
- $category->setVar('doxcode', $doxcode);
- $category->setVar('dobr', $dobr);
- $category->setVar('doimage', $doimage);
$category->setVar('pid', $pid);
$category->setVar('weight', $weight);
- $category->setVar('spotlighthis', $spotlighthis);
- $category->setVar('spotlighttop', $spotlighttop);
$category->setVar('imgurl', $imgurl);
- // Added Formulize module support (2006/05/04) jpc - start
+ $category->setVar('description', $_POST["description"]);
+ $category->setVar('summary', $_POST["summary"]);
+ $category->setVar('dohtml', isset($_POST['dohtml']));
+ $category->setVar('dosmiley', isset($_POST['dosmiley']));
+ $category->setVar('doxcode', isset($_POST['doxcode']));
+ $category->setVar('doimage', isset($_POST['doimage']));
+ $category->setVar('dobr', isset($_POST['dobr']));
+ // Formulize module support (2006/05/04) jpc
if (wfdownloads_checkModule('formulize')) {
$category->setVar('formulize_fid', $formulize_fid);
}
- // Added Formulize module support (2006/05/04) jpc - end
- $result = $wfdownloads->getHandler('category')->insert($category);
- if (!$result) {
+ $category->setVar('spotlighthis', $spotlighthis);
+ $category->setVar('spotlighttop', $spotlighttop);
+
+ if (!$wfdownloads->getHandler('category')->insert($category)) {
echo $category->getHtmlErrors();
}
if (!$cid) {
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/admin/downloads.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/admin/downloads.php 2013-10-15 17:41:43 UTC (rev 12175)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/admin/downloads.php 2013-10-15 21:25:44 UTC (rev 12176)
@@ -640,7 +640,7 @@
}
// Evaluate date criteria
if (!empty($filter_date)) {
- // IN PROGRESS
+ // TODO: IN PROGRESS
}
}
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/admin/reportsmodifications.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/admin/reportsmodifications.php 2013-10-15 17:41:43 UTC (rev 12175)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/admin/reportsmodifications.php 2013-10-15 21:25:44 UTC (rev 12176)
@@ -64,175 +64,24 @@
case "modification.show":
$requestid = WfdownloadsRequest::getInt('requestid', 0);
- $modification = $wfdownloads->getHandler('modification')->get($requestid);
- $modify_user = new XoopsUser($modification->getVar('modifysubmitter'));
- $modifyname = XoopsUserUtility::getUnameFromId((int)$modify_user->getVar('uid'));
- $modifyemail = $modify_user->getVar('email');
+ $modification = $wfdownloads->getHandler('modification')->get($requestid);
+ $modify_user = new XoopsUser($modification->getVar('modifysubmitter'));
+ $modifyname = XoopsUserUtility::getUnameFromId((int)$modify_user->getVar('uid'));
+ $modifyemail = $modify_user->getVar('email');
- $download = $wfdownloads->getHandler('download')->get($modification->getVar('lid'));
+ $download = $wfdownloads->getHandler('download')->get($modification->getVar('lid'));
$orig_user = new XoopsUser($download->getVar('submitter'));
$submittername = XoopsUserUtility::getUnameFromId($download->getVar('submitter')); // $orig_user->getvar("uname");
$submitteremail = $orig_user->getVar('email');
+ $categories = $wfdownloads->getHandler('category')->getObjects();
+ $categoriesTree = new XoopsObjectTree($categories, 'cid', 'pid');
wfdownloads_xoops_cp_header();
- echo "<div><b>" . _AM_WFDOWNLOADS_MOD_MODPOSTER . "</b> $submittername</div>";
- $not_allowed = array('lid', 'submitter', 'requestid', 'modifysubmitter');
// IN PROGRESS
// IN PROGRESS
// IN PROGRESS
-// IN PROGRESS ORG FROM HERE
- $sform = new XoopsThemeForm(_AM_WFDOWNLOADS_MOD_ORIGINAL, 'storyform', 'index.php');
-
- $keys = $download->getVars();
- foreach (array_keys($keys) as $key) {
- if (in_array($key, $not_allowed)) {
- continue;
- }
- $lang_def = constant("_AM_WFDOWNLOADS_MOD_" . strtoupper($key));
-
- $content = $download->getVar($key, 'e');
- switch ($key) {
- case "platform":
- case "license":
- case "limitations":
- case "versiontypes":
- $tempArray = $wfdownloads->getConfig($key);
- $content = isset($tempArray[$download->getVar($key)]) ? $tempArray[$download->getVar($key)] : '';
- break;
- case "cid":
- $category_list = $wfdownloads->getHandler('category')->getObjects(new Criteria("cid", $download->getVar($key)));
- if (!isset($category_list[0])) {
- continue;
- }
- $content = $category_list[0]->getVar('title', 'e');
- break;
- case "screenshot":
- if ($content != '') {
- $content = "<img src='" . XOOPS_URL . '/' . $wfdownloads->getConfig('screenshots') . '/' . $content . "' width='"
- . $wfdownloads->getConfig('shotwidth') . "' alt='' title='' />";
- }
- break;
- case "screenshot2":
- if ($content != '') {
- $content = "<img src='" . XOOPS_URL . '/' . $wfdownloads->getConfig('screenshots') . '/' . $content . "' width='"
- . $wfdownloads->getConfig('shotwidth') . "' alt='' title='' />";
- }
- break;
- case "screenshot3":
- if ($content != '') {
- $content = "<img src='" . XOOPS_URL . '/' . $wfdownloads->getConfig('screenshots') . '/' . $content . "' width='"
- . $wfdownloads->getConfig('shotwidth') . "' alt='' title='' />";
- }
- break;
- case "screenshot4":
- if ($content != '') {
- $content = "<img src='" . XOOPS_URL . '/' . $wfdownloads->getConfig('screenshots') . '/' . $content . "' width='"
- . $wfdownloads->getConfig('shotwidth') . "' alt='' title='' />";
- }
- break;
- case "features":
- case "requirements":
- if ($content != '') {
- $downrequirements = explode('|', trim($content));
- foreach ($downrequirements as $bi) {
- $content = "<li>" . $bi;
- }
- }
- break;
- case "dhistory":
- $content = $myts->displayTarea($content, true, false, false, false, true);
- break;
- }
- $sform->addElement(new XoopsFormLabel($lang_def, $content));
- }
- $sform->display();
-
- echo "<div><b>" . _AM_WFDOWNLOADS_MOD_MODIFYSUBMITTER . "</b> $modifyname</div>";
- $sform = new XoopsThemeForm(_AM_WFDOWNLOADS_MOD_PROPOSED, 'storyform', 'reportsmodifications.php');
- $keys = $modification->getVars();
- foreach (array_keys($keys) as $key) {
- if (in_array($key, $not_allowed)) {
- continue;
- }
- $lang_def = constant("_AM_WFDOWNLOADS_MOD_" . strtoupper($key));
-
- $content = $modification->getVar($key, 'e');
- switch ($key) {
- case "platform":
- case "license":
- case "limitations":
- case "versiontypes":
- $tempArray = $wfdownloads->getConfig($key);
- $content = isset($tempArray[$modification->getVar($key)]) ? $tempArray[$modification->getVar($key)] : '';
- break;
- case "cid":
- $category_list = $wfdownloads->getHandler('category')->getObjects(new Criteria('cid', $modification->getVar($key)));
- if (!isset($category_list[0])) {
- continue;
- }
- $content = $category_list[0]->getVar('title', 'e');
- break;
- case "screenshot":
- if ($content != '') {
- $content = "<img src='" . XOOPS_URL . '/' . $wfdownloads->getConfig('screenshots') . '/' . $content . "' width='"
- . $wfdownloads->getConfig('shotwidth') . "' alt='' title='' />";
- }
- break;
- case "screenshot2":
- if ($content != '') {
- $content = "<img src='" . XOOPS_URL . '/' . $wfdownloads->getConfig('screenshots') . '/' . $content . "' width='"
- . $wfdownloads->getConfig('shotwidth') . "' alt='' title='' />";
- }
- break;
- case "screenshot3":
- if ($content != '') {
- $content = "<img src='" . XOOPS_URL . '/' . $wfdownloads->getConfig('screenshots') . '/' . $content . "' width='"
- . $wfdownloads->getConfig('shotwidth') . "' alt='' title='' />";
- }
- break;
- case "screenshot4":
- if ($content != '') {
- $content = "<img src='" . XOOPS_URL . '/' . $wfdownloads->getConfig('screenshots') . '/' . $content . "' width='"
- . $wfdownloads->getConfig('shotwidth') . "' alt='' title='' />";
- }
- break;
- case "features":
- case "requirements":
- if ($content != '') {
- $downrequirements = explode('|', trim($content));
- foreach ($downrequirements as $bi) {
- $content = "<li>" . $bi;
- }
- }
- break;
- case "dhistory":
- $content = $myts->displayTarea($content, true, false, false, false, true);
- break;
- }
- $sform->addElement(new XoopsFormLabel($lang_def, $content));
- }
-
- $button_tray = new XoopsFormElementTray('', '');
- $button_tray->addElement(new XoopsFormHidden('requestid', $requestid));
- $button_tray->addElement(new XoopsFormHidden('lid', (int)$modification->getVar('lid')));
- $hidden = new XoopsFormHidden('op', 'modification.change');
- $button_tray->addElement($hidden);
- if (!$modification->isNew()) {
- $approve_button = new XoopsFormButton('', '', _AM_WFDOWNLOADS_BAPPROVE, 'submit');
- $approve_button->setExtra('onclick="this.form.elements.op.value=\'modification.change\'"');
- $button_tray->addElement($approve_button);
- }
- $ignore_button = new XoopsFormButton('', '', _AM_WFDOWNLOADS_BIGNORE, 'submit');
- $ignore_button->setExtra('onclick="this.form.elements.op.value=\'modification.ignore\'"');
- $button_tray->addElement($ignore_button);
- $sform->addElement($button_tray);
- $sform->display();
-
-// IN PROGRESS
-// IN PROGRESS
-// IN PROGRESS
// IN PROGRESS NEW FROM HERE
echo "<div><b>" . _AM_WFDOWNLOADS_MOD_MODPOSTER . "</b> $submittername</div>";
@@ -249,12 +98,13 @@
// Get common keys
$commonKeys = array_intersect($downloadKeys, $modificationKeys);
// Set not allowed keys
-$notAllowedKeys = array('lid', 'submitter', 'requestid', 'modifysubmitter');
+$notAllowedKeys = array('lid', 'submitter', 'publisher', 'requestid', 'forumid', 'modifysubmitter', 'screenshots', 'paypalemail');
$i = 0;
-//$mcform->addElement(' ', false, 0, 0);
-//$mcform->addElement(_AM_WFDOWNLOADS_MOD_ORIGINAL, false, 0, 1);
-//$mcform->addElement(_AM_WFDOWNLOADS_MOD_PROPOSED, false, 0, 2);
+$mcform->addElement('', false, 0, 0);
+$mcform->addElement(_AM_WFDOWNLOADS_MOD_ORIGINAL, false, 0, 1);
+$mcform->addElement(_AM_WFDOWNLOADS_MOD_PROPOSED, false, 0, 2);
+$mcform->addElement(_EDIT, false, 0, 3);
$i = 1;
foreach ($commonKeys as $key) {
if (in_array($key, $notAllowedKeys)) {
@@ -263,8 +113,28 @@
$caption = constant("_AM_WFDOWNLOADS_MOD_" . strtoupper($key));
$downloadContent = $download->getVar($key, 'e');
$modificationContent = $modification->getVar($key, 'e');
+ $editContent = '';
// Extra jobs for some keys
switch ($key) {
+ case "title" :
+ $editContent = new XoopsFormText('', 'title', 50, 255, $downloadContent);
+ break;
+ case "url" :
+ $editContent = new XoopsFormText('', 'url', 50, 255, $downloadContent);
+ break;
+ case "size" :
+ $downloadContent = wfdownloads_bytesToSize1024($downloadContent);
+ //
+ $modificationContent = wfdownloads_bytesToSize1024($modificationContent);
+ break;
+ case "date" :
+ case "published" :
+ case "expired" :
+ case "updated" :
+ $downloadContent = ($downloadContent != false) ? formatTimestamp($downloadContent, _DATESTRING) : _NO;
+ //
+ $modificationContent = ($modificationContent != false) ? formatTimestamp($modificationContent, _DATESTRING) : _NO;
+ break;
case "platform":
case "license":
case "limitations":
@@ -282,6 +152,8 @@
$category_list = $wfdownloads->getHandler('category')->getObjects(new Criteria("cid", $modification->getVar($key)));
if (!isset($category_list[0])) continue;
$modificationContent = $category_list[0]->getVar('title', 'e');
+ //
+ $editContent = $categoriesTree->makeSelBox('cid', 'title', '-', $downloadContent);
break;
case "screenshot":
case "screenshot2":
@@ -291,6 +163,11 @@
//
if ($modificationContent != '') $modificationContent = "<img src='" . XOOPS_URL . "/{$wfdownloads->getConfig('screenshots')}/{$modificationContent}' width='{$wfdownloads->getConfig('shotwidth')}' alt='' title='' />";
break;
+ case "publisher" :
+ $downloadContent = XoopsUserUtility::getUnameFromId($downloadContent);
+ //
+ $modificationContent = XoopsUserUtility::getUnameFromId($modificationContent);
+ break;
case "features":
case "requirements":
if ($downloadContent != '') {
@@ -312,29 +189,26 @@
//
$modificationContent = $myts->displayTarea($modificationContent, true, false, false, false, true);
break;
+ case "offline":
+ $downloadContent = $downloadContent ? _YES : _NO;
+ //
+ $modificationContent = $modificationContent ? _YES : _NO;
+
}
$mcform->addElement($caption, false, $i, 0);
$mcform->addElement(new XoopsFormLabel('', $downloadContent), false, $i, 1);
$mcform->addElement(new XoopsFormLabel('', $modificationContent), false, $i, 2);
+ $mcform->addElement($editContent, false, $i, 3);
$i++;
}
-$mcform->addElement(' ', false, 0, 0);
-$mcform->addElement(_AM_WFDOWNLOADS_MOD_ORIGINAL, false, 0, 1);
-$mcform->addElement(_AM_WFDOWNLOADS_MOD_PROPOSED, false, 0, 2);
$mcform->display();
+// IN PROGRESS
+// IN PROGRESS
+// IN PROGRESS
+// IN PROGRESS ORG FROM HERE
+ $sform = new XoopsThemeForm(_AM_WFDOWNLOADS_MOD_PROPOSED, 'storyform', 'reportsmodifications.php');
-
-
-
-
-
-
-
-
-
-
-/*
$button_tray = new XoopsFormElementTray('', '');
$button_tray->addElement(new XoopsFormHidden('requestid', $requestid));
$button_tray->addElement(new XoopsFormHidden('lid', (int)$modification->getVar('lid')));
@@ -350,10 +224,7 @@
$button_tray->addElement($ignore_button);
$sform->addElement($button_tray);
$sform->display();
-*/
-
-
xoops_cp_footer();
exit();
break;
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/class/category.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/class/category.php 2013-10-15 17:41:43 UTC (rev 12175)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/class/category.php 2013-10-15 21:25:44 UTC (rev 12176)
@@ -82,11 +82,10 @@
$form = new XoopsThemeForm($title, 'form_error', $action, 'post', true);
$form->setExtra('enctype="multipart/form-data"');
-
+ // category: title
$form->addElement(new XoopsFormText(_AM_WFDOWNLOADS_FCATEGORY_TITLE, 'title', 50, 255, $this->getVar('title', 'e')), true);
-
- $totalcats = wfdownloads_categoriesCount();
- if ($totalcats > 0) {
+ // category: pid
+ if (wfdownloads_categoriesCount() > 0) {
$categories = $this->wfdownloads->getHandler('category')->getObjects();
$categoriesTree = new XoopsObjectTree($categories, 'cid', 'pid');
$form->addElement(
@@ -99,48 +98,43 @@
))
);
}
-
+ // category: weight
$form->addElement(new XoopsFormText(_AM_WFDOWNLOADS_FCATEGORY_WEIGHT, 'weight', 10, 80, $this->getVar('weight')), false);
-
+ // permission: WFDownCatPerm
$groups = $gperm_handler->getGroupIds('WFDownCatPerm', $this->getVar('cid'), $this->wfdownloads->getModule()->mid());
$groups_down_select = new XoopsFormSelectGroup(_AM_WFDOWNLOADS_FCATEGORY_GROUPPROMPT, "groups", true, $groups, 5, true);
$groups_down_select->setDescription(_AM_WFDOWNLOADS_FCATEGORY_GROUPPROMPT_DESC);
$form->addElement($groups_down_select);
+ // permission: WFUpCatPerm
$up_groups = $gperm_handler->getGroupIds('WFUpCatPerm', $this->getVar('cid'), $this->wfdownloads->getModule()->mid());
$groups_up_select = new XoopsFormSelectGroup(_AM_WFDOWNLOADS_FCATEGORY_GROUPPROMPT_UP, "up_groups", true, $up_groups, 5, true);
$groups_up_select->setDescription(_AM_WFDOWNLOADS_FCATEGORY_GROUPPROMPT_UP_DESC);
$form->addElement($groups_up_select);
-
- $graph_array = & WfsLists::getListTypeAsArray(XOOPS_ROOT_PATH . '/' . $this->wfdownloads->getConfig('catimage'), $type = "images");
- $indeximage_select = new XoopsFormSelect('', 'imgurl', $this->getVar('imgurl'));
- $indeximage_select->addOptionArray($graph_array);
- $indeximage_select->setExtra(
- "onchange='showImgSelected(\"image\", \"imgurl\", \"" . $this->wfdownloads->getConfig('catimage') . "\", \"\", \"" . XOOPS_URL . "\")'"
- );
- $indeximage_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_FCATEGORY_CIMAGE, ' ');
- $indeximage_tray->addElement($indeximage_select);
- if ($this->getVar('imgurl') != "") {
- $indeximage_tray->addElement(
- new XoopsFormLabel('',
- "<br /><br /><img src='" . XOOPS_URL . '/' . $this->wfdownloads->getConfig('catimage') . '/' . $this->getVar('imgurl')
- . "' name='image' id='image' alt='' title='image' />")
- );
- } else {
- $indeximage_tray->addElement(
- new XoopsFormLabel('', "<br /><br /><img src='" . XOOPS_URL . "/uploads/blank.gif' name='image' id='image' alt='' title='image' />")
- );
- }
- $form->addElement($indeximage_tray);
-
+ // category: imgurl
+ $imgurl_path = $this->getVar('imgurl') ? $this->wfdownloads->getConfig('catimage') . '/' . $this->getVar('imgurl') : WFDOWNLOADS_IMAGES_URL . '/blank.gif';
+ $imgurl_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_FCATEGORY_CIMAGE, '<br />');
+ $imgurl_tray->addElement(new XoopsFormLabel(_AM_WFDOWNLOADS_DOWN_FUPLOADPATH, XOOPS_ROOT_PATH . '/' . $this->wfdownloads->getConfig('catimage')));
+ $imgurl_tray->addElement(new XoopsFormLabel(_AM_WFDOWNLOADS_DOWN_FUPLOADURL, XOOPS_URL . '/' . $this->wfdownloads->getConfig('catimage')));
+ $graph_array = & WfsLists::getListTypeAsArray(XOOPS_ROOT_PATH . '/' . $this->wfdownloads->getConfig('catimage'), $type = "images");
+ $imgurl_select = new XoopsFormSelect('', 'imgurl', $this->getVar('imgurl'));
+ $imgurl_select->addOptionArray($graph_array);
+ $imgurl_select->setExtra(
+ "onchange='showImgSelected(\"image\", \"imgurl\", \"" . $this->wfdownloads->getConfig('catimage') . "\", \"\", \"" . XOOPS_URL . "\")'"
+ );
+ $imgurl_tray->addElement($imgurl_select, false);
+ $imgurl_tray->addElement( new XoopsFormLabel( '', "<img src='" . XOOPS_URL . "/" . $imgurl_path . "' name='image' id='image' alt='' />" ) );
+ $imgurl_tray->addElement(new XoopsFormFile(_AM_WFDOWNLOADS_BUPLOAD , 'uploadfile', 0), false);
+ $form->addElement($imgurl_tray);
+ // category: description
$description_textarea = new XoopsFormDhtmlTextArea(_AM_WFDOWNLOADS_FCATEGORY_DESCRIPTION, 'description', $this->getVar(
'description',
'e'
), 15, 60);
$form->addElement($description_textarea, true);
-
+ // category: summary
$summary_textarea = new XoopsFormTextArea(_AM_WFDOWNLOADS_FCATEGORY_SUMMARY, 'summary', $this->getVar('summary'), 10, 60);
$form->addElement($summary_textarea);
-
+ // category: dohtml, dosmiley, doxcode, doimage, dobr
$options_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_TEXTOPTIONS, '<br />');
$html_checkbox = new XoopsFormCheckBox('', 'dohtml', $this->getVar('dohtml'));
$html_checkbox->addOption(1, _AM_WFDOWNLOADS_ALLOWHTML);
@@ -158,8 +152,8 @@
$breaks_checkbox->addOption(1, _AM_WFDOWNLOADS_ALLOWBREAK);
$options_tray->addElement($breaks_checkbox);
$form->addElement($options_tray);
-
- // Added Formulize module support (2006/05/04) jpc - start
+ // Formulize module support (2006/05/04) jpc
+ // category: formulize_fid
if (wfdownloads_checkModule('formulize')) {
if (file_exists(XOOPS_ROOT_PATH . "/modules/formulize/include/functions.php")) {
include_once XOOPS_ROOT_PATH . "/modules/formulize/include/functions.php";
@@ -175,8 +169,7 @@
$form->addElement($formulize_forms);
}
}
- // Added Formulize module support (2006/05/04) jpc - end
-
+ // form: button tray
$button_tray = new XoopsFormElementTray('', '');
$button_tray->addElement(new XoopsFormHidden('op', 'save'));
if ($this->isNew()) {
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/class/download.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/class/download.php 2013-10-15 17:41:43 UTC (rev 12175)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/class/download.php 2013-10-15 21:25:44 UTC (rev 12176)
@@ -89,7 +89,7 @@
$this->initVar('doimage', XOBJ_DTYPE_INT, 1, false); // boolean
$this->initVar('dobr', XOBJ_DTYPE_INT, 1, false); // boolean
- // Added Formulize module support (2006/05/04) jpc - start
+ // Added Formulize module support (2006/05/04) jpc
$this->initVar('formulize_idreq', XOBJ_DTYPE_INT, 0);
// Added 3.23
@@ -453,13 +453,17 @@
$sform = new XoopsThemeForm(_MD_WFDOWNLOADS_SUBMITCATHEAD, 'storyform', $_SERVER['REQUEST_URI']);
$sform->setExtra('enctype="multipart/form-data"');
-
+ // download: title
$sform->addElement(new XoopsFormText(_MD_WFDOWNLOADS_FILETITLE, 'title', 50, 255, $this->getVar('title', 'e')), true);
+ // download: url
$sform->addElement(new XoopsFormText(_MD_WFDOWNLOADS_DLURL, 'url', 50, 255, $this->getVar('url', 'e')), false);
if (!$this->isNew()) {
+ // download: filename
$sform->addElement(new XoopsFormHidden('filename', $this->getVar('filename', 'e')));
+ // download: filetype
$sform->addElement(new XoopsFormHidden('filetype', $this->getVar('filetype', 'e')));
}
+ // download: userfile
if (($this->wfdownloads->getConfig('useruploads') && array_intersect($this->wfdownloads->getConfig('useruploadsgroup'), $groups))
|| (wfdownloads_userIsAdmin())
) {
@@ -484,11 +488,12 @@
);
$sform->addElement($userfile_file, false);
}
+ // download: mirror
if ($use_mirrors !== true) {
$sform->addElement(new XoopsFormText(_MD_WFDOWNLOADS_MIRROR, 'mirror', 50, 255, $this->getVar('mirror', 'e')), false);
}
-
- // changed - start - March 4 2006 - jpc
+ // download: cid
+ // Formulize module support (2006/05/04) jpc
if (wfdownloads_checkModule('formulize')) {
$sform->addElement(new XoopsFormHidden('cid', $this->getVar('cid', 'e')));
} else {
@@ -498,52 +503,44 @@
new XoopsFormLabel(_MD_WFDOWNLOADS_CATEGORYC, $categoriesTree->makeSelBox('cid', 'title', "-", $this->getVar('cid', 'e')))
);
}
- // changed - end - March 4 2006 - jpc
- // Changed - start - April 22, 2006 - jwe
if (count($customArray) == 0) {
+ // download: homepagetitle
$sform->addElement(
new XoopsFormText(_MD_WFDOWNLOADS_HOMEPAGETITLEC, 'homepagetitle', 50, 255, $this->getVar('homepagetitle', 'e')),
false
);
+ // download: homepage
$sform->addElement(new XoopsFormText(_MD_WFDOWNLOADS_HOMEPAGEC, 'homepage', 50, 255, $this->getVar('homepage', 'e')), false);
+ // download: version
$sform->addElement(new XoopsFormText(_MD_WFDOWNLOADS_VERSIONC, 'version', 10, 20, $this->getVar('version', 'e')), false);
+ // download: publisher
$sform->addElement(new XoopsFormText(_MD_WFDOWNLOADS_PUBLISHERC, 'publisher', 50, 255, $this->getVar('publisher', 'e')), false);
+ // download: size
$sform->addElement(new XoopsFormText(_MD_WFDOWNLOADS_FILESIZEC, 'size', 10, 20, $this->getVar('size', 'e')), false);
-
+ // download: platform
$platform_array = $this->wfdownloads->getConfig('platform');
$platform_select = new XoopsFormSelect(_MD_WFDOWNLOADS_PLATFORMC, 'platform', $this->getVar('platform', 'e'));
$platform_select->addOptionArray($platform_array);
$sform->addElement($platform_select);
-
+ // download: license
$license_array = $this->wfdownloads->getConfig('license');
$license_select = new XoopsFormSelect(_MD_WFDOWNLOADS_LICENCEC, 'license', $this->getVar('license', 'e'));
$license_select->addOptionArray($license_array);
$sform->addElement($license_select);
-
+ // download: limitations
$limitations_array = $this->wfdownloads->getConfig('limitations');
$limitations_select = new XoopsFormSelect(_MD_WFDOWNLOADS_LIMITATIONS, 'limitations', $this->getVar('limitations', 'e'));
$limitations_select->addOptionArray($limitations_array);
$sform->addElement($limitations_select);
-
+ // download: versiontype
$versiontypes_array = $this->wfdownloads->getConfig('versiontypes');
$versiontypes_select = new XoopsFormSelect(_MD_WFDOWNLOADS_VERSIONTYPES, 'versiontypes', $this->getVar('versiontypes', 'e'));
$versiontypes_select->addOptionArray($versiontypes_array);
$sform->addElement($versiontypes_select);
-
+ // download: price
$sform->addElement(new XoopsFormText(_MD_WFDOWNLOADS_PRICEC, 'price', 10, 20, $this->getVar('price', 'e')), false);
- /*
- if ($this->wfdownloads->getConfig('autosummary') == true) {
- $summary_dhtmltextarea = new XoopsFormDhtmlTextArea(_MD_WFDOWNLOADS_SUMMARY, 'summary', $this->getVar('summary', 'e'), 10, 60, 'smartHiddenSummary');
- $summary_dhtmltextarea->setDescription(_MD_WFDOWNLOADS_SUMMARY_DESC_AUTOSUMMARY_ON);
- $summary_dhtmltextarea->setExtra('disabled', 'disabled');
- $sform->addElement($summary_dhtmltextarea, false);
- } else {
- $summary_dhtmltextarea = new XoopsFormDhtmlTextArea(_MD_WFDOWNLOADS_SUMMARY, 'summary', $this->getVar('summary', 'e'), 10, 60, 'smartHiddenSummary');
- $summary_dhtmltextarea->setDescription(_MD_WFDOWNLOADS_SUMMARY_DESC_AUTOSUMMARY_OFF);
- $sform->addElement($summary_dhtmltextarea, false);
- }
- */
+ // download: summary
switch ($this->wfdownloads->getConfig('autosummary')) {
case _WFDOWNLOADS_AUTOSUMMARY_YES :
$summary_dhtmltextarea = new XoopsFormDhtmlTextArea(_MD_WFDOWNLOADS_SUMMARY, 'summary', $this->getVar(
@@ -572,7 +569,7 @@
$sform->addElement($summary_dhtmltextarea, false);
break;
}
-
+ // download: description
$description_dhtmltextarea = new XoopsFormDhtmlTextArea(_MD_WFDOWNLOADS_DESCRIPTION, 'description', $this->getVar(
'description',
'e'
@@ -610,14 +607,14 @@
$customArray['groups']
);
}
- // Changed - end - April 22, 2006 - jwe
-
+ // download: dhistory
$sform->addElement(new XoopsFormTextArea(_MD_WFDOWNLOADS_HISTORYC, 'dhistory', $this->getVar('dhistory', 'e'), 7, 60), false);
if (!$this->isNew() && $this->getVar('dhistory', 'n') != "") {
$dhistoryaddedd_textarea = new XoopsFormTextArea(_MD_WFDOWNLOADS_HISTORYD, 'dhistoryaddedd', '', 7, 60);
$dhistoryaddedd_textarea->setDescription(_MD_WFDOWNLOADS_HISTORYD_DESC);
$sform->addElement($dhistoryaddedd_textarea, false);
}
+ // download: screenshot, screenshot2, screenshot3, screenshot4
if (($this->wfdownloads->getConfig('useruploads') && array_intersect($this->wfdownloads->getConfig('useruploadsgroup'), $groups))
|| wfdownloads_userIsAdmin()
) {
@@ -632,12 +629,13 @@
$sform->addElement(new XoopsFormFile(_MD_WFDOWNLOADS_DUPLOADSCRSHOT, 'screenshot4', 0), false);
}
}
+ // download: notifypub
$option_tray = new XoopsFormElementTray(_MD_WFDOWNLOADS_OPTIONS, '<br />');
$notify_checkbox = new XoopsFormCheckBox('', 'notifypub');
$notify_checkbox->addOption(1, _MD_WFDOWNLOADS_NOTIFYAPPROVE);
$option_tray->addElement($notify_checkbox);
$sform->addElement($option_tray);
- // button tray
+ // form: button tray
$button_tray = new XoopsFormElementTray('', '');
if ($this->isNew()) {
$button_tray->addElement(new XoopsFormHidden('op', 'download.save'));
@@ -673,13 +671,15 @@
$sform = new XoopsThemeForm($title, "storyform", $_SERVER['REQUEST_URI']);
$sform->setExtra('enctype="multipart/form-data"');
+ // download: lid
if (!$this->isNew()) {
$sform->addElement(new XoopsFormLabel(_AM_WFDOWNLOADS_FILE_ID, (int)$this->getVar('lid')));
}
+ // download: ipaddress
if ($this->getVar('ipaddress') != "") {
$sform->addElement(new XoopsFormLabel(_AM_WFDOWNLOADS_FILE_IP, $this->getVar('ipaddress')));
}
-
+ // download: title
$titles_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_FILE_TITLE, '<br />');
$titles = new XoopsFormText('', 'title', 50, 255, $this->getVar('title', 'e'));
$titles_tray->addElement($titles);
@@ -687,7 +687,7 @@
$titles_checkbox->addOption(1, _AM_WFDOWNLOADS_FILE_USE_UPLOAD_TITLE);
$titles_tray->addElement($titles_checkbox);
$sform->addElement($titles_tray);
-
+ // download: submitter
if (!$this->isNew()) {
//$sform -> addElement(new XoopsFormText(_AM_WFDOWNLOADS_FILE_SUBMITTERID, 'submitter', 10, 10, $this->getVar('submitter', 'e')), true);
$submitter_select = new XoopsFormSelectUser (_AM_WFDOWNLOADS_FILE_SUBMITTER, 'submitter', false, $this->getVar(
@@ -699,20 +699,17 @@
} else {
$sform->addElement(new XoopsFormHidden('submitter', $xoopsUser->getVar('uid', 'e')));
}
-
+ // download: url
$sform->addElement(new XoopsFormText(_AM_WFDOWNLOADS_FILE_DLURL, 'url', 50, 255, $this->getVar('url', 'e')), false);
+ // download: filename
$sform->addElement(new XoopsFormText(_AM_WFDOWNLOADS_FILE_FILENAME, 'filename', 50, 255, $this->getVar('filename', 'e')), false);
- /*
- $filename_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_FILE_FILENAME);
- $filename_tray->addElement(new XoopsFormLabel($this->getVar('filename')));
- $filename_tray->addElement(new XoopsFormHidden("filename", $this->getVar('filename', 'e')));
- $sform->addElement($filename_tray, false);
- */
+ // download: filetype
$sform->addElement(new XoopsFormText(_AM_WFDOWNLOADS_FILE_FILETYPE, 'filetype', 50, 100, $this->getVar('filetype', 'e')), false);
+ // download: mirror
if ($use_mirrors !== true) {
$sform->addElement(new XoopsFormText(_AM_WFDOWNLOADS_FILE_MIRRORURL, 'mirror', 50, 255, $this->getVar('mirror', 'e')), false);
}
-
+ // download: userfile
$userfile_file = new XoopsFormFile(_MD_WFDOWNLOADS_UPLOAD_FILEC, 'userfile', 0);
$maxFileSize = wfdownloads_bytesToSize1024($this->wfdownloads->getConfig('maxfilesize'));
$criteria = new Criteria('mime_admin', true);
@@ -729,61 +726,58 @@
)
);
$sform->addElement($userfile_file, false);
-
- // changed - start - March 4 2006 - jpc
-// if (file_exists(XOOPS_ROOT_PATH . "/modules/formulize/include/functions.php")) {
-// $sform->addElement(new XoopsFormHidden('cid', $this->getVar('cid', 'e')));
-// } else {
+ // download: cid
$categories = $this->wfdownloads->getHandler('category')->getObjects();
$categoriesTree = new XoopsObjectTree($categories, 'cid', 'pid');
$sform->addElement(
new XoopsFormLabel(_AM_WFDOWNLOADS_FILE_CATEGORY, $categoriesTree->makeSelBox('cid', 'title', '-', $this->getVar('cid', 'e')))
);
-// }
- // changed - end - March 4 2006 - jpc
- // changed and added - start - April 22, 2006 - jwe
if (count($customArray) == 0) {
+ // download: homepagetitle
$sform->addElement(
new XoopsFormText(_AM_WFDOWNLOADS_FILE_HOMEPAGETITLE, 'homepagetitle', 50, 255, $this->getVar('homepagetitle', 'e')),
false
);
+ // download: homepage
$sform->addElement(new XoopsFormText(_AM_WFDOWNLOADS_FILE_HOMEPAGE, 'homepage', 50, 255, $this->getVar('homepage', 'e')), false);
+ // download: version
$sform->addElement(new XoopsFormText(_AM_WFDOWNLOADS_FILE_VERSION, 'version', 10, 20, $this->getVar('version', 'e')), false);
+ // download: publisher
$sform->addElement(new XoopsFormText(_AM_WFDOWNLOADS_FILE_PUBLISHER, 'publisher', 50, 255, $this->getVar('publisher', 'e')), false);
-
+ // download: size
$sform->addElement(new XoopsFormText(_AM_WFDOWNLOADS_FILE_SIZE, 'size', 10, 20, $this->getVar('size', 'e')), false);
-
+ // download: platform
$platform_array = $this->wfdownloads->getConfig('platform');
$platform_select = new XoopsFormSelect('', 'platform', $this->getVar('platform', 'e'), '', '', 0);
$platform_select->addOptionArray($platform_array);
$platform_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_FILE_PLATFORM, ' ');
$platform_tray->addElement($platform_select);
$sform->addElement($platform_tray);
-
+ // download: license
$license_array = $this->wfdownloads->getConfig('license');
$license_select = new XoopsFormSelect('', 'license', $this->getVar('license', 'e'), '', '', 0);
$license_select->addOptionArray($license_array);
$license_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_FILE_LICENCE, ' ');
$license_tray->addElement($license_select);
$sform->addElement($license_tray);
-
+ // download: limitations
$limitations_array = $this->wfdownloads->getConfig('limitations');
$limitations_select = new XoopsFormSelect('', 'limitations', $this->getVar('limitations', 'e'), '', '', 0);
$limitations_select->addOptionArray($limitations_array);
$limitations_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_FILE_LIMITATIONS, ' ');
$limitations_tray->addElement($limitations_select);
$sform->addElement($limitations_tray);
-
+ // download: versiontypes
$versiontypes_array = $this->wfdownloads->getConfig('versiontypes');
$versiontypes_select = new XoopsFormSelect('', 'versiontypes', $this->getVar('versiontypes', 'e'), '', '', 0);
$versiontypes_select->addOptionArray($versiontypes_array);
$versiontypes_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_FILE_VERSIONTYPES, ' ');
$versiontypes_tray->addElement($versiontypes_select);
$sform->addElement($versiontypes_tray);
-
+ // download: versiontypes
$sform->addElement(new XoopsFormText(_AM_WFDOWNLOADS_FILE_PRICE, 'price', 10, 20, $this->getVar('price', 'e')), false);
-
+ // download: summary
$mode = 'html';
$summary_tray = new XoopsFormElementTray(_MD_WFDOWNLOADS_SUMMARY, '<br />');
$options['name'] = 'summary';
@@ -796,13 +790,6 @@
$summary_editor = new XoopsFormEditor('', $this->wfdownloads->getConfig('editor_options'), $options, $nohtml = false,
$onfailure = 'textarea');
$summary_tray->addElement($summary_editor);
- /*
- if ($this->wfdownloads->getConfig('autosummary') == true) {
- $summary_tray->setDescription(_MD_WFDOWNLOADS_SUMMARY_DESC_AUTOSUMMARY_ON);
- } else {
- $summary_tray->setDescription(_MD_WFDOWNLOADS_SUMMARY_DESC_AUTOSUMMARY_OFF);
- }
- */
switch ($this->wfdownloads->getConfig('autosummary')) {
case _WFDOWNLOADS_AUTOSUMMARY_YES :
$summary_tray->setDescription(_MD_WFDOWNLOADS_SUMMARY_DESC_AUTOSUMMARY_YES);
@@ -816,7 +803,7 @@
break;
}
$sform->addElement($summary_tray);
-
+ // download: decription
$description_tray = new XoopsFormElementTray(_MD_WFDOWNLOADS_DESCRIPTION, '<br />');
$options['name'] = 'description';
$options['value'] = $this->getVar('description', 'e');
@@ -829,9 +816,9 @@
$description_tray->addElement($description_editor, true);
$description_tray->setDescription(_MD_WFDOWNLOADS_DESCRIPTION_DESC);
$sform->addElement($description_tray);
-
-
+ // download: features
$sform->addElement(new XoopsFormTextArea(_AM_WFDOWNLOADS_FILE_KEYFEATURES, 'features', $this->getVar('features', 'e'), 7, 60), false);
+ // download: requirements
$sform->addElement(
new XoopsFormTextArea(_AM_WFDOWNLOADS_FILE_REQUIREMENTS, 'requirements', $this->getVar('requirements', 'e'), 7, 60),
false
@@ -839,7 +826,7 @@
} else {
// if we are using a custom form, then add in the form's elements here
- // $sform -> addElement(new XoopsFormDhtmlTextArea(_AM_WFDOWNLOADS_FILE_DESCRIPTION, 'description', $this->getVar('description', 'e'), 15, 60, "smartHiddenDescription"), true);
+ // download: description
$description_tray = new XoopsFormElementTray(_MD_WFDOWNLOADS_DESCRIPTION, '<br />');
$options['name'] = 'description';
$options['value'] = $this->getVar('description', 'e');
@@ -852,7 +839,7 @@
$description_tray->addElement($description_editor, true);
$description_tray->setDescription(_MD_WFDOWNLOADS_DESCRIPTION_DESC);
$sform->addElement($description_tray);
-
+ // download: size
$sform->addElement(new XoopsFormHidden('size', $this->getVar('size', 'e')));
$sform = compileElements(
$customArray['fid'],
@@ -866,13 +853,12 @@
$customArray['groups']
);
}
- // Changed and added - end - April 22, 2006 - jwe
-
+ // download: dhistory
$sform->addElement(new XoopsFormTextArea(_AM_WFDOWNLOADS_FILE_HISTORY, 'dhistory', $this->getVar('dhistory', 'e'), 7, 60), false);
-
if (!$this->isNew() && $this->getVar('dhistory') != "") {
$sform->addElement(new XoopsFormTextArea(_AM_WFDOWNLOADS_FILE_HISTORYD, 'dhistoryaddedd', '', 7, 60), false);
}
+ // download: screenshot
$graph_array = & WfsLists :: getListTypeAsArray(
XOOPS_ROOT_PATH . '/' . $this->wfdownloads->getConfig('screenshots'),
$type = "images"
@@ -899,7 +885,7 @@
);
}
$sform->addElement($indeximage_tray);
-
+ // download: screenshot2
$graph_array2 = & WfsLists :: getListTypeAsArray(
XOOPS_ROOT_PATH . '/' . $this->wfdownloads->getConfig('screenshots'),
$type = "images"
@@ -926,7 +912,7 @@
);
}
$sform->addElement($indeximage_tray2);
-
+ // download: screenshot3
$graph_array3 = & WfsLists :: getListTypeAsArray(
XOOPS_ROOT_PATH . '/' . $this->wfdownloads->getConfig('screenshots'),
$type = "images"
@@ -953,7 +939,7 @@
);
}
$sform->addElement($indeximage_tray3);
-
+ // download: screenshot4
$graph_array4 = & WfsLists :: getListTypeAsArray(
XOOPS_ROOT_PATH . '/' . $this->wfdownloads->getConfig('screenshots'),
$type = "images"
@@ -980,9 +966,8 @@
);
}
$sform->addElement($indeximage_tray4);
-
$sform->insertBreak(sprintf(_AM_WFDOWNLOADS_FILE_MUSTBEVALID, "<b>" . $this->wfdownloads->getConfig('screenshots') . "</b>"), "even");
-
+ // download: published
$publishtext = ($this->isNew() || $this->getVar('published') == 0) ? _AM_WFDOWNLOADS_FILE_SETPUBLISHDATE
: _AM_WFDOWNLOADS_FILE_SETNEWPUBLISHDATE;
if ($this->getVar('published') > time()) {
@@ -994,18 +979,16 @@
: _AM_WFDOWNLOADS_FILE_SETDATETIMEPUBLISH;
$publishdate_checkbox = new XoopsFormCheckBox('', 'publishdateactivate', $ispublished);
$publishdate_checkbox->addOption(1, $publishdates . '<br />');
-
if (!$this->isNew()) {
$sform->addElement(new XoopsFormHidden('was_published', $this->getVar('published', 'e')));
$sform->addElement(new XoopsFormHidden('was_expired', $this->getVar('expired', 'e')));
}
-
$publishdate_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_FILE_PUBLISHDATE, '');
$publishdate_tray->addElement($publishdate_checkbox);
$publishdate_tray->addElement(new XoopsFormDateTime($publishtext, 'published', 15, $this->getVar('published', 'e')));
$publishdate_tray->addElement(new XoopsFormRadioYN(_AM_WFDOWNLOADS_FILE_CLEARPUBLISHDATE, 'clearpublish', 0));
$sform->addElement($publishdate_tray);
-
+ // download: expired
$isexpired = ($this->getVar('expired', 'e') > time()) ? true : false;
$expiredates = ($this->getVar('expired', 'e') > time()) ?
_AM_WFDOWNLOADS_FILE_EXPIREDATESET . formatTimestamp($this->getVar('expired'), 'Y-m-d H:s') : _AM_WFDOWNLOADS_FILE_SETDATETIMEEXPIRE;
@@ -1013,26 +996,25 @@
? _AM_WFDOWNLOADS_FILE_EXPIREWARNING : '';
$expiredate_checkbox = new XoopsFormCheckBox('', 'expiredateactivate', $isexpired);
$expiredate_checkbox->addOption(1, $expiredates . '<br />');
-
$expiredate_tray = new XoopsFormElementTray(_AM_WFDOWNLOADS_FILE_EXPIREDATE . $warning, '');
$expiredate_tray->addElement($expiredate_checkbox);
$expiredate_tray->addElement(new XoopsFormDateTime(_AM_WFDOWNLOADS_FILE_SETEXPIREDATE, 'expired', 15, $this->getVar('expired')));
$expiredate_tray->addElement(new XoopsFormRadioYN(_AM_WFDOWNLOADS_FILE_CLEAREXPIREDATE, 'clearexpire', 0));
$sform->addElement($expiredate_tray);
-
+ // download: offline
$filestatus_radio = new XoopsFormRadioYN(_AM_WFDOWNLOADS_FILE_FILESSTATUS, 'offline', $this->getVar('offline', 'e'));
$sform->addElement($filestatus_radio);
-
+ // download: up_dated
$file_updated_radio = new XoopsFormRadioYN(_AM_WFDOWNLOADS_FILE_SETASUPDATED, 'up_dated', ($this->getVar('updated', 'e') == true));
$sform->addElement($file_updated_radio);
-
+ // download: approved
if (!$this->isNew() && $this->getVar('published') == 0) {
$approved = ($this->getVar('published') == 0) ? false : true;
$approve_checkbox = new XoopsFormCheckBox(_AM_WFDOWNLOADS_FILE_EDITAPPROVE, 'approved', true);
$approve_checkbox->addOption(1, " ");
$sform->addElement($approve_checkbox);
}
-
+ // form: button tray
$button_tray = new XoopsFormElementTray('', '');
$button_tray->addElement(new XoopsFormHidden('op', 'download.save'));
if ($this->isNew()) {
@@ -1061,20 +1043,20 @@
return $sform;
}
- // Added Formulize module support (2006/05/04) jpc - start
+ // Added Formulize module support (2006/05/04) jpc
function getCategoryForm()
{
include XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
include_once(XOOPS_ROOT_PATH . '/class/tree.php');
$sform = new XoopsThemeForm(_MD_WFDOWNLOADS_FFS_SUBMITCATEGORYHEAD, 'storyform', $_SERVER['REQUEST_URI']);
$sform->setExtra('enctype="multipart/form-data"');
-
+ // download: cid
$categories = $this->wfdownloads->getHandler('category')->getUserUpCategories();
$categoriesTree = new XoopsObjectTree($categories, 'cid', 'pid');
$sform->addElement(
new XoopsFormLabel(_MD_WFDOWNLOADS_CATEGORYC, $categoriesTree->makeSelBox('cid', 'title', '-', $this->getVar('cid', 'e')))
);
-
+ // form: button tray
$button_tray = new XoopsFormElementTray('', '');
$button_tray->addElement(new XoopsFormButton('', 'submit_category', _SUBMIT, 'submit'));
if (!$this->isNew()) {
@@ -1085,8 +1067,6 @@
return $sform;
}
- // Added Formulize module support (2006/05/04) jpc - end
-
/**
* Returns an array representation of the object
*
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/class/multicolumnsthemeform.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/class/multicolumnsthemeform.php 2013-10-15 17:41:43 UTC (rev 12175)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/class/multicolumnsthemeform.php 2013-10-15 21:25:44 UTC (rev 12176)
@@ -149,10 +149,10 @@
function render()
{
$ele_name = $this->getName();
- $ret = '';
- $ret .= '<form name="' . $ele_name . '" id="' . $ele_name . '" action="' . $this->getAction() . '" method="' . $this->getMethod() . '" onsubmit="return xoopsFormValidate_' . $ele_name . '();"' . $this->getExtra() . '>' . NWLINE;
- $ret .= '<table width="100%" class="outer" cellspacing="1">' . NWLINE;
- $ret .= '<tr><th colspan="' . $this->_columns . '">' . $this->getTitle() . '</th></tr>' . NWLINE;
+ $ret = "";
+ $ret .= "<form name='{$ele_name}' id='{$ele_name}' action='{$this->getAction()}' method='{$this->getMethod()}' onsubmit='return xoopsFormValidate_{$ele_name}();' {$this->getExtra()} >" . NWLINE;
+ $ret .= "<table width='100%' class='outer' cellspacing='1'>" . NWLINE;
+ $ret .= "<tr><th colspan='{$this->_columns}'>{$this->getTitle()}</th></tr>" . NWLINE;
$hidden = '';
$class = 'even';
for ($row = 0; $row < $this->_rows; $row++) {
@@ -170,13 +170,13 @@
if (!$ele->getNocolspan()) {
//$ret .= '<tr valign="top" align="left"><td class="head">';
if (($caption = $ele->getCaption()) != '') {
- $ret .= '<div class="xoops-form-element-caption' . ($ele->isRequired() ? '-required' : '') . '">';
- $ret .= '<span class="caption-text">' . $caption . '</span>';
- $ret .= '<span class="caption-marker">*</span>';
- $ret .= '</div>';
+ $ret .= "<div class='xoops-form-element-caption" . ($ele->isRequired() ? '-required' : '') . "'>";
+ $ret .= "<span class='caption-text'>{$caption}</span>";
+ $ret .= "<span class='caption-marker'>*</span>";
+ $ret .= "</div>";
}
if (($desc = $ele->getDescription()) != '') {
- $ret .= '<div class="xoops-form-element-help">' . $desc . '</div>';
+ $ret .= "<div class='xoops-form-element-help'>{$desc}</div>";
}
//$ret .= '</td><td class="' . $class . '">';
$ret .= $ele->render();
@@ -184,10 +184,10 @@
} else {
//$ret .= '<tr valign="top" align="left"><td class="head" colspan="2">';
if (($caption = $ele->getCaption()) != '') {
- $ret .= '<div class="xoops-form-element-caption' . ($ele->isRequired() ? '-required' : '') . '">';
- $ret .= '<span class="caption-text">' . $caption . '</span>';
- $ret .= '<span class="caption-marker">*</span>';
- $ret .= '</div>';
+ $ret .= "<div class='xoops-form-element-caption" . ($ele->isRequired() ? '-required' : '') . "'>";
+ $ret .= "<span class='caption-text'>{$caption}</span>";
+ $ret .= "<span class='caption-marker'>*</span>";
+ $ret .= "</div>";
}
//$ret .= '</td></tr>' . NWLINE;
//$ret .= '<tr valign="top" align="left"><td class="' . $class . '" colspan="' . $this->_columns . '">';
@@ -201,9 +201,9 @@
}
$ret .= "</tr>";
}
- $ret .= '</table>' . NWLINE;
- $ret .= ' ' . $hidden . NWLINE;
- $ret .= '</form>' . NWLINE;
+ $ret .= "</table>" . NWLINE;
+ $ret .= "{$hidden}" . NWLINE;
+ $ret .= "</form>" . NWLINE;
$ret .= $this->renderValidationJS(true);
return $ret;
}
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/class/wfdownloads.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/class/wfdownloads.php 2013-10-15 17:41:43 UTC (rev 12175)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/class/wfdownloads.php 2013-10-15 21:25:44 UTC (rev 12176)
@@ -42,6 +42,9 @@
if (!$instance) {
$instance = new self($debug);
}
+//error_log("istance: [" . print_r($istance,true) . "]");
+//phpinfo();
+//debug_print_backtrace ();
return $instance;
}
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/docs/changelog.txt
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/docs/changelog.txt 2013-10-15 17:41:43 UTC (rev 12175)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/docs/changelog.txt 2013-10-15 21:25:44 UTC (rev 12176)
@@ -1,4 +1,4 @@
-<b><u>=> Version 3.23 Beta (2013-10-10)</u></b>
+<b><u>=> Version 3.23 Beta (2013-10-15)</u></b>
- standardization of English language files (cesag)
- fixed: typos in english folder (cesag)
- module standardization: header.php, admin/admin_header.php, xoops_version.php
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/include/functions.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/include/functions.php 2013-10-15 17:41:43 UTC (rev 12175)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/include/functions.php 2013-10-15 21:25:44 UTC (rev 12176)
@@ -975,27 +975,24 @@
*
* @return
**/
-function wfdownloads_createThumb($imgName, $imgPath, $imgSavePath, $width = 100, $height = 100, $quality = 100, $update = 0, $aspect = 1)
+function wfdownloads_createThumb($imgName, $imgPath, $imgSavePath, $width = 100, $height = 100, $quality = 100, $update = false, $aspect = 1)
{
$wfdownloads = WfdownloadsWfdownloads::getInstance();
- // paths
- if ($wfdownloads->getConfig('usethumbs') == 0) {
- $imagePath = XOOPS_URL . "/{$imgPath}/{$imgName}";
-
- return $imagePath;
+ // Paths
+ if ($wfdownloads->getConfig('usethumbs') == false) {
+ $imageURL = XOOPS_URL . "/{$imgPath}/{$imgName}";
+ return $imageURL;
}
- $imagePath = XOOPS_ROOT_PATH . "/{$img_path}/{$imgName}";
-
+ $imagePath = XOOPS_ROOT_PATH . "/{$imgPath}/{$imgName}";
$saveFile = "{$imgPath}/{$imgSavePath}/{$width}x{$height}_{$imgName}";
- $savePath = XOOPS_ROOT_PATH . '/' . $savefile;
+ $savePath = XOOPS_ROOT_PATH . '/' . $saveFile;
// Return the image if no update and image exists
- if ($update == 0 && file_exists($savePath)) {
+ if ($update == false && file_exists($savePath)) {
return XOOPS_URL . '/' . $saveFile;
}
-
+ // Original image info
list($origWidth, $origHeight, $type, $attr) = getimagesize($imagePath, $info);
-
switch ($type) {
case 1:
# GIF image
@@ -1014,12 +1011,13 @@
$img = @imageCreateFromPNG($imagePath);
break;
default...
[truncated message content] |
|
From: <dj...@us...> - 2013-10-15 17:41:46
|
Revision: 12175
http://sourceforge.net/p/xoops/svn/12175
Author: djculex
Date: 2013-10-15 17:41:43 +0000 (Tue, 15 Oct 2013)
Log Message:
-----------
Bugfix : - Fixed problem with following issue when unfriending
Bugfix : - Multible issues with not displaying genderbased avatar if not uploaded.
Bugfix : - Sending notifications on replys to a thread where user is active, new registry, complaints etc
Bugfix : - Error with partnersearch or username search.
Bugfix : - Fixing a few IE special issues (Just gotta love IE :o[ )
Modified Paths:
--------------
XoopsModules/smallworld/trunk/smallworld/class/db.php
XoopsModules/smallworld/trunk/smallworld/class/mail.php
XoopsModules/smallworld/trunk/smallworld/comment_ajax.php
XoopsModules/smallworld/trunk/smallworld/include/functions.php
XoopsModules/smallworld/trunk/smallworld/js/smallworld.js
XoopsModules/smallworld/trunk/smallworld/search.php
Modified: XoopsModules/smallworld/trunk/smallworld/class/db.php
===================================================================
--- XoopsModules/smallworld/trunk/smallworld/class/db.php 2013-10-14 18:48:40 UTC (rev 12174)
+++ XoopsModules/smallworld/trunk/smallworld/class/db.php 2013-10-15 17:41:43 UTC (rev 12175)
@@ -447,7 +447,9 @@
if ($following > 0) {
$sql = "DELETE FROM ".$xoopsDB->prefix('smallworld_followers')." WHERE you = '".intval($friend)."'";
$sql .= " AND me = '".intval($myUid)."'";
- $result = $xoopsDB->queryF($sql);
+ $sql2 = "DELETE FROM ".$xoopsDB->prefix('smallworld_followers')." WHERE me = '".intval($friend)."'";
+ $sql2 .= " AND you = '".intval($myUid)."'";
+ $result2 = $xoopsDB->queryF($sql2);
}
}
@@ -685,7 +687,7 @@
{
global $xoopsDB;
$sql = "SELECT value FROM ".$xoopsDB->prefix('smallworld_settings')." WHERE userid = ".intval($userid)."";
- $result = $xoopsDB->query($sql);
+ $result = $xoopsDB->queryF($sql);
$i = $xoopsDB->getRowsNum($result);
if ($i < 1) {
$posts = serialize(array(
@@ -700,8 +702,9 @@
while ($row=$xoopsDB->fetchArray($result)) {
$data = $row['value'];
}
+ return json_encode(unserialize(stripslashes($data)));
}
- return json_encode(unserialize(stripslashes($data)));
+
}
}
Modified: XoopsModules/smallworld/trunk/smallworld/class/mail.php
===================================================================
--- XoopsModules/smallworld/trunk/smallworld/class/mail.php 2013-10-14 18:48:40 UTC (rev 12174)
+++ XoopsModules/smallworld/trunk/smallworld/class/mail.php 2013-10-15 17:41:43 UTC (rev 12175)
@@ -35,7 +35,7 @@
*/
function sendMails ($fromUserID, $toUserID, $event, $link=null, array $data) {
- global $xoopsConfig, $xoopsUser;
+ global $xoopsConfig, $xoopsUser;
$date = date('m-d-Y H:i:s',time());
$mail = new XoopsMultiMailer;
$wall = new Wall_Updates;
@@ -45,12 +45,11 @@
// From and To user ids
$FromUser = new xoopsUser($fromUserID);
$from_avatar = $wall->Gravatar($fromUserID);
- $from_avatarlink = "<img class='left' src='".XOOPS_URL."/uploads/".$from_avatar."' height='90px' width='90px'>";
+ $from_avatarlink = "<img class='left' src='".smallworld_getAvatarLink($fromUserID, $from_avatar)."' height='90px' width='90px'>";
$ToUser = new xoopsUser($toUserID);
$To_avatar = $wall->Gravatar($toUserID);
- $To_avatarlink = "<img class='left' src='".XOOPS_URL."/uploads/".$To_avatar."' height='90px' width='90px'>";
-
+ $To_avatarlink = "<img class='left' src='".smallworld_getAvatarLink ($toUserID, $To_avatar)."' height='90px' width='90px'>";
// Senders username
$SendName = $FromUser->getVar('uname');
$SendNameUrl = "<a href='".XOOPS_URL."/modules/smallworld/userprofile.php?username=".$SendName."'>".$SendName."</a>";
@@ -64,7 +63,7 @@
$subject = _SMALLWORLD_MAIL_REGISTERSUBJECT.$xoopsConfig['sitename'];
$registername = $SendName;
- $To_avatarlink = "<img class='left' src='".XOOPS_URL."/modules/smallworld/images/genderless.png' height='90px' width='90px'>";
+ $To_avatarlink = "<img class='left' src='".smallworld_getAvatarLink ($fromUserID, $To_avatar)."' height='90px' width='90px'>";
$tpl = new XoopsTpl();
$tpl->assign('registername',$registername);
@@ -112,7 +111,7 @@
$owner = Smallworld_getOwnerFromComment ($data['msg_id_fk']);
$OwnerUser = new xoopsUser($owner);
$Owner_avatar = $wall->Gravatar($owner);
- $Owner_avatarlink = "<img class='left' src='".XOOPS_URL."/uploads/".$Owner_avatar."' height='90px' width='90px'>";
+ $Owner_avatarlink = "<img class='left' src='".smallworld_getAvatarLink ($owner, $Owner_avatar)."' height='90px' width='90px'>";
$OwnerName = $OwnerUser->getVar('uname');
$OwnerNameUrl = "<a href='".XOOPS_URL."/modules/smallworld/userprofile.php?username=".$OwnerName."'>".$OwnerName."</a>";
Modified: XoopsModules/smallworld/trunk/smallworld/comment_ajax.php
===================================================================
--- XoopsModules/smallworld/trunk/smallworld/comment_ajax.php 2013-10-14 18:48:40 UTC (rev 12174)
+++ XoopsModules/smallworld/trunk/smallworld/comment_ajax.php 2013-10-15 17:41:43 UTC (rev 12175)
@@ -24,6 +24,7 @@
include_once (XOOPS_ROOT_PATH.'/class/template.php');
global $xoopsUser, $xoopsModule,$xoopsLogger,$xoopsTpl;
$xoopsLogger->activated = false;
+//error_reporting(E_ALL);
$page = 'index';
$check = new SmallWorldUser;
$id = ($xoopsUser) ? $xoopsUser->getVar('uid'):0;
@@ -61,6 +62,7 @@
$USC = array();
$USC['posts'] = 0;
$USC['comments'] = 0;
+ //$USC['notify'] = 0;
if ($xoopsUser) {
@@ -93,10 +95,10 @@
$wc['avatar_size'] = smallworld_getImageSize(80, 100, $wc['myavatar_link']);
$wc['avatar_highwide'] = smallworld_imageResize($wc['avatar_size'][0], $wc['avatar_size'][1], 35);
$wc['compl_msg_lnk'] = "<a href='".XOOPS_URL."/modules/smallworld/permalink.php?ownerid=".Smallworld_getOwnerFromComment($data['msg_id_fk']);
- $wc['compl_msg_lnk'] .= "&updid=".$cdata['msg_id_fk']."#".$data['com_id']."'>"._SMALLWORLD_COMP_MSG_LNK_DESC."</a>";
+ $wc['compl_msg_lnk'] .= "&updid=".$data['msg_id_fk']."#".$data['com_id']."'>"._SMALLWORLD_COMP_MSG_LNK_DESC."</a>";
$wc['vote_up'] = $Wall->countVotesCom ('com', 'up', $data['msg_id_fk'],$data['com_id']);
$wc['vote_down'] = $Wall->countVotesCom ('com', 'down', $data['msg_id_fk'],$data['com_id']);
-
+
//Send mail if tagged
$permalink = XOOPS_URL."/modules/smallworld/permalink.php?ownerid=".$data['uid_fk']."&updid=".$data['msg_id_fk'];
smallworld_getTagUsers ($wc['comment'],$wc['uid'], $permalink);
@@ -112,10 +114,12 @@
// send mail to user owning update + participans in the thread that a comment has been posted
$parts = $mail->getPartsFromComment ($data['msg_id_fk']);
$emails = "";
- foreach ($parts as $k=>$v) {
+ foreach ($parts as $k => $v) {
$owner = Smallworld_getOwnerFromComment ($data['msg_id_fk']);
+ // Get owner of posts settings in order to send mail or not!
+ $owner_privset = json_decode($dBase->GetSettings($v), true);
if(smallworld_GetModuleOption('smallworldusemailnotis', $repmodule='smallworld') != 0) {
- if ($USC['notify'] == 1) {
+ if ($owner_privset['notify'] == 1) {
$mail->sendMails ($data['uid_fk'], $v, 'commentToWM', $link=null, $wc);
}
}
Modified: XoopsModules/smallworld/trunk/smallworld/include/functions.php
===================================================================
--- XoopsModules/smallworld/trunk/smallworld/include/functions.php 2013-10-14 18:48:40 UTC (rev 12174)
+++ XoopsModules/smallworld/trunk/smallworld/include/functions.php 2013-10-15 17:41:43 UTC (rev 12175)
@@ -569,9 +569,20 @@
while ($r = $xoopsDB->fetchArray($result)) {
$image = $r['userimage'];
}
- if ($image == 'Not specifiyed' || $image == '') {
- $avt = new XoopsUser($uid);
- $avatar = $avt->user_avatar();
+
+ $image = ($image == '' || $image == 'blank.gif') ? smallworld_getAvatarLink($uid, $image) : $image;
+
+ $type = Array(
+ 1 => 'jpg',
+ 2 => 'jpeg',
+ 3 => 'png',
+ 4 => 'gif'
+ );
+
+ $ext = explode(".",$image);
+
+ if (@!in_array(strtolower ($ext[1]), $type) || $image == '') {
+ $avatar = '';
} else {
$avatar = $image;
}
Modified: XoopsModules/smallworld/trunk/smallworld/js/smallworld.js
===================================================================
--- XoopsModules/smallworld/trunk/smallworld/js/smallworld.js 2013-10-14 18:48:40 UTC (rev 12174)
+++ XoopsModules/smallworld/trunk/smallworld/js/smallworld.js 2013-10-15 17:41:43 UTC (rev 12175)
@@ -243,7 +243,7 @@
changeMonth: true,
changeYear: true,
dateFormat: 'yy',
- yearRange: '-100:+0',
+ yearRange: '-100:+0'
});
// Attach jquery-ui datepicker to form.
@@ -332,56 +332,56 @@
}
function extractLast(term) {
- return split( term ).pop();
+ return split( term ).pop();
}
// Attach '@' to comment and message for user tagging
xoops_smallworld(document).ready(function() {
xoops_smallworld("#smallworld_update, .smallworld_comment").bind("keydown", function(event) {
- // if TAB or autocomplete already is active
- if (event.keyCode === 9 && xoops_smallworld(this).data("autocomplete").menu.active) {
- event.preventDefault();
- }
- // if @ is pressed
+ // if TAB or autocomplete already is active
+ if (event.keyCode === 9 && xoops_smallworld(this).data("autocomplete").menu.active) {
+ event.preventDefault();
+ }
+ // if @ is pressed
if (event.keyCode === 50) {
xoops_smallworld(this).autocomplete({
disabled: false,
minLength: 1,
source : function (request, response) {
- xoops_smallworld.ajax({
- // basePath is used for defining contecxt-path of the url.
- url: smallworld_url+ 'partnersearch.php',
- dataType: "json",
- // data to be sent to the server:
- data: {
- term : extractLast(request.term)
- },
- success: function(data,type) {
- //console.log( data);
- items = data;
- response(items);
- },
- error: function(data,type){
- console.log( type);
- }
+ xoops_smallworld.ajax({
+ // basePath is used for defining contecxt-path of the url.
+ url: smallworld_url+ 'search.php',
+ dataType: "json",
+ // data to be sent to the server:
+ data: {
+ term : extractLast(request.term)
+ },
+ success: function(data,type) {
+ //console.log( data);
+ items = data;
+ response(items);
+ },
+ error: function(data,type){
+ console.log( type);
+ }
});
- },
+ },
focus: function() {
return false;
- },
+ },
open: function(event, ui){
- xoops_smallworld("ul.ui-autocomplete li a").each(function(){
- var htmlString = xoops_smallworld(this).html().replace(/</g, '<');
- htmlString = htmlString.replace(/>/g, '>');
- xoops_smallworld(this).html(htmlString);
- xoops_smallworld('.ui-autocomplete.ui-menu').width(200);
- });
+ xoops_smallworld("ul.ui-autocomplete li a").each(function(){
+ var htmlString = xoops_smallworld(this).html().replace(/</g, '<');
+ htmlString = htmlString.replace(/>/g, '>');
+ xoops_smallworld(this).html(htmlString);
+ xoops_smallworld('.ui-autocomplete.ui-menu').width(200);
+ });
},
select: function(event, ui) {
var terms = split_(this.value);
terms.pop();
//Add @ to username
- ui.item.value = "@" + ui.item.value;
+ ui.item.value = "@" + ui.item.value;
terms.push(ui.item.value);
terms.push("");
// Join last username with @
@@ -393,16 +393,16 @@
}
});
} else {
- xoops_smallworld(this).autocomplete({ disabled: true });
- xoops_smallworld(this).autocomplete( "close" );
- }
+ xoops_smallworld(this).autocomplete({ disabled: true });
+ xoops_smallworld(this).autocomplete( "close" );
+ }
});
-});
+});
// Search for partner in smallworld users or accept username
xoops_smallworld(function() {
xoops_smallworld("#partner").autocomplete({
- source: smallworld_url+ 'partnersearch.php',
+ source: smallworld_url+ 'search.php',
minLength:1,
open: function(event, ui){
xoops_smallworld("ul.ui-autocomplete li a").each(function(){
@@ -411,6 +411,9 @@
xoops_smallworld(this).html(htmlString);
xoops_smallworld('.ui-autocomplete.ui-menu').width(200);
});
+ },
+ select: function(event, ui) {
+ xoops_smallworld("input#partner").val(ui.item.value);
}
});
});
Modified: XoopsModules/smallworld/trunk/smallworld/search.php
===================================================================
--- XoopsModules/smallworld/trunk/smallworld/search.php 2013-10-14 18:48:40 UTC (rev 12174)
+++ XoopsModules/smallworld/trunk/smallworld/search.php 2013-10-15 17:41:43 UTC (rev 12175)
@@ -38,18 +38,8 @@
$imageLink = XOOPS_URL.'/uploads/'.trim($row['userimage']);
$imageSize = smallworld_getImageSize(30, 30, $imageLink);
$imageHw = smallworld_imageResize($imageSize[0], $imageSize[1], 30);
- $image = '<img src="'.XOOPS_URL.'/uploads/'.$row['userimage'].'" '.$imageHw.'/>';
- } else {
- if ($row['gender'] == 1) {
- $image = "<img src='".XOOPS_URL."/modules/smallworld/images/ano_woman.png'"." height='30px' width='30px'/>";
- }
- if ($row['gender'] == 2) {
- $image = "<img src='".XOOPS_URL."/modules/smallworld/images/ano_man.png'"." height='30px' width='30px'/>";
- }
- if ($row['gender'] == 0) {
- $image = "<img src='".XOOPS_URL."/modules/smallworld/images/genderless.png'"." height='30px' width='30px'/>";
- }
- }
+ $image = '<img src="'.smallworld_getAvatarLink ($row['userid'], $row['userimage']).'" height="20" />';
+ }
$imageHw = smallworld_imageResize($imageSize[0], $imageSize[1], 30);
$data[] = array(
|
|
From: <txm...@us...> - 2013-10-14 18:48:44
|
Revision: 12174
http://sourceforge.net/p/xoops/svn/12174
Author: txmodxoops
Date: 2013-10-14 18:48:40 +0000 (Mon, 14 Oct 2013)
Log Message:
-----------
Fixed bugs
Modified Paths:
--------------
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/tables.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/language/english/admin.php
Modified: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/tables.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/tables.php 2013-10-13 19:15:38 UTC (rev 12173)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/tables.php 2013-10-14 18:48:40 UTC (rev 12174)
@@ -672,7 +672,7 @@
$pathIcon32 = '../' . $xoopsModule->getInfo('icons32');
if ($action === false) {
- $action = $this->isNew() ? TDMC_URL.'/admin/tables.php?op=create_table&table_mid='.$table_mid : $_SERVER['REQUEST_URI'];
+ $action = $_SERVER['REQUEST_URI'];
$sending = $this->isNew() ? 'table_fields' : 'table_save_fields';
}
$title = $this->isNew() ? sprintf(_AM_TDMCREATE_TABLES_ADD) : sprintf(_AM_TDMCREATE_TABLES_EDIT);
Modified: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/language/english/admin.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/language/english/admin.php 2013-10-13 19:15:38 UTC (rev 12173)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/language/english/admin.php 2013-10-14 18:48:40 UTC (rev 12174)
@@ -213,8 +213,8 @@
define('_AM_TDMCREATE_TABLES_WAITING', "Show Table Waiting");
//1.39
-define('_AM_TDMCREATE_MODULES_MIN_PHP', "Minimum Php");
-define('_AM_TDMCREATE_MODULES_MIN_XOOPS', "Minimum Xoops");
+define('_AM_TDMCREATE_MODULES_MIN_PHP', "Minimum PHP");
+define('_AM_TDMCREATE_MODULES_MIN_XOOPS', "Minimum XOOPS");
define('_AM_TDMCREATE_MODULES_MIN_ADMIN', "Minimum Admin");
define('_AM_TDMCREATE_MODULES_MIN_MYSQL', "Minimum Database");
define('_AM_TDMCREATE_BUILDING_FILES', "Files that have been compiled");
|
|
From: <txm...@us...> - 2013-10-13 19:15:44
|
Revision: 12173
http://sourceforge.net/p/xoops/svn/12173
Author: txmodxoops
Date: 2013-10-13 19:15:38 +0000 (Sun, 13 Oct 2013)
Log Message:
-----------
Updated
Added more files
Fixed bugs for edit and save table_fields
Deleted unnecessary file
Modified Paths:
--------------
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/building.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/includes.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/tables.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_admin_about.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_admin_footer.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_admin_header.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_admin_help.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_admin_index.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_admin_permissions.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_architecture.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_class.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_class_helper.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_header.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_templates_pages.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/include/functions_const.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/language/english/admin.php
Added Paths:
-----------
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/modules.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/structure.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/tables.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/const/const_class_module.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/include/common.php
Removed Paths:
-------------
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/admin_footer.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/admin_header.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/constArch.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/constArchitecture.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/tdmcreate_modules.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/tdmcreate_tables.php
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/32/
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/Hotel_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/My Module_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/MyShop_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/Real Estate_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/Shopper_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/Shopping_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/album_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/ams_slogo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/module1_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/moduleimport_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/realestate_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/travel_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/txmLinks_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/modules/txmrestaurant_logo.png
XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/images/uploads/tables/cat.png
Deleted: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/admin_footer.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/admin_footer.php 2013-10-13 16:21:04 UTC (rev 12172)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/admin_footer.php 2013-10-13 19:15:38 UTC (rev 12173)
@@ -1,26 +0,0 @@
-<?php
-/*
- 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.
- */
-/**
- * tdmcreate module
- *
- * @copyright The XOOPS Project http://sourceforge.net/projects/xoops/
- * @license GNU GPL 2 (http://www.gnu.org/licenses/old-licenses/gpl-2.0.html)
- * @package tdmcreate
- * @since 2.5.0
- * @author Txmod Xoops http://www.txmodxoops.org
- * @version $Id: admin_footer.php 11084 2013-02-23 15:44:20Z timgno $
- */
-echo "<div align='center'><a href='http://www.xoops.org' title='Visit XOOPS' target='_blank'>
- <img src='".$pathIcon32."/xoopsmicrobutton.gif' alt='XOOPS' /></a></div>";
-echo "<div class='center smallsmall italic pad5'>
- <strong>" . $xoopsModule->getVar('name') . "</strong> is maintained by the
- <a href='http://xoops.org/forums/newbb' title='Visit Support Forum' class='tooltip' rel='external'>Support Forum</a></div>";
-xoops_cp_footer();
\ No newline at end of file
Deleted: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/admin_header.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/admin_header.php 2013-10-13 16:21:04 UTC (rev 12172)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/admin_header.php 2013-10-13 19:15:38 UTC (rev 12173)
@@ -1,55 +0,0 @@
-<?php
-/*
- 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.
- */
-/**
- * tdmcreate module
- *
- * @copyright The XOOPS Project http://sourceforge.net/projects/xoops/
- * @license GNU GPL 2 (http://www.gnu.org/licenses/old-licenses/gpl-2.0.html)
- * @package tdmcreate
- * @since 2.5.0
- * @author Txmod Xoops http://www.txmodxoops.org
- * @version $Id: admin_header.php 11084 2013-02-23 15:44:20Z timgno $
- */
-include_once dirname(dirname(dirname(dirname(__FILE__)))) . '/mainfile.php';
-include_once XOOPS_ROOT_PATH . '/include/cp_header.php';
-include_once('../include/functions.php');
-include_once 'includes.php';
-//
-$thisDirname = $GLOBALS['xoopsModule']->getVar('dirname');
-//
-$pathIcon16 = '../' . $xoopsModule->getInfo('icons16');
-$pathIcon32 = '../' . $xoopsModule->getInfo('icons32');
-$pathModuleAdmin = $xoopsModule->getInfo('dirmoduleadmin');
-
-// Get class handler
-$modulesHandler =& xoops_getModuleHandler('tdmcreate_modules', 'TDMCreate');
-$tablesHandler =& xoops_getModuleHandler('tdmcreate_tables', 'TDMCreate');
-//
-$myts =& MyTextSanitizer::getInstance();
-if (!isset($xoopsTpl) || !is_object($xoopsTpl)) {
- include_once(XOOPS_ROOT_PATH."/class/template.php");
- $xoopsTpl = new XoopsTpl();
-}
-//
-$xoopsTpl->assign('pathIcon16', $pathIcon16);
-$xoopsTpl->assign('pathIcon32', $pathIcon32);
-//Load languages
-xoops_loadLanguage('admin', $thisDirname);
-xoops_loadLanguage('modinfo', $thisDirname);
-xoops_loadLanguage('main', $thisDirname);
-// Locad admin menu class
-if ( file_exists($GLOBALS['xoops']->path($pathModuleAdmin.'/moduleadmin.php'))){
- include_once $GLOBALS['xoops']->path($pathModuleAdmin.'/moduleadmin.php');
-}else{
- redirect_header("../../../admin.php", 5, _AM_MODULEADMIN_MISSING, false);
-}
-xoops_cp_header();
-$adminMenu = new ModuleAdmin();
\ No newline at end of file
Modified: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/building.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/building.php 2013-10-13 16:21:04 UTC (rev 12172)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/building.php 2013-10-13 19:15:38 UTC (rev 12173)
@@ -55,7 +55,7 @@
switch ($op) {
case 'build':
// Effacer repertoire of nouveau module s'il existe
- TDMCreate_clearDir($modPath.'/modules/'.$mod_name);
+ TDMCreate_clearDir($modPath.'/modules/'.strtolower($mod_name));
// Debut
TDMCreate_OpenTable(_AM_TDMCREATE_BUILDING_FILES, _AM_TDMCREATE_BUILDING_SUCCESS, _AM_TDMCREATE_BUILDING_FAILED);
/************************************************/
@@ -66,7 +66,7 @@
//Creation of changelog.txt
const_changelog($modules);
- $result = $xoopsDB->queryF("SELECT COUNT(*) FROM " . $xoopsDB->prefix('mod_tdmcreate_tables') . " WHERE table_name = 'mod_".$mod_name."_categories'");
+ $result = $xoopsDB->queryF("SELECT COUNT(*) FROM " . $xoopsDB->prefix('mod_tdmcreate_tables') . " WHERE table_name = 'mod_".strtolower($mod_name)."_categories'");
list( $category ) = $xoopsDB->fetchRow($result);
foreach (array_keys($tables_arr) as $i)
@@ -91,11 +91,11 @@
// Copy of images tables
$table_image1 = $modPath . '/images/uploads/tables/' . $table_image;
if (file_exists($table_image1)) {
- copy($table_image1, $modPath . '/modules/' . $mod_name . '/images/icons/32/' . $table_image);
+ copy($table_image1, $modPath . '/modules/' . strtolower($mod_name) . '/images/icons/32/' . $table_image);
}
// Creation of classes
if ( $table_admin == 1 || $table_user == 1) {
- const_class($modules, $table_name, $table_fieldname, $category, $table_fields, $table_parameters, $table_permissions, $category);
+ const_class($modules, $table_name, $table_fieldname, $table_category, $table_fields, $table_parameters, $table_permissions);
}
// Creation of pages admin
if ( $table_admin == 1 ) {
@@ -150,9 +150,10 @@
// Creation of Waiting Plugin
const_waiting($modules, $tables_arr);
}
- // Creation of class helper & request
+ // Creation of class helper, module & request
if ( $table_name != '' ) {
const_class_helper($modules);
+ const_class_module($modules);
const_class_request($modules);
}
// Creation of xoopsversion.php
Modified: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/includes.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/includes.php 2013-10-13 16:21:04 UTC (rev 12172)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/includes.php 2013-10-13 19:15:38 UTC (rev 12173)
@@ -41,6 +41,7 @@
include_once $cPath.'/const_class.php';
include_once $cPath.'/const_class_helper.php';
include_once $cPath.'/const_class_request.php';
+include_once $cPath.'/const_class_module.php';
include_once $cPath.'/const_admin_header.php';
include_once $cPath.'/const_admin_footer.php';
include_once $cPath.'/const_admin_menu.php';
Modified: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/tables.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/tables.php 2013-10-13 16:21:04 UTC (rev 12172)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/admin/tables.php 2013-10-13 19:15:38 UTC (rev 12173)
@@ -160,9 +160,8 @@
$obj->setVar('table_fields', $table_fields);
$obj->setVar('table_parameters', $table_parameters);
- if ($tablesHandler->insert($obj))
- {
- redirect_header('tables.php', 2, _AM_TDMCREATE_FORMOK);
+ if ($tablesHandler->insert($obj)) {
+ redirect_header('tables.php', 2, _AM_TDMCREATE_FORMOK);
}
break;
@@ -248,10 +247,8 @@
break;
case "edit_table":
- $table_id = TDMCreate_CleanVars( $_REQUEST, 'table_id', 0);
- $table_mid = TDMCreate_CleanVars( $_REQUEST, 'table_mid', 0);
- $obj =& $tablesHandler->get($table_id);
- $form = $obj->getFormTable(false, $table_mid);
+ $obj =& $tablesHandler->get($_REQUEST['table_id']);
+ $form = $obj->getFormTable(false, $_REQUEST['table_mid']);
break;
case "edit_fields":
Deleted: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/constArch.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/constArch.php 2013-10-13 16:21:04 UTC (rev 12172)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/constArch.php 2013-10-13 19:15:38 UTC (rev 12173)
@@ -1,65 +0,0 @@
-/**
- * ****************************************************************************
- * - TXModCreate By TXMod Xoops - TEAM XOOPS MODULE FOR XOOPS
- * - Licence GPL Copyright (c) (http://www.txmodxoops.org)
- *
- * Cette licence, contient des limitations!!!
- *
- * 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.
- *
- * @license TXMod Xoops GPL license
- * @author TXMod Xoops MODULE
- *
- * ****************************************************************************
- */
-if (!defined('XOOPS_ROOT_PATH')) {
- die('XOOPS root path not defined');
-}
-
-class constArch {
- /**
- *
- */
- var $module_name;
- /**
- *
- */
- var $type = null;
- /**
- *
- */
- var $path = null;
- /**
- *
- */
- var $indexFile = XOOPS_ROOT_PATH."/modules/TDMCreate/include/index.html";
- /**
- *
- */
- function __construct(){
-
- }
-
- function constArch($path, $module_name, $type, $folder)
- {
- $this->path = $path;
- $this->module_name = $module_name;
- $this->type = $type;
- $this->folder = $folder;
- }
-
- function makeDir($path, $module_name, $folder)
- {
- $path = XOOPS_ROOT_PATH."/modules/TDMCreate/modules/".$modules_name."/".$folder;
- if(!is_dir($path))
- mkdir($path, 0705);
- chmod($path, 0705);
- copy($this->indexFile, XOOPS_ROOT_PATH."/modules/TDMCreate/modules/".$modules_name."/".$folder."/index.html");
- }
-
-}
\ No newline at end of file
Deleted: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/constArchitecture.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/constArchitecture.php 2013-10-13 16:21:04 UTC (rev 12172)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/constArchitecture.php 2013-10-13 19:15:38 UTC (rev 12173)
@@ -1,132 +0,0 @@
-<?php
-/**
- * ****************************************************************************
- * - TXModCreate By TXMod Xoops - TEAM DEV MODULE & THEMES FOR XOOPS
- * - Licence GPL Copyright (c) (http://www.txmodxoops.org)
- *
- * This license contains restrictions...!!!
- *
- * 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.
- *
- * @license TXMod Xoops GPL license
- * @author TXMod Xoops MODULE
- *
- * @Version 2.0.1 $Id Timgno <in...@tx...>
- * ****************************************************************************
- */
-if (!defined('XOOPS_ROOT_PATH')) {
- die('XOOPS root path not defined');
-}
-
-class constArchitecture {
- /*
- *
- *
- */
- var $module_name = '';
- /*
- *
- *
- */
- var $folder_name = null;
- /*
- *
- *
- */
- var $file_name = null;
- /*
- *
- *
- */
- var $path = null;
- /*
- *
- *
- */
- var $copieFile;
- /*
- * @pubblic function constructor class
- * @param string $path
- */
- function __construct($path) {
- $this->path = $path;
- }
- /*
- * @pubblic function class
- * @param string $path
- */
- function constArchitecture($path)
- {
- $this->__construct($path);
- }
- /*
- * @pubblic function makeDir
- * @param string $path
- */
- function makeDir($path)
- {
- $this->path = $path;
- if(!is_dir($this->path)) {
- mkdir($this->path, 0755);
- chmod($this->path, 0755);
- }
- }
- /*
- * @pubblic function makeDirModule
- * @param string $folder_name
- */
- function makeDirInModule($folder_name)
- {
- $this->folder_name = $folder_name;
- $fname = $this->path . "/" .$this->module_name. "/" .$this->folder_name;
- if(!is_dir($fname)) {
- mkdir($fname, 0755);
- chmod($fname, 0755);
- }
- }
- /*
- * @pubblic function makeDir & copy file
- * @param string $folder_name
- * @param string $copieFile
- * @param string $file
- */
- function makeDirAndCopyFile($folder_name, $copieFile, $file)
- {
- $this->file_name = $file;
- $this->folder_name = $folder_name;
- $this->copieFile = $copieFile;
- $fname = $this->path . "/" .$this->module_name. "/" .$this->folder_name;
- if(!is_dir($fname)) {
- mkdir($fname, 0755);
- chmod($fname, 0755);
- $this->copyFile($this->folder_name, $this->copieFile, $this->file_name);
- } else {
- $this->copyFile($this->folder_name, $this->copieFile, $this->file_name);
- }
- }
- /*
- * @pubblic function copy file
- * @param string $folder_name
- * @param string $copieFile
- * @param string $file
- */
- function copyFile($folder_name, $copieFile, $file)
- {
- $this->file_name = $file;
- $this->folder_name = $folder_name;
- $this->copieFile = $copieFile;
- $fname = $this->path . "/" .$this->module_name. "/" .$this->folder_name. "/". $this->file_name;
- /*if(!file_exists($fname)) {
- chmod($fname, 0777);
- copy($this->copieFile, $fname);
- } else {*/
- copy($this->copieFile, $fname);
- //}
- }
-}
-?>
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/modules.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/modules.php (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/modules.php 2013-10-13 19:15:38 UTC (rev 12173)
@@ -0,0 +1,269 @@
+<?php
+/*
+ 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.
+ */
+
+/**
+ * Xoops Javascript class
+ *
+ * @copyright The XOOPS Project http://sourceforge.net/projects/xoops/
+ * @license GNU GPL 2 (http://www.gnu.org/licenses/old-licenses/gpl-2.0.html)
+ * @package media
+ * @since 2.5.x
+ * @author TDM TEAM DEV MODULE
+ * @version $Id$ modules.php 11114 2013-02-13 10:22:12Z timgno $
+ */
+
+defined('XOOPS_ROOT_PATH') or die('Restricted access');
+
+//include_once 'iconGenerator.php';
+
+class TDMCreateModules extends XoopsObject
+{
+ // constructor
+ function __construct()
+ {
+ $this->XoopsObject();
+ $this->initVar('mod_id',XOBJ_DTYPE_INT, 0);
+ $this->initVar('mod_name',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['name']);
+ $this->initVar('mod_version',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['version']);
+ $this->initVar('mod_since',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['since']);
+ $this->initVar('mod_min_php',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['min_php']);
+ $this->initVar('mod_min_xoops',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['min_xoops']);
+ $this->initVar('mod_min_admin',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['min_admin']);
+ $this->initVar('mod_min_mysql',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['min_mysql']);
+ $this->initVar('mod_description',XOBJ_DTYPE_TXTAREA, $GLOBALS['xoopsModuleConfig']['description']);
+ $this->initVar('mod_author',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['author']);
+ $this->initVar('mod_author_mail',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['author_email']);
+ $this->initVar('mod_author_website_url',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['author_website_url']);
+ $this->initVar('mod_author_website_name',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['author_website_name']);
+ $this->initVar('mod_credits',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['credits']);
+ $this->initVar('mod_license',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['license']);
+ $this->initVar('mod_release_info',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['release_info']);
+ $this->initVar('mod_release_file',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['release_file']);
+ $this->initVar('mod_manual',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['manual']);
+ $this->initVar('mod_manual_file',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['manual_file']);
+ $this->initVar('mod_image',XOBJ_DTYPE_TXTBOX, null);
+ $this->initVar('mod_demo_site_url',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['demo_site_url']);
+ $this->initVar('mod_demo_site_name',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['demo_site_name']);
+ $this->initVar('mod_support_url',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['support_url']);
+ $this->initVar('mod_support_name',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['support_name']);
+ $this->initVar('mod_website_url',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['website_url']);
+ $this->initVar('mod_website_name',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['website_name']);
+ $this->initVar('mod_release',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['release_date']);
+ $this->initVar('mod_status',XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['status']);
+ $this->initVar('mod_admin',XOBJ_DTYPE_INT,$GLOBALS['xoopsModuleConfig']['display_admin']);
+ $this->initVar('mod_user',XOBJ_DTYPE_INT, $GLOBALS['xoopsModuleConfig']['display_user']);
+ $this->initVar('mod_search',XOBJ_DTYPE_INT, $GLOBALS['xoopsModuleConfig']['active_search']);
+ $this->initVar('mod_comments',XOBJ_DTYPE_INT, $GLOBALS['xoopsModuleConfig']['active_comments']);
+ $this->initVar('mod_notifications', XOBJ_DTYPE_INT, $GLOBALS['xoopsModuleConfig']['active_notifications']);
+ $this->initVar('mod_permissions', XOBJ_DTYPE_INT, $GLOBALS['xoopsModuleConfig']['active_permissions']);
+ $this->initVar('mod_install', XOBJ_DTYPE_INT, $GLOBALS['xoopsModuleConfig']['inroot_install']);
+ $this->initVar('mod_donations', XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['donations']);
+ $this->initVar('mod_subversion', XOBJ_DTYPE_TXTBOX, $GLOBALS['xoopsModuleConfig']['subversion']);
+ }
+
+ function getForm($action = false)
+ {
+ global $xoopsModule, $pathIcon32;
+
+ if ($action === false) {
+ $action = $_SERVER['REQUEST_URI'];
+ }
+ $title = $this->isNew() ? sprintf(_AM_TDMCREATE_MODULES_ADD) : sprintf(_AM_TDMCREATE_MODULES_EDIT);
+
+ include_once(XOOPS_ROOT_PATH."/class/xoopsformloader.php");
+
+ $form = new XoopsThemeForm($title, 'modulesform', $action, 'post', true);
+ $form->setExtra('enctype="multipart/form-data"');
+
+ $form->insertBreak('<div class="center"><b>'._AM_TDMCREATE_MODULES_IMPORTANT.'</b></div>','head');
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_NAME, 'mod_name', 50, 255, $this->getVar('mod_name')), true);
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_VERSION, 'mod_version', 10, 25, $this->getVar('mod_version')), true);
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_SINCE, 'mod_since', 10, 25, $this->getVar('mod_since')), true);
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_MIN_PHP, 'mod_min_php', 10, 25, $this->getVar('mod_min_php')), true);
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_MIN_XOOPS, 'mod_min_xoops', 10, 25, $this->getVar('mod_min_xoops')), true);
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_MIN_ADMIN, 'mod_min_admin', 10, 25, $this->getVar('mod_min_admin')), true);
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_MIN_MYSQL, 'mod_min_mysql', 10, 25, $this->getVar('mod_min_mysql')), true);
+ // Name description
+ $editor_configs=array();
+ $editor_configs['name'] = 'mod_description';
+ $editor_configs['value'] = $this->getVar('mod_description', 'e');
+ $editor_configs['rows'] = 5;
+ $editor_configs['cols'] = 100;
+ $editor_configs['width'] = '50%';
+ $editor_configs['height'] = '100px';
+ $editor_configs['editor'] = $GLOBALS['xoopsModuleConfig']['tdmcreate_editor'];
+ $form->addElement( new XoopsFormEditor(_AM_TDMCREATE_MODULES_DESCRIPTION, 'mod_description', $editor_configs), true);
+ // Author
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_AUTHOR, 'mod_author', 50, 255, $this->getVar('mod_author')), true);
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_LICENSE, 'mod_license', 50, 255, $this->getVar('mod_license')), true);
+ $mod_admin = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['display_admin'] : $this->getVar('mod_admin');
+ $form->addElement(new XoopsFormRadioYN(_AM_TDMCREATE_MODULES_DISPLAY_ADMIN, 'mod_admin', $mod_admin, _YES, _NO));
+ $mod_user = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['display_user'] : $this->getVar('mod_user');
+ $form->addElement(new XoopsFormRadioYN(_AM_TDMCREATE_MODULES_DISPLAY_USER, 'mod_user', $mod_user, _YES, _NO));
+ $mod_search = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['active_search'] : $this->getVar('mod_search');
+ $form->addElement(new XoopsFormRadioYN(_AM_TDMCREATE_MODULES_ACTIVE_SEARCH, 'mod_search', $mod_search, _YES, _NO));
+ $mod_comments = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['active_comments'] : $this->getVar('mod_comments');
+ $form->addElement(new XoopsFormRadioYN(_AM_TDMCREATE_MODULES_ACTIVE_COMMENTS, 'mod_comments', $mod_comments, _YES, _NO));
+
+ $mod_notifications = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['active_notifications'] : $this->getVar('mod_notifications');
+ $form->addElement(new XoopsFormRadioYN(_AM_TDMCREATE_MODULES_ACTIVE_NOTIFICATIONS, 'mod_notifications', $mod_notifications, _YES, _NO));
+
+ $mod_permissions = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['active_permissions'] : $this->getVar('mod_permissions');
+ $form->addElement(new XoopsFormRadioYN(_AM_TDMCREATE_MODULES_ACTIVE_PERMISSIONS, 'mod_permissions', $mod_permissions, _YES, _NO));
+
+ $mod_install = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['inroot_install'] : $this->getVar('mod_install');
+ $form->addElement(new XoopsFormRadioYN(_AM_TDMCREATE_MODULES_INROOT_INSTALL, 'mod_install', $mod_install, _YES, _NO));
+
+ $mod_image = $this->getVar('mod_image') ? $this->getVar('mod_image') : 'empty.png';
+
+ $uploadirectory = '/modules/'.$xoopsModule->dirname().'/images/uploads/modules';
+ $imgtray = new XoopsFormElementTray(_AM_TDMCREATE_MODULES_IMAGE, '<br />');
+ $imgpath = sprintf(_AM_TDMCREATE_FORMIMAGE_PATH, './modules/' . $xoopsModule->dirname() . '/images/uploads/modules');
+ $imageselect= new XoopsFormSelect($imgpath, 'mod_image', $mod_image);
+ $mod_image_array = XoopsLists::getImgListAsArray( XOOPS_ROOT_PATH . $uploadirectory );
+ foreach( $mod_image_array as $image ) {
+ $imageselect->addOption("$image", $image);
+ }
+ $imageselect->setExtra( "onchange='showImgSelected(\"image3\", \"mod_image\", \"" . $uploadirectory . "\", \"\", \"" . XOOPS_URL . "\")'" );
+ $imgtray->addElement($imageselect);
+ $imgtray -> addElement( new XoopsFormLabel( '', "<br /><img src='" . XOOPS_URL . "/" . $uploadirectory . "/" . $mod_image . "' name='image3' id='image3' alt='' />" ) );
+
+ $fileseltray = new XoopsFormElementTray('', '<br />');
+ $fileseltray->addElement(new XoopsFormFile(_AM_TDMCREATE_FORMUPLOAD, 'attachedfile', $GLOBALS['xoopsModuleConfig']['maxsize']));
+ $fileseltray->addElement(new XoopsFormLabel(''));
+ $imgtray->addElement($fileseltray);
+ $form->addElement($imgtray);
+
+//---------- START -----------------
+ ?>
+
+ <script type="text/javascript">
+
+ function showImgSelected2(imgId, selectId, imgDir, extra, xoopsUrl) {
+ if (xoopsUrl == null) {
+ xoopsUrl = "./";
+ }
+ imgDom = xoopsGetElementById(imgId);
+ selectDom = xoopsGetElementById(selectId);
+ if (selectDom.options[selectDom.selectedIndex].value != "") {
+ imgDom.src = xoopsUrl + imgDir + "/" + selectDom.options[selectDom.selectedIndex].value + extra;
+ } else {
+ imgDom.src = xoopsUrl + "/modules/TDMCreate/images/uploads/modules/blank.gif";
+ }
+ }
+
+ function createNewModuleLogo(xoopsUrl) { // this is JavaScript function
+
+ iconDom = xoopsGetElementById(image4);
+ iconName = iconDom.src;
+ caption = xoopsGetElementById(mod_name).value;
+ logoDom = xoopsGetElementById(image3);
+ moduleImageDom=xoopsGetElementById(mod_image);
+ moduleImageSelected=moduleImageDom.options[moduleImageDom.selectedIndex].value;
+ $.ajax({
+ type:'GET',
+ url:xoopsUrl + "/modules/TDMCreate/class/logoGenerator.php?f=phpFunction&iconName=" + iconName + "&caption=" + caption,
+ // call php function , phpFunction=function Name , x= parameter
+ data:{},
+ dataType:"html",
+ success:function (data1) {
+ //alert(data1);
+ logoDom.src = data1.split('\n')[0];//the data returned has too many lines. We need only the link to the image
+ logoDom.load; //refresh the logo
+ mycheck=caption+'_logo.png'; //name of the new logo file
+ //if file is not in the list of logo files, add it to the dropdown menu
+ var fileExist;
+ elems = moduleImageDom.options;
+ for (var i = 0, max = elems.length; i < max; i++) {
+ if (moduleImageDom.options[i].text == mycheck){
+ fileExist=true;}
+ }
+
+ if (null == fileExist){
+ var opt = document.createElement("option");
+ document.getElementById("mod_image").options.add(opt);
+ opt.text = mycheck;
+ opt.value = mycheck;
+ }
+ $('#mod_image').load;
+ $('#mod_image').val(mycheck);//change value of selected logo file to the new file
+ }
+ });
+ }
+ </script>
+
+
+ <?php
+ $tables_img = $this->getVar('table_image') ? $this->getVar('table_image') : 'about.png';
+ if(is_dir($pathIcon32)){
+ $uploadirectory = $pathIcon32;
+ }else{
+ $uploadirectory = "/modules/".$xoopsModule->dirname()."/images/uploads/tables";
+ }
+ $createLogoTray = new XoopsFormElementTray('Create new Logo','<br />');
+ if(is_dir($pathIcon32)){
+ $imgpath = sprintf(_AM_TDMCREATE_FORMIMAGE_PATH, ".$pathIcon32");
+ }else{
+ $imgpath = sprintf(_AM_TDMCREATE_FORMIMAGE_PATH, "./modules/".$xoopsModule->dirname()."/images/uploads/tables");
+ }
+ $iconSelect= new XoopsFormSelect($imgpath, 'tables_img', $tables_img, 8);
+ $tables_img_array = XoopsLists :: getImgListAsArray( $uploadirectory );
+ foreach( $tables_img_array as $image ) {
+ $iconSelect->addOption("$image", $image);
+ }
+ $iconSelect->setExtra( "onchange='showImgSelected2(\"image4\", \"tables_img\", \"" . $uploadirectory . "\", \"\", \"" . '' . "\")'" );
+ $createLogoTray->addElement($iconSelect);
+ $createLogoTray -> addElement( new XoopsFormLabel( '', "<br /><img src='" . $pathIcon32 . "/" . $tables_img . "' name='image4' id='image4' alt='' />" ) );
+
+ // Create preview and submit buttons
+ $buttonLogoGenerator4= new XoopsFormButton('', 'button4', "Create New Logo", 'button');
+ $buttonLogoGenerator4->setExtra("onclick='createNewModuleLogo(\"" . XOOPS_URL . "\")'");
+ $createLogoTray->addElement($buttonLogoGenerator4);
+
+ $form->addElement($createLogoTray);
+
+//------------ END --------------------
+
+ $form->insertBreak('<div class="center"><b>'._AM_TDMCREATE_MODULES_NOTIMPORTANT.'</b></div>','head');
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_AUTHOR_MAIL, 'mod_author_mail', 50, 255, $this->getVar('mod_author_mail')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_AUTHOR_WEBSITE_URL, 'mod_author_website_url', 50, 255, $this->getVar('mod_author_website_url')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_AUTHOR_WEBSITE_NAME, 'mod_author_website_name', 50, 255, $this->getVar('mod_author_website_name')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_CREDITS, 'mod_credits', 50, 255, $this->getVar('mod_credits')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_RELEASE_INFO, 'mod_release_info', 50, 255, $this->getVar('mod_release_info')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_RELEASE_FILE, 'mod_release_file', 50, 255, $this->getVar('mod_release_file')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_MANUAL, 'mod_manual', 50, 255, $this->getVar('mod_manual')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_MANUAL_FILE, 'mod_manual_file', 50, 255, $this->getVar('mod_manual_file')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_DEMO_SITE_URL, 'mod_demo_site_url', 50, 255, $this->getVar('mod_demo_site_url')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_DEMO_SITE_NAME, 'mod_demo_site_name', 50, 255, $this->getVar('mod_demo_site_name')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_FORUM_SITE_URL, 'mod_support_url', 50, 255, $this->getVar('mod_support_url')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_FORUM_SITE_NAME, 'mod_support_name', 50, 255, $this->getVar('mod_support_name')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_WEBSITE_URL, 'mod_website_url', 50, 255, $this->getVar('mod_website_url')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_WEBSITE_NAME, 'mod_website_name', 50, 255, $this->getVar('mod_website_name')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_RELEASE, 'mod_release', 50, 255, $this->getVar('mod_release')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_STATUS, 'mod_status', 50, 255, $this->getVar('mod_status')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_PAYPAL_BUTTON, 'mod_donations', 50, 255, $this->getVar('mod_donations')));
+ $form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULES_SUBVERSION, 'mod_subversion', 50, 255, $this->getVar('mod_subversion')));
+
+ $form->addElement(new XoopsFormHidden('op', 'save'));
+ $form->addElement(new XoopsFormButton(_REQUIRED.' <span class="red bold">*</span>', 'submit', _SUBMIT, 'submit'));
+ $form->display();
+ return $form;
+ }
+}
+
+class TDMCreateModulesHandler extends XoopsPersistableObjectHandler
+{
+ function __construct(&$db)
+ {
+ parent::__construct($db, 'mod_tdmcreate_modules', 'tdmcreatemodules', 'mod_id', 'mod_name');
+ }
+}
+?>
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/structure.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/structure.php (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/structure.php 2013-10-13 19:15:38 UTC (rev 12173)
@@ -0,0 +1,131 @@
+<?php
+/*
+ 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.
+ */
+/**
+ * tdmcreate module
+ *
+ * @copyright The XOOPS Project http://sourceforge.net/projects/xoops/
+ * @license GNU GPL 2 (http://www.gnu.org/licenses/old-licenses/gpl-2.0.html)
+ * @package tdmcreate
+ * @since 2.5.0
+ * @author Txmod Xoops http://www.txmodxoops.org
+ * @version $Id: structure.php 11084 2013-02-23 15:44:20Z timgno $
+ */
+if (!defined('XOOPS_ROOT_PATH')) {
+ die('XOOPS root path not defined');
+}
+
+class constArchitecture {
+ /*
+ *
+ *
+ */
+ var $module_name = '';
+ /*
+ *
+ *
+ */
+ var $folder_name = null;
+ /*
+ *
+ *
+ */
+ var $file_name = null;
+ /*
+ *
+ *
+ */
+ var $path = null;
+ /*
+ *
+ *
+ */
+ var $copieFile;
+ /*
+ * @public function constructor class
+ * @param string $path
+ */
+ function __construct($path) {
+ $this->path = $path;
+ }
+ /*
+ * @public function class
+ * @param string $path
+ */
+ function constArchitecture($path)
+ {
+ $this->__construct($path);
+ }
+ /*
+ * @public function makeDir
+ * @param string $path
+ */
+ function makeDir($path)
+ {
+ $this->path = $path;
+ if(!is_dir($this->path)) {
+ mkdir($this->path, 0755);
+ chmod($this->path, 0755);
+ }
+ }
+ /*
+ * @public function makeDirModule
+ * @param string $folder_name
+ */
+ function makeDirInModule($folder_name)
+ {
+ $this->folder_name = $folder_name;
+ $fname = $this->path . '/' .$this->module_name. '/' .$this->folder_name;
+ if(!is_dir($fname)) {
+ mkdir($fname, 0755);
+ chmod($fname, 0755);
+ }
+ }
+ /*
+ * @public function makeDir & copy file
+ * @param string $folder_name
+ * @param string $copieFile
+ * @param string $file
+ */
+ function makeDirAndCopyFile($folder_name, $copieFile, $file)
+ {
+ $this->file_name = $file;
+ $this->folder_name = $folder_name;
+ $this->copieFile = $copieFile;
+ $fname = $this->path . '/' .$this->module_name. '/' .$this->folder_name;
+ if(!is_dir($fname)) {
+ mkdir($fname, 0755);
+ chmod($fname, 0755);
+ $this->copyFile($this->folder_name, $this->copieFile, $this->file_name);
+ } else {
+ $this->copyFile($this->folder_name, $this->copieFile, $this->file_name);
+ }
+ }
+ /*
+ * @public function copy file
+ * @param string $folder_name
+ * @param string $copieFile
+ * @param string $file
+ */
+ function copyFile($folder_name, $copieFile, $file)
+ {
+ $this->file_name = $file;
+ $this->folder_name = $folder_name;
+ $this->copieFile = $copieFile;
+ $fname = $this->path . '/' .$this->module_name. '/' .$this->folder_name. '/'. $this->file_name;
+ /*if(!is_readable($fname)) {
+ chmod($fname, 0777);
+ copy($this->copieFile, $fname);
+ } else {*/
+ copy($this->copieFile, $fname);
+ //}
+ }
+}
+?>
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/tables.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/tables.php (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.39/TDMCreate/class/tables.php 2013-10-13 19:15:38 UTC (rev 12173)
@@ -0,0 +1,892 @@
+<?php
+/*
+ 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.
+ */
+/**
+ * tdmcreate module
+ *
+ * @copyright The XOOPS Project http://sourceforge.net/projects/xoops/
+ * @license GNU GPL 2 (http://www.gnu.org/licenses/old-licenses/gpl-2.0.html)
+ * @package tdmcreate
+ * @since 2.5.0
+ * @author Txmod Xoops http://www.txmodxoops.org
+ * @version $Id: tables.php 11084 2013-02-23 15:44:20Z timgno $
+ */
+if (!defined("XOOPS_ROOT_PATH")) {
+ die("XOOPS root path not defined");
+}
+
+class TDMCreateTables extends XoopsObject
+{
+ //Constructor
+ function __construct()
+ {
+ $this->XoopsObject();
+ $this->initVar('table_id',XOBJ_DTYPE_INT,null,false,5);
+ $this->initVar('table_mid',XOBJ_DTYPE_INT,null,false, 5);
+ $this->initVar('table_category',XOBJ_DTYPE_INT,null,false, 1);
+ $this->initVar('table_name',XOBJ_DTYPE_TXTBOX,null,false);
+ $this->initVar('table_fieldname',XOBJ_DTYPE_TXTBOX,null,false);
+ $this->initVar('table_image',XOBJ_DTYPE_TXTBOX,null,false);
+ $this->initVar('table_nbfields',XOBJ_DTYPE_INT,null,false);
+ $this->initVar('table_fields',XOBJ_DTYPE_TXTBOX,null,false);
+ $this->initVar('table_parameters',XOBJ_DTYPE_TXTBOX,null,false);
+ $this->initVar('table_blocks',XOBJ_DTYPE_INT,null,false, 1);
+ $this->initVar('table_admin',XOBJ_DTYPE_INT,null,false, 1);
+ $this->initVar('table_user',XOBJ_DTYPE_INT,null,false, 1);
+ $this->initVar('table_status',XOBJ_DTYPE_INT,null,false, 1);
+ $this->initVar('table_waiting',XOBJ_DTYPE_INT,null,false, 1);
+ $this->initVar('table_online',XOBJ_DTYPE_INT,null,false, 1);
+ $this->initVar('table_search',XOBJ_DTYPE_INT,null,false, 1);
+ $this->initVar('table_comments',XOBJ_DTYPE_INT,null,false, 1);
+ $this->initVar('table_notifications',XOBJ_DTYPE_INT,null,false, 1);
+ $this->initVar('table_permissions',XOBJ_DTYPE_INT,null,false, 1);
+ }
+
+ //Formulaire de saisi de fields
+ function getFormFields($action = false, $table_id, $table_mid, $table_name, $table_fieldname, $table_blocks, $table_admin, $table_user, $table_status, $table_waiting, $table_online, $table_search, $table_comments, $table_notifications, $table_permissions, $table_nbfields, $select)
+ {
+ global $xoopsDB, $xoopsModule;
+ if ($action === false) {
+ $action = XOOPS_URL.'/modules/TDMCreate/admin/tables.php';
+ }
+ $class = 'even';
+ $title = $this->isNew() ? sprintf(_AM_TDMCREATE_TABLES_FIELDS_ADD) : sprintf(_AM_TDMCREATE_TABLES_FIELDS_EDIT);
+
+ $table_actions = $table_mid.'&table_id='.$table_id.'&table_name='.$table_name.'&table_fieldname='.$table_fieldname.'&table_blocks='.$table_blocks.'&table_admin='.$table_admin.'&table_user='.$table_user.'&table_status='.$table_status.'&table_waiting='.$table_waiting.'&table_online='.$table_online.'&table_search='.$table_search.'&table_comments='.$table_comments.'&table_notifications='.$table_notifications.'&table_permissions='.$table_permissions.'&table_nbfields='.$table_nbfields.'&select='.$select;
+
+ echo "<FORM Method='POST' Action='".$action."?op=save_table&table_mid=".$table_actions."'>
+ <table border='0' width='100%' cellspacing='1' class='outer'>
+ <tr>
+ <td colspan='8' class='head' align='center'>".$title."</td>
+ </tr>
+ <tr class='head'>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_NAME."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_TYPE."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_VALUE."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_ATTRIBUTES."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_NULL."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_DEFAULT."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_INDEX."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_MORE."</td>
+ </tr>";
+ for($i=0; $i<$table_nbfields ; $i++)
+ {
+ $table_id = ( $i == 0 ) ? strtolower($table_fieldname).'_id' : strtolower($table_fieldname).'_';
+ $table_primary = ( $i == 0 ) ? "checked" : "";
+ $table_value = ( $i == 0 ) ? "8" : "";
+
+ $class = ($class == 'even') ? 'odd' : 'even';
+ echo "<tr class=".$class.">
+ <td align='center'><INPUT type='text' size='10' value='".$table_id."' name='fields_name[".$i."]'></td>
+ <td align='center'><SELECT name='fields_type[".$i."]'>
+ <OPTION VALUE='int'>INT</OPTION>
+ <OPTION VALUE='tinyint'>TINYINT</OPTION>
+ <OPTION VALUE='mediumint'>MEDIUMINT</OPTION>
+ <OPTION VALUE='smallint'>SMALLINT</OPTION>
+ <OPTION VALUE='float'>FLOAT</OPTION>
+ <OPTION VALUE='double'>DOUBLE</OPTION>
+ <OPTION VALUE='decimal'>DECIMAL</OPTION>
+ <OPTION VALUE='set'>SET</OPTION>
+ <OPTION VALUE='enum'>ENUM</OPTION>
+ <OPTION VALUE='email'>EMAIL</OPTION>
+ <OPTION VALUE='url'>URL</OPTION>
+ <OPTION VALUE='char'>CHAR</OPTION>
+ <OPTION VALUE='varchar'>VARCHAR</OPTION>
+ <OPTION VALUE='text'>TEXT</OPTION>
+ <OPTION VALUE='tinytext'>TINYTEXT</OPTION>
+ <OPTION VALUE='mediumtext'>MEDIUMTEXT</OPTION>
+ <OPTION VALUE='longtext'>LONGTEXT</OPTION>
+ <OPTION VALUE='date'>DATE</OPTION>
+ <OPTION VALUE='datetime'>DATETIME</OPTION>
+ <OPTION VALUE='timestamp'>TIMESTAMP</OPTION>
+ <OPTION VALUE='time'>TIME</OPTION>
+ <OPTION VALUE='year'>YEAR</OPTION>
+ </SELECT></td>
+ <td align='center'><INPUT type='text' size='2' name='fields_value[".$i."]' value='".$table_value."'></td>
+ <td align='center'><SELECT name='fields_attributes[".$i."]'>
+ <OPTION VALUE=''></OPTION>
+ <OPTION VALUE='unsigned'>UNSIGNED</OPTION>
+ <OPTION VALUE='ON UPDATE CURRENT_TIMESTAMP'>on update CURRENT_TIMESTAMP</OPTION>
+ </SELECT></td>
+ <td align='center'><SELECT name='fields_null[".$i."]'>
+ <OPTION VALUE='not null'>NOT NULL</OPTION>
+ <OPTION VALUE='null'>NULL</OPTION>
+ </SELECT></td>
+ <td align='center'><INPUT type='text' size='2' name='fields_default[".$i."]'></td>
+ <td align='center'><SELECT name='fields_index[".$i."]'>
+ <OPTION VALUE=''></OPTION>
+ <OPTION VALUE='primary'>PRIMARY</OPTION>
+ <OPTION VALUE='unique'>UNIQUE</OPTION>
+ <OPTION VALUE='index'>INDEX</OPTION>
+ <OPTION VALUE='fulltext'>FULLTEXT</OPTION>
+ </SELECT></td>
+ <td align='center'>";
+ if ( $i != 0 ) {
+ echo "<table border='0' style='border-color:#666666'; width='100%' cellspacing='1' class='outer'>
+ <tr>
+ <td align='left' class='head' width='95%'>"._AM_TDMCREATE_TABLES_FIELDS_MORE_ELEMENTS."</td>
+ <td align='right' class='even' width='5%'>
+ <SELECT name='fields_param_elements[".$i."]'>
+ <OPTION VALUE='XoopsFormText'>Text</OPTION>
+ <OPTION VALUE='XoopsFormTextArea'>TextArea</OPTION>
+ <OPTION VALUE='XoopsFormDhtmlTextArea'>DhtmlTextArea</OPTION>
+ <OPTION VALUE='XoopsFormCheckBox'>CheckBox</OPTION>
+ <OPTION VALUE='XoopsFormRadioYN'>RadioYN</OPTION>
+ <OPTION VALUE='XoopsFormSelectUser'>SelectUser</OPTION>
+ <OPTION VALUE='XoopsFormColorPicker'>ColorPicker</OPTION>
+ <OPTION VALUE='XoopsFormUploadImage'>UploadImage</OPTION>
+ <OPTION VALUE='XoopsFormUploadFile'>UploadFile</OPTION>
+ <OPTION VALUE='XoopsFormTextDateSelect'>TextDateSelect</OPTION>";
+ $tablesHandler =& xoops_getModuleHandler('tables', 'TDMCreate');
+ $criteria = new CriteriaCompo();
+ $criteria->add(new Criteria('table_mid', $table_mid));
+ $criteria->setSort('table_name');
+ $criteria->setOrder('ASC');
+ $table_arr1 = $tablesHandler->getAll($criteria);
+
+ foreach (array_keys($table_arr1) as $j)
+ {
+ $table_name1 = $table_arr1[$j]->getVar('table_name');
+ if ( $table_name1 != 'categories' ) {
+ if ( $table_name1 != $table_name )
+ {
+ echo "<OPTION VALUE='XoopsFormTables-".$table_name1."'>Table : ".$table_name1."</OPTION>";
+ }
+ } else {
+ echo "<OPTION VALUE='XoopsFormCategory'>Table : categories</OPTION>";
+ }
+ }
+ echo "
+ </SELECT>
+ </td>
+ <tr>
+ <td align='left' class='head'>"._AM_TDMCREATE_TABLES_FIELDS_MORE_DISPLAY_ADMIN."</td>
+ <td align='right' class='even'><INPUT type='checkbox' size='4' name='fields_param_admin[".$i."]' checked></td>
+ </tr>
+ <tr>
+ <td align='left' class='head'>"._AM_TDMCREATE_TABLES_FIELDS_MORE_DISPLAY_USER."</td>
+ <td align='right' class='even'><INPUT type='checkbox' size='4' name='fields_param_user[".$i."]' checked></td>
+ </tr>
+ ";
+ //Afficher la case blocks
+ if ( $table_blocks == 1 )
+ {
+ //Pour l'affichage dans les blocks
+ $checked_blocks = ( $i == 1 || $i == 2 ) ? "checked" : "";
+ echo "<tr>
+ <td align='left' class='head'>"._AM_TDMCREATE_TABLES_FIELDS_MORE_BLOC."</td>
+ <td align='right' class='even'><INPUT type='checkbox' size='4' name='fields_param_blocks[".$i."]' ".$checked_blocks."></td>
+ </tr>";
+ }
+ $checked_main_field = ( $i == 1 ) ? "checked" : "";
+ echo "
+ <tr>
+ <td align='left' class='head'>"._AM_TDMCREATE_TABLES_FIELDS_MORE_MAIN_FIELD."</td>
+ <td align='right' class='even'><INPUT type='radio' value='".$i."' name='fields_param_main_field' ".$checked_main_field."></td>
+ </tr>";
+
+ //Afficher la case blocks
+ if ( $table_blocks == 1 )
+ {
+ echo "
+ <tr>
+ <td align='left' class='head'>"._AM_TDMCREATE_TABLES_FIELDS_MORE_SEARCH."</td>
+ <td align='right' class='even'><INPUT type='checkbox' size='4' name='fields_param_search_field[".$i."]' checked></td>
+ </tr>";
+ }
+ echo "
+ <tr>
+ <td align='left' class='head'>"._AM_TDMCREATE_TABLES_FIELDS_MORE_REQUIRED."</td>
+ <td align='right' class='even'><INPUT type='checkbox' size='4' name='fields_param_required_field[".$i."]' checked></td>
+ </tr>
+ </table>";
+ }
+ echo "</td></tr>";
+ }
+ echo "<tr>
+ <td colspan='8' class='head' align='right'><input type='submit' value="._AM_TDMCREATE_ADMIN_SUBMIT."></td>
+ </tr>";
+ echo "</table>
+ </FORM>";
+ }
+
+ //Form to Edit Fields
+ function getFormEditFields($action = false, $table_id)
+ {
+ global $xoopsDB, $xoopsModule;
+
+ if ($action === false) {
+ $action = XOOPS_URL.'/modules/TDMCreate/admin/tables.php';
+ }
+
+ $class = 'even';
+ $title = $this->isNew() ? sprintf(_AM_TDMCREATE_TABLES_FIELDS_ADD) : sprintf(_AM_TDMCREATE_TABLES_FIELDS_EDIT);
+ //Donnees
+ //$table_id = $this->getVar('table_id');
+ $table_mid = $this->getVar('table_mid');
+ $table_name = $this->getVar('table_name');
+ $table_fieldname = $this->getVar('table_fieldname');
+ $table_category = $this->getVar('table_category');
+ $table_image = $this->getVar('table_image');
+ $table_nbfields = $this->getVar('table_nbfields');
+ $table_fields = $this->getVar('table_fields');
+ $table_parameters = $this->getVar('table_parameters');
+ $table_blocks = $this->getVar('table_blocks');
+ $table_admin = $this->getVar('table_admin');
+ $table_user = $this->getVar('table_user');
+ $table_status = $this->getVar('table_status');
+ $table_waiting = $this->getVar('table_waiting');
+ $table_online = $this->getVar('table_online');
+ $table_search = $this->getVar('table_search');
+ $table_comments = $this->getVar('table_comments');
+ $table_notifications = $this->getVar('table_notifications');
+ $table_permissions = $this->getVar('table_permissions');
+ $select = 0;
+
+ $fields_total = explode('|', $table_fields);
+ $count_fields = count($fields_total);
+
+ $parameters_total = explode('|', $table_parameters);
+ $count_parameters = count($parameters_total);
+
+ //echo $count_parameters;
+ //fields
+ for($i=0; $i<$table_nbfields; $i++)
+ {
+ if ( $i >= $count_fields ) {
+ $fields_name[$i] = '';
+ $fields_type[$i] = '';
+ $fields_value[$i] = '';
+ $fields_attributes[$i] = '';
+ $fields_null[$i] = '';
+ $fields_default[$i] = '';
+ $fields_index[$i] = '';
+ } else {
+ $fields = explode(":", $fields_total[$i]);
+
+ $fields_name[$i] = $fields[0];
+ $fields_type[$i] = $fields[1];
+ $fields_value[$i] = $fields[2];
+ $fields_attributes[$i] = $fields[3];
+ $fields_null[$i] = $fields[4];
+ $fields_default[$i] = $fields[5];
+ $fields_index[$i] = $fields[6];
+ }
+ }
+ //parameters
+ for($i=0; $i<$table_nbfields; $i++)
+ {
+ if ( $i == 0 || $i > $count_parameters) {
+ $param_elements[$i] = '0';
+ $param_display_admin[$i] = '0';
+ $param_display_user[$i] = '0';
+ $param_display_blocks[$i] = '0';
+ } else {
+ $parameters = explode(":", $parameters_total[$i-1]);
+ $param_elements[$i] = $parameters[0];
+ $param_display_admin[$i] = $parameters[1];
+ $param_display_user[$i] = $parameters[2];
+ $param_display_blocks[$i] = $parameters[3];
+ $param_display_main_field[$i] = $parameters[4];
+ $fields_param_search_field[$i] = $parameters[5];
+ $fields_param_required_field[$i] = $parameters[6];
+ }
+ }
+ $table_action = $table_mid.'&table_id='.$table_id.'&table_name='.$table_name.'&table_fieldname='.$table_fieldname.'&table_blocks='.$table_blocks.'&table_display_admin='.$table_admin.'&table_display_user='.$table_user.'&table_status='.$table_status.'&table_waiting='.$table_waiting.'&table_online='.$table_online.'&table_search='.$table_search.'&table_comments='.$table_comments.'&table_notifications='.$table_notifications.'&table_permissions='.$table_permissions.'&table_nbfields='.$table_nbfields.'&select='.$select;
+
+ echo "<FORM Method='POST' Action='".$action."?op=save_table&table_mid=".$table_action."'>
+ <table border='0' width='100%' cellspacing='1' class='outer'>
+ <tr>
+ <td colspan='8' class='head' align='center'>".$title."</td>
+ </tr>
+ <tr class='head'>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_NAME."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_TYPE."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_VALUE."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_ATTRIBUTES."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_NULL."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_DEFAULT."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_INDEX."</td>
+ <td align='center'>"._AM_TDMCREATE_TABLES_FIELDS_MORE."</td>
+ </tr>";
+ for($i=0; $i<$table_nbfields ; $i++)
+ {
+ $class = ($class == 'even') ? 'odd' : 'even';
+ echo "<tr class=".$class.">
+ <td align='center'><INPUT type='text' size='9' value='".$fields_name[$i]."' name='fields_name[".$i."]'></td>
+ <td align='center'><SELECT name='fields_type[".$i."]'>";
+ if ( $fields_type[$i] == 'int' ) {
+ echo "<OPTION VALUE='int' selected>INT</OPTION>";
+ } else {
+ echo "<OPTION VALUE='int'>INT</OPTION>";
+ }
+ if ( $fields_type[$i] == 'tinyint' ) {
+ echo "<OPTION VALUE='tinyint' selected>TINYINT</OPTION>";
+ } else {
+ echo "<OPTION VALUE='tinyint'>TINYINT</OPTION>";
+ }
+ if ( $fields_type[$i] == 'mediumint' ) {
+ echo "<OPTION VALUE='mediumint' selected>MEDIUMINT</OPTION>";
+ } else {
+ echo "<OPTION VALUE='mediumint'>MEDIUMINT</OPTION>";
+ }
+ if ( $fields_type[$i] == 'smallint' ) {
+ echo "<OPTION VALUE='smallint' selected>SMALLINT</OPTION>";
+ } else {
+ echo "<OPTION VALUE='smallint'>SMALLINT</OPTION>";
+ }
+ if ( $fields_type[$i] == 'float' ) {
+ echo "<OPTION VALUE='float' selected>FLOAT</OPTION>";
+ } else {
+ echo "<OPTION VALUE='float'>FLOAT</OPTION>";
+ }
+ if ( $fields_type[$i] == 'double' ) {
+ echo "<OPTION VALUE='double' selected>DOUBLE</OPTION>";
+ } else {
+ echo "<OPTION VALUE='double'>DOUBLE</OPTION>";
+ }
+ if ( $fields_type[$i] == 'decimal' ) {
+ echo "<OPTION VALUE='decimal' selected>DECIMAL</OPTION>";
+ } else {
+ echo "<OPTION VALUE='decimal'>DECIMAL</OPTION>";
+ }
+ if ( $fields_type[$i] == 'set' ) {
+ echo "<OPTION VALUE='set' selected>SET</OPTION>";
+ } else {
+ echo "<OPTION VALUE='set'>SET</OPTION>";
+ }
+ if ( $fields_type[$i] == 'enum' ) {
+ echo "<OPTION VALUE='enum' selected>ENUM</OPTION>";
+ } else {
+ echo "<OPTION VALUE='enum'>ENUM</OPTION>";
+ }
+ if ( $fields_type[$i] == 'email' ) {
+ echo "<OPTION VALUE='email' selected>EMAIL</OPTION>";
+ } else {
+ echo "<OPTION VALUE='email'>EMAIL</OPTION>";
+ }
+ if ( $fields_type[$i] == 'url' ) {
+ echo "<OPTION VALUE='url' selected>URL</OPTION>";
+ } else {
+ echo "<OPTION VALUE='url'>URL</OPTION>";
+ }
+ if ( $fields_type[$i] == 'char' ) {
+ echo "<OPTION VALUE='char' selected>CHAR</OPTION>";
+ } else {
+ echo "<OPTION VALUE='char'>CHAR</OPTION>";
+ }
+ if ( $fields_type[$i] == 'varchar' ) {
+ echo "<OPTION VALUE='varchar' selected>VARCHAR</OPTION>";
+ } else {
+ echo "<OPTION VALUE='varchar'>VARCHAR</OPTION>";
+ }
+ if ( $fields_type[$i] == 'text' ) {
+ echo "<OPTION VALUE='text' selected>TEXT</OPTION>";
+ } else {
+ echo "<OPTION VALUE='text'>TEXT</OPTION>";
+ }
+ if ( $fields_type[$i] == 'tinytext' ) {
+ echo "<OPTION VALUE='tinytext' selected>TINYTEXT</OPTION>";
+ } else {
+ echo "<OPTION VALUE='tinytext'>TINYTEXT</OPTION>";
+ }
+ if ( $fields_type[$i] == 'mediumtext' ) {
+ echo "<OPTION VALUE='mediumtext' selected>MEDIUMTEXT</OPTION>";
+ } else {
+ echo "<OPTION VALUE='mediumtext'>MEDIUMTEXT</OPTION>";
+ }
+ if ( $fields_type[$i]...
[truncated message content] |
|
From: <txm...@us...> - 2013-10-13 16:21:06
|
Revision: 12172
http://sourceforge.net/p/xoops/svn/12172
Author: txmodxoops
Date: 2013-10-13 16:21:04 +0000 (Sun, 13 Oct 2013)
Log Message:
-----------
Added for module TDMCreate
Added Paths:
-----------
XoopsCore/branches/2.5.x/2.5.7/htdocs/Frameworks/moduleclasses/icons/16/blank.gif
XoopsCore/branches/2.5.x/2.5.7/htdocs/Frameworks/moduleclasses/icons/32/blank.gif
Added: XoopsCore/branches/2.5.x/2.5.7/htdocs/Frameworks/moduleclasses/icons/16/blank.gif
===================================================================
(Binary files differ)
Index: XoopsCore/branches/2.5.x/2.5.7/htdocs/Frameworks/moduleclasses/icons/16/blank.gif
===================================================================
--- XoopsCore/branches/2.5.x/2.5.7/htdocs/Frameworks/moduleclasses/icons/16/blank.gif 2013-10-13 02:15:04 UTC (rev 12171)
+++ XoopsCore/branches/2.5.x/2.5.7/htdocs/Frameworks/moduleclasses/icons/16/blank.gif 2013-10-13 16:21:04 UTC (rev 12172)
Property changes on: XoopsCore/branches/2.5.x/2.5.7/htdocs/Frameworks/moduleclasses/icons/16/blank.gif
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: XoopsCore/branches/2.5.x/2.5.7/htdocs/Frameworks/moduleclasses/icons/32/blank.gif
===================================================================
(Binary files differ)
Index: XoopsCore/branches/2.5.x/2.5.7/htdocs/Frameworks/moduleclasses/icons/32/blank.gif
===================================================================
--- XoopsCore/branches/2.5.x/2.5.7/htdocs/Frameworks/moduleclasses/icons/32/blank.gif 2013-10-13 02:15:04 UTC (rev 12171)
+++ XoopsCore/branches/2.5.x/2.5.7/htdocs/Frameworks/moduleclasses/icons/32/blank.gif 2013-10-13 16:21:04 UTC (rev 12172)
Property changes on: XoopsCore/branches/2.5.x/2.5.7/htdocs/Frameworks/moduleclasses/icons/32/blank.gif
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
|
|
From: <ce...@us...> - 2013-10-13 02:15:07
|
Revision: 12171
http://sourceforge.net/p/xoops/svn/12171
Author: cesag
Date: 2013-10-13 02:15:04 +0000 (Sun, 13 Oct 2013)
Log Message:
-----------
Fixed an error when sending Captcha (Montuy337513 alias black_beard)
Modified Paths:
--------------
XoopsModules/contact/trunk/contact/class/contact.php
XoopsModules/contact/trunk/contact/docs/changelog.txt
XoopsModules/contact/trunk/contact/index.php
Modified: XoopsModules/contact/trunk/contact/class/contact.php
===================================================================
--- XoopsModules/contact/trunk/contact/class/contact.php 2013-10-13 02:02:44 UTC (rev 12170)
+++ XoopsModules/contact/trunk/contact/class/contact.php 2013-10-13 02:15:04 UTC (rev 12171)
@@ -129,7 +129,7 @@
|| ($xoopsUser && !$xoopsUserIsAdmin && $xoopsModuleConfig['captchaRegistered'])
) {
xoops_load('XoopsFormCaptcha');
- $form->addElement(new XoopsFormCaptcha('','',false), true);
+ $form->addElement(new XoopsFormCaptcha('','xoopscaptcha',false), true);
}
$form->addElement(new XoopsFormButton('', 'submit', _SUBMIT, 'submit'));
Modified: XoopsModules/contact/trunk/contact/docs/changelog.txt
===================================================================
--- XoopsModules/contact/trunk/contact/docs/changelog.txt 2013-10-13 02:02:44 UTC (rev 12170)
+++ XoopsModules/contact/trunk/contact/docs/changelog.txt 2013-10-13 02:15:04 UTC (rev 12171)
@@ -6,6 +6,7 @@
- PSR-2 code reformatting (mamba)
- making Captcha optional for Anonymous/Registered users (mamba)
- Fixed an error when sending anonymous (mamba)
+- Fixed an error when sending Captcha (Montuy337513 alias black_beard)
Version 1.80 from 2012-1-19
=================================
Modified: XoopsModules/contact/trunk/contact/index.php
===================================================================
--- XoopsModules/contact/trunk/contact/index.php 2013-10-13 02:02:44 UTC (rev 12170)
+++ XoopsModules/contact/trunk/contact/index.php 2013-10-13 02:15:04 UTC (rev 12171)
@@ -47,7 +47,6 @@
redirect_header(XOOPS_URL, 3, _MD_CONTACT_MES_ERROR);
exit();
} else {
-
// check captcha
if ((!$xoopsUser && $xoopsModuleConfig['captchaAnonymous'])
|| ($xoopsUser && !$xoopsUserIsAdmin && $xoopsModuleConfig['captchaRegistered'])
@@ -56,7 +55,6 @@
xoops_load('XoopsCaptcha');
if (class_exists('XoopsFormCaptcha')) {
$xoopsCaptcha = XoopsCaptcha::getInstance();
- $xoopsCaptcha->active = false;
if (!$xoopsCaptcha->verify()) {
// $err[] = $xoopsCaptcha->getMessage();
redirect_header("javascript:history.go(-1)", 1, $xoopsCaptcha->getMessage());
@@ -92,8 +90,8 @@
} else {
$message = _MD_CONTACT_MES_SENDERROR;
}
-
redirect_header(XOOPS_URL, 3, $message);
+ exit();
}
break;
|
|
From: <ce...@us...> - 2013-10-13 02:02:49
|
Revision: 12170
http://sourceforge.net/p/xoops/svn/12170
Author: cesag
Date: 2013-10-13 02:02:44 +0000 (Sun, 13 Oct 2013)
Log Message:
-----------
Fixed an error when sending anonymous (mamba)
Modified Paths:
--------------
XoopsModules/contact/trunk/contact/docs/changelog.txt
XoopsModules/contact/trunk/contact/docs/credits.txt
XoopsModules/contact/trunk/contact/docs/install.txt
XoopsModules/contact/trunk/contact/docs/lang_diff.txt
XoopsModules/contact/trunk/contact/docs/readme.txt
XoopsModules/contact/trunk/contact/index.php
XoopsModules/contact/trunk/contact/language/english/help/help.html
Modified: XoopsModules/contact/trunk/contact/docs/changelog.txt
===================================================================
--- XoopsModules/contact/trunk/contact/docs/changelog.txt 2013-10-11 17:21:28 UTC (rev 12169)
+++ XoopsModules/contact/trunk/contact/docs/changelog.txt 2013-10-13 02:02:44 UTC (rev 12170)
@@ -1,22 +1,23 @@
-Version 1.81 from 2013-02-24
-=================================
-- Rebuild Module (Voltan)
-- English corrections (Cesag)
-- fixed: bug when sending UTF-8 emails (cesag/mamba)
-- PSR-2 code reformatting (mamba)
-- making Captcha optional for Anonymous/Registered users (mamba)
-
-Version 1.80 from 2012-1-19
-=================================
-- Rebuild Module (Voltan)
-
-Version 1.71 from 2011-12-12
-=================================
-- converted to XOOPS Standard Module GUI (Mamba)
-- included ModuleAdmin class from (Mage)
-
-Version 1.70 from 11-08-2010
-=================================
-- added 2.4.x compatibilty (Trabis)
-- added php5.3 compatibilty (Trabis)
-- added error checking while sending emails (Trabis)
+Version 1.81 from 2013-02-24
+=================================
+- Rebuild Module (Voltan)
+- English corrections (Cesag)
+- fixed: bug when sending UTF-8 emails (cesag/mamba)
+- PSR-2 code reformatting (mamba)
+- making Captcha optional for Anonymous/Registered users (mamba)
+- Fixed an error when sending anonymous (mamba)
+
+Version 1.80 from 2012-1-19
+=================================
+- Rebuild Module (Voltan)
+
+Version 1.71 from 2011-12-12
+=================================
+- converted to XOOPS Standard Module GUI (Mamba)
+- included ModuleAdmin class from (Mage)
+
+Version 1.70 from 11-08-2010
+=================================
+- added 2.4.x compatibilty (Trabis)
+- added php5.3 compatibilty (Trabis)
+- added error checking while sending emails (Trabis)
Modified: XoopsModules/contact/trunk/contact/docs/credits.txt
===================================================================
--- XoopsModules/contact/trunk/contact/docs/credits.txt 2013-10-11 17:21:28 UTC (rev 12169)
+++ XoopsModules/contact/trunk/contact/docs/credits.txt 2013-10-13 02:02:44 UTC (rev 12170)
@@ -1,8 +1,8 @@
-Credits
-===============
-
-Originally developed by Kazumi Ono (Onokazu), modified by Ricardo Costa (Trabis)
-
-Updated to XOOPS 2.5.0 Standard GUI by Michael Beck (Mamba), with contributions by Gregory Mage (Mage)
-
-Added DB for saving messages: (Voltan)
+Credits
+===============
+
+Originally developed by Kazumi Ono (Onokazu), modified by Ricardo Costa (Trabis)
+
+Updated to XOOPS 2.5.0 Standard GUI by Michael Beck (Mamba), with contributions by Gregory Mage (Mage)
+
+Added DB for saving messages: (Voltan)
Modified: XoopsModules/contact/trunk/contact/docs/install.txt
===================================================================
--- XoopsModules/contact/trunk/contact/docs/install.txt 2013-10-11 17:21:28 UTC (rev 12169)
+++ XoopsModules/contact/trunk/contact/docs/install.txt 2013-10-13 02:02:44 UTC (rev 12170)
@@ -1,4 +1,4 @@
-INSTALL/UNISTALL
-=================
-
+INSTALL/UNISTALL
+=================
+
In order to install the module please do following:
\ No newline at end of file
Modified: XoopsModules/contact/trunk/contact/docs/lang_diff.txt
===================================================================
--- XoopsModules/contact/trunk/contact/docs/lang_diff.txt 2013-10-11 17:21:28 UTC (rev 12169)
+++ XoopsModules/contact/trunk/contact/docs/lang_diff.txt 2013-10-13 02:02:44 UTC (rev 12170)
@@ -1,29 +1,29 @@
-LANGUAGE DIFFERENCES
-=====================
-
-Below are language differences from a version to next version.
-
-
-in file /language/english/admin.php:
-//1.71
-
-// About.php
-define("_AM_CONTACT_ABOUT_RELEASEDATE", "Released: ");
-define("_AM_CONTACT_ABOUT_UPDATEDATE", "Updated: ");
-define("_AM_CONTACT_ABOUT_AUTHOR", "Author: ");
-define("_AM_CONTACT_ABOUT_CREDITS", "Credits: ");
-define("_AM_CONTACT_ABOUT_LICENSE", "License: ");
-define("_AM_CONTACT_ABOUT_MODULE_STATUS", "Status: ");
-define("_AM_CONTACT_ABOUT_WEBSITE", "Website: ");
-define("_AM_CONTACT_ABOUT_AUTHOR_NAME", "Author name: ");
-define("_AM_CONTACT_ABOUT_CHANGELOG", "Change Log");
-define("_AM_CONTACT_ABOUT_MODULE_INFO", "Module Infos");
-define("_AM_CONTACT_ABOUT_AUTHOR_INFO", "Author Infos");
-define("_AM_CONTACT_ABOUT_DESCRIPTION", "Description: ");
-
-// Configuration
-define("_AM_CONTACT_CONFIG","Configuration Check");
-define("_AM_CONTACT_CONFIG_PHP","Minimum PHP required: %s (your version is %s)");
-define("_AM_CONTACT_CONFIG_XOOPS","Minimum XOOPS required: %s (your version is %s)");
-// Text for Admin footer
+LANGUAGE DIFFERENCES
+=====================
+
+Below are language differences from a version to next version.
+
+
+in file /language/english/admin.php:
+//1.71
+
+// About.php
+define("_AM_CONTACT_ABOUT_RELEASEDATE", "Released: ");
+define("_AM_CONTACT_ABOUT_UPDATEDATE", "Updated: ");
+define("_AM_CONTACT_ABOUT_AUTHOR", "Author: ");
+define("_AM_CONTACT_ABOUT_CREDITS", "Credits: ");
+define("_AM_CONTACT_ABOUT_LICENSE", "License: ");
+define("_AM_CONTACT_ABOUT_MODULE_STATUS", "Status: ");
+define("_AM_CONTACT_ABOUT_WEBSITE", "Website: ");
+define("_AM_CONTACT_ABOUT_AUTHOR_NAME", "Author name: ");
+define("_AM_CONTACT_ABOUT_CHANGELOG", "Change Log");
+define("_AM_CONTACT_ABOUT_MODULE_INFO", "Module Infos");
+define("_AM_CONTACT_ABOUT_AUTHOR_INFO", "Author Infos");
+define("_AM_CONTACT_ABOUT_DESCRIPTION", "Description: ");
+
+// Configuration
+define("_AM_CONTACT_CONFIG","Configuration Check");
+define("_AM_CONTACT_CONFIG_PHP","Minimum PHP required: %s (your version is %s)");
+define("_AM_CONTACT_CONFIG_XOOPS","Minimum XOOPS required: %s (your version is %s)");
+// Text for Admin footer
define("_AM_ADMIN_FOOTER", "<div class='center smallsmall italic pad5'>Contact is maintained by the <a class='tooltip' rel='external' href='http://xoops.org/' title='Visit XOOPS Community'>XOOPS Community</a></div>");
\ No newline at end of file
Modified: XoopsModules/contact/trunk/contact/docs/readme.txt
===================================================================
--- XoopsModules/contact/trunk/contact/docs/readme.txt 2013-10-11 17:21:28 UTC (rev 12169)
+++ XoopsModules/contact/trunk/contact/docs/readme.txt 2013-10-13 02:02:44 UTC (rev 12170)
@@ -1,35 +1,35 @@
-Read Me First
-=============
- 1. License
- _____________________________________________________________________
-
- This source code is released under the GPL.
- A copy of the license in provided in this package in the file
- named LICENSE.txt
-
-2. What is CONTACT?
- _____________________________________________________________________
-
- CONTACT is a XOOPS module designed to provide XOOPS website with Contact Us area.
- This module provides Contact Information Area which can be configurated by adminstrator panel.
-
- 3. Requirements
- _____________________________________________________________________
-
- - PHP version >= 5.2.0
- - ModuleClasses in /Frameworks (download it from here: http://goo.gl/Bmknt)
-
-
- 4. Installation
- _____________________________________________________________________
-
- Simply upload these module folder to a directory of your xoops modules folder,
- and install it via xoops modules administration panel. You can configure
- it through Contact module control panel.
- Detailed instructions on installing modules are available in the
- XOOPS Operations Manual (http://goo.gl/adT2i)
-
- 5. Tutorial
-_____________________________________________________________________
-
- You can find a more detailed Tutorial here: http://goo.gl/bz94i
+Read Me First
+=============
+ 1. License
+ _____________________________________________________________________
+
+ This source code is released under the GPL.
+ A copy of the license in provided in this package in the file
+ named LICENSE.txt
+
+2. What is CONTACT?
+ _____________________________________________________________________
+
+ CONTACT is a XOOPS module designed to provide XOOPS website with Contact Us area.
+ This module provides Contact Information Area which can be configurated by adminstrator panel.
+
+ 3. Requirements
+ _____________________________________________________________________
+
+ - PHP version >= 5.2.0
+ - ModuleClasses in /Frameworks (download it from here: http://goo.gl/Bmknt)
+
+
+ 4. Installation
+ _____________________________________________________________________
+
+ Simply upload these module folder to a directory of your xoops modules folder,
+ and install it via xoops modules administration panel. You can configure
+ it through Contact module control panel.
+ Detailed instructions on installing modules are available in the
+ XOOPS Operations Manual (http://goo.gl/adT2i)
+
+ 5. Tutorial
+_____________________________________________________________________
+
+ You can find a more detailed Tutorial here: http://goo.gl/bz94i
Modified: XoopsModules/contact/trunk/contact/index.php
===================================================================
--- XoopsModules/contact/trunk/contact/index.php 2013-10-11 17:21:28 UTC (rev 12169)
+++ XoopsModules/contact/trunk/contact/index.php 2013-10-13 02:02:44 UTC (rev 12170)
@@ -42,7 +42,8 @@
case 'save':
- if (empty($_POST['submit']) | !$GLOBALS['xoopsSecurity']->check()) {
+// if (empty($_POST['submit']) | !$GLOBALS['xoopsSecurity']->check()) { //mb
+ if (empty($_POST['submit']) ) {
redirect_header(XOOPS_URL, 3, _MD_CONTACT_MES_ERROR);
exit();
} else {
@@ -55,6 +56,7 @@
xoops_load('XoopsCaptcha');
if (class_exists('XoopsFormCaptcha')) {
$xoopsCaptcha = XoopsCaptcha::getInstance();
+ $xoopsCaptcha->active = false;
if (!$xoopsCaptcha->verify()) {
// $err[] = $xoopsCaptcha->getMessage();
redirect_header("javascript:history.go(-1)", 1, $xoopsCaptcha->getMessage());
@@ -82,7 +84,7 @@
}
}
- // send mail can seet message
+ // send mail can send message
if ($sendmail = true) {
$message = $contact_handler->Contact_SendMail($contact);
} elseif ($saveinfo = true) {
Modified: XoopsModules/contact/trunk/contact/language/english/help/help.html
===================================================================
--- XoopsModules/contact/trunk/contact/language/english/help/help.html 2013-10-11 17:21:28 UTC (rev 12169)
+++ XoopsModules/contact/trunk/contact/language/english/help/help.html 2013-10-13 02:02:44 UTC (rev 12170)
@@ -1,32 +1,32 @@
-<div id="help-template" class="outer">
- <h1 class="head">Help:
- <a class="ui-corner-all tooltip" href="<{$xoops_url}>/modules/contact/admin/index.php"
- title="Back to the administration of Contact"> Contact
- <img src="<{xoAdminIcons home.png}>"
- alt="Back to the Administration of Contact"/>
- </a></h1>
-
- <h4 class="odd">Description</h4><br/>
-
- 'Contact Us' is a very simple module. It provides a Main Menu link to a
- contact form that visitors can use to email the website Administrator.
-
-
- You can set the content of the Contact Us form in 'Preferences'<br/><br/>
-
- <h4 class="odd">Install/uninstall</h4><br/>
-
- No special measures necessary, follow the standard installation process –
- extract the /contact folder into the ../modules directory. Install the
- module through Admin -> System Module -> Modules. <br/><br/>
- Detailed instructions on installing modules are available in the
- <a href="http://goo.gl/adT2i">XOOPS Operations Manual</a><br/><br/>
-
-
- <h4 class="odd">Operating instructions</h4><br/>
- There is nothing really to do on the Admin site, except setting preferences.<br/><br/>
- <h4 class="odd">Tutorial</h4><br/>
-
- You can find a more detailed Tutorial <a href="http://goo.gl/bz94i">here</a><br/>
-
+<div id="help-template" class="outer">
+ <h1 class="head">Help:
+ <a class="ui-corner-all tooltip" href="<{$xoops_url}>/modules/contact/admin/index.php"
+ title="Back to the administration of Contact"> Contact
+ <img src="<{xoAdminIcons home.png}>"
+ alt="Back to the Administration of Contact"/>
+ </a></h1>
+
+ <h4 class="odd">Description</h4><br/>
+
+ 'Contact Us' is a very simple module. It provides a Main Menu link to a
+ contact form that visitors can use to email the website Administrator.
+
+
+ You can set the content of the Contact Us form in 'Preferences'<br/><br/>
+
+ <h4 class="odd">Install/uninstall</h4><br/>
+
+ No special measures necessary, follow the standard installation process –
+ extract the /contact folder into the ../modules directory. Install the
+ module through Admin -> System Module -> Modules. <br/><br/>
+ Detailed instructions on installing modules are available in the
+ <a href="http://goo.gl/adT2i">XOOPS Operations Manual</a><br/><br/>
+
+
+ <h4 class="odd">Operating instructions</h4><br/>
+ There is nothing really to do on the Admin site, except setting preferences.<br/><br/>
+ <h4 class="odd">Tutorial</h4><br/>
+
+ You can find a more detailed Tutorial <a href="http://goo.gl/bz94i">here</a><br/>
+
</div>
\ No newline at end of file
|
|
From: <dj...@us...> - 2013-10-11 17:21:33
|
Revision: 12169
http://sourceforge.net/p/xoops/svn/12169
Author: djculex
Date: 2013-10-11 17:21:28 +0000 (Fri, 11 Oct 2013)
Log Message:
-----------
- Bugfix : Redirect and permission mayhem (Thanks Cesag)
Modified Paths:
--------------
XoopsModules/smallworld/trunk/smallworld/class/user.php
XoopsModules/smallworld/trunk/smallworld/comment_ajax.php
XoopsModules/smallworld/trunk/smallworld/message_ajax.php
XoopsModules/smallworld/trunk/smallworld/register.php
Modified: XoopsModules/smallworld/trunk/smallworld/class/user.php
===================================================================
--- XoopsModules/smallworld/trunk/smallworld/class/user.php 2013-10-10 12:50:52 UTC (rev 12168)
+++ XoopsModules/smallworld/trunk/smallworld/class/user.php 2013-10-11 17:21:28 UTC (rev 12169)
@@ -229,7 +229,7 @@
return Smallworld_array_flatten($data,0);
}
} else {
- redirect_header(XOOPS_URL . "/modules/smallworld/register.php");
+ //redirect_header(XOOPS_URL . "/modules/smallworld/register.php");
}
}
}
Modified: XoopsModules/smallworld/trunk/smallworld/comment_ajax.php
===================================================================
--- XoopsModules/smallworld/trunk/smallworld/comment_ajax.php 2013-10-10 12:50:52 UTC (rev 12168)
+++ XoopsModules/smallworld/trunk/smallworld/comment_ajax.php 2013-10-11 17:21:28 UTC (rev 12169)
@@ -26,7 +26,7 @@
$xoopsLogger->activated = false;
$page = 'index';
$check = new SmallWorldUser;
-$id = $xoopsUser->getVar('uid');
+$id = ($xoopsUser) ? $xoopsUser->getVar('uid'):0;
$profile = ($xoopsUser) ? $check->checkIfProfile($id) : 0;
if ($profile >= 2) {
Modified: XoopsModules/smallworld/trunk/smallworld/message_ajax.php
===================================================================
--- XoopsModules/smallworld/trunk/smallworld/message_ajax.php 2013-10-10 12:50:52 UTC (rev 12168)
+++ XoopsModules/smallworld/trunk/smallworld/message_ajax.php 2013-10-11 17:21:28 UTC (rev 12169)
@@ -27,7 +27,7 @@
$xoopsLogger->activated = false;
//error_reporting(E_ALL);
$page = 'index';
-$id = $xoopsUser->getVar('uid');
+$id = ($xoopsUser) ? $xoopsUser->getVar('uid'):0;
$check = new SmallWorldUser;
$profile = ($xoopsUser) ? $check->checkIfProfile($id) : 0;
Modified: XoopsModules/smallworld/trunk/smallworld/register.php
===================================================================
--- XoopsModules/smallworld/trunk/smallworld/register.php 2013-10-10 12:50:52 UTC (rev 12168)
+++ XoopsModules/smallworld/trunk/smallworld/register.php 2013-10-11 17:21:28 UTC (rev 12169)
@@ -289,7 +289,7 @@
}
} else {
- redirect_header(XOOPS_URL . "/user.php", 1, _NOPERM);
+ redirect_header(XOOPS_URL . "/register.php", 1, _NOPERM);
}
include(XOOPS_ROOT_PATH."/footer.php");
?>
\ No newline at end of file
|
|
From: <luc...@us...> - 2013-10-10 12:50:56
|
Revision: 12168
http://sourceforge.net/p/xoops/svn/12168
Author: luciorota
Date: 2013-10-10 12:50:52 +0000 (Thu, 10 Oct 2013)
Log Message:
-----------
fixed: mimetype permissions error
fixed: category permissions error
fixed: user can modify only his downloads/ administrator can modify all downloads
in progress: improved download/modification comparison table
Modified Paths:
--------------
XoopsModules/wfdownloads/trunk/wfdownloads/admin/reportsmodifications.php
XoopsModules/wfdownloads/trunk/wfdownloads/class/download.php
XoopsModules/wfdownloads/trunk/wfdownloads/class/wfdownloads.php
XoopsModules/wfdownloads/trunk/wfdownloads/docs/changelog.txt
XoopsModules/wfdownloads/trunk/wfdownloads/include/common.php
XoopsModules/wfdownloads/trunk/wfdownloads/include/functions.php
XoopsModules/wfdownloads/trunk/wfdownloads/index.php
XoopsModules/wfdownloads/trunk/wfdownloads/language/english/modinfo.php
XoopsModules/wfdownloads/trunk/wfdownloads/submit.php
XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_download.html
XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_viewcat.html
XoopsModules/wfdownloads/trunk/wfdownloads/viewcat.php
XoopsModules/wfdownloads/trunk/wfdownloads/xoops_version.php
Added Paths:
-----------
XoopsModules/wfdownloads/trunk/wfdownloads/class/multicolumnsthemeform.php
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/admin/reportsmodifications.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/admin/reportsmodifications.php 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/admin/reportsmodifications.php 2013-10-10 12:50:52 UTC (rev 12168)
@@ -65,16 +65,24 @@
$requestid = WfdownloadsRequest::getInt('requestid', 0);
$modification = $wfdownloads->getHandler('modification')->get($requestid);
+ $modify_user = new XoopsUser($modification->getVar('modifysubmitter'));
+ $modifyname = XoopsUserUtility::getUnameFromId((int)$modify_user->getVar('uid'));
+ $modifyemail = $modify_user->getVar('email');
+
$download = $wfdownloads->getHandler('download')->get($modification->getVar('lid'));
-
$orig_user = new XoopsUser($download->getVar('submitter'));
$submittername = XoopsUserUtility::getUnameFromId($download->getVar('submitter')); // $orig_user->getvar("uname");
$submitteremail = $orig_user->getVar('email');
+
wfdownloads_xoops_cp_header();
echo "<div><b>" . _AM_WFDOWNLOADS_MOD_MODPOSTER . "</b> $submittername</div>";
$not_allowed = array('lid', 'submitter', 'requestid', 'modifysubmitter');
+// IN PROGRESS
+// IN PROGRESS
+// IN PROGRESS
+// IN PROGRESS ORG FROM HERE
$sform = new XoopsThemeForm(_AM_WFDOWNLOADS_MOD_ORIGINAL, 'storyform', 'index.php');
$keys = $download->getVars();
@@ -141,10 +149,6 @@
}
$sform->display();
- $modify_user = new XoopsUser($modification->getVar('modifysubmitter'));
- $modifyname = XoopsUserUtility::getUnameFromId((int)$modify_user->getVar('uid'));
- $modifyemail = $modify_user->getVar('email');
-
echo "<div><b>" . _AM_WFDOWNLOADS_MOD_MODIFYSUBMITTER . "</b> $modifyname</div>";
$sform = new XoopsThemeForm(_AM_WFDOWNLOADS_MOD_PROPOSED, 'storyform', 'reportsmodifications.php');
$keys = $modification->getVars();
@@ -226,6 +230,130 @@
$sform->addElement($button_tray);
$sform->display();
+// IN PROGRESS
+// IN PROGRESS
+// IN PROGRESS
+// IN PROGRESS NEW FROM HERE
+
+echo "<div><b>" . _AM_WFDOWNLOADS_MOD_MODPOSTER . "</b> $submittername</div>";
+echo "<div><b>" . _AM_WFDOWNLOADS_MOD_MODIFYSUBMITTER . "</b> $modifyname</div>";
+
+$mcform = new WfdownloadsMulticolumnsThemeForm(_AM_WFDOWNLOADS_MOD_ORIGINAL, 'storyform', 'index.php');
+
+// Get download keys
+$downloadVars = $download->getVars();
+$downloadKeys = array_keys($downloadVars);
+// Get modification keys
+$modificationVars = $modification->getVars();
+$modificationKeys = array_keys($modificationVars);
+// Get common keys
+$commonKeys = array_intersect($downloadKeys, $modificationKeys);
+// Set not allowed keys
+$notAllowedKeys = array('lid', 'submitter', 'requestid', 'modifysubmitter');
+
+$i = 0;
+//$mcform->addElement(' ', false, 0, 0);
+//$mcform->addElement(_AM_WFDOWNLOADS_MOD_ORIGINAL, false, 0, 1);
+//$mcform->addElement(_AM_WFDOWNLOADS_MOD_PROPOSED, false, 0, 2);
+$i = 1;
+foreach ($commonKeys as $key) {
+ if (in_array($key, $notAllowedKeys)) {
+ continue;
+ }
+ $caption = constant("_AM_WFDOWNLOADS_MOD_" . strtoupper($key));
+ $downloadContent = $download->getVar($key, 'e');
+ $modificationContent = $modification->getVar($key, 'e');
+ // Extra jobs for some keys
+ switch ($key) {
+ case "platform":
+ case "license":
+ case "limitations":
+ case "versiontypes":
+ $tempArray = $wfdownloads->getConfig($key);
+ $downloadContent = isset($tempArray[$download->getVar($key)]) ? $tempArray[$download->getVar($key)] : '';
+ //
+ $modificationContent = isset($tempArray[$modification->getVar($key)]) ? $tempArray[$modification->getVar($key)] : '';
+ break;
+ case "cid":
+ $category_list = $wfdownloads->getHandler('category')->getObjects(new Criteria("cid", $download->getVar($key)));
+ if (!isset($category_list[0])) continue;
+ $downloadContent = $category_list[0]->getVar('title', 'e');
+ //
+ $category_list = $wfdownloads->getHandler('category')->getObjects(new Criteria("cid", $modification->getVar($key)));
+ if (!isset($category_list[0])) continue;
+ $modificationContent = $category_list[0]->getVar('title', 'e');
+ break;
+ case "screenshot":
+ case "screenshot2":
+ case "screenshot3":
+ case "screenshot4":
+ if ($downloadContent != '') $downloadContent = "<img src='" . XOOPS_URL . "/{$wfdownloads->getConfig('screenshots')}/{$downloadContent}' width='{$wfdownloads->getConfig('shotwidth')}' alt='' title='' />";
+ //
+ if ($modificationContent != '') $modificationContent = "<img src='" . XOOPS_URL . "/{$wfdownloads->getConfig('screenshots')}/{$modificationContent}' width='{$wfdownloads->getConfig('shotwidth')}' alt='' title='' />";
+ break;
+ case "features":
+ case "requirements":
+ if ($downloadContent != '') {
+ $downrequirements = explode('|', trim($downloadContent));
+ $downloadContent = "<ul>";
+ foreach ($downrequirements as $bi) { $downloadContent.= "<li>{$bi}</li>"; }
+ $downloadContent.= "</ul>";
+ }
+ //
+ if ($modificationContent != '') {
+ $downrequirements = explode('|', trim($modificationContent));
+ $modificationContent = "<ul>";
+ foreach ($downrequirements as $bi) { $modificationContent.= "<li>{$bi}</li>"; }
+ $modificationContent.= "</ul>";
+ }
+ break;
+ case "dhistory":
+ $downloadContent = $myts->displayTarea($downloadContent, true, false, false, false, true);
+ //
+ $modificationContent = $myts->displayTarea($modificationContent, true, false, false, false, true);
+ break;
+ }
+ $mcform->addElement($caption, false, $i, 0);
+ $mcform->addElement(new XoopsFormLabel('', $downloadContent), false, $i, 1);
+ $mcform->addElement(new XoopsFormLabel('', $modificationContent), false, $i, 2);
+ $i++;
+}
+$mcform->addElement(' ', false, 0, 0);
+$mcform->addElement(_AM_WFDOWNLOADS_MOD_ORIGINAL, false, 0, 1);
+$mcform->addElement(_AM_WFDOWNLOADS_MOD_PROPOSED, false, 0, 2);
+$mcform->display();
+
+
+
+
+
+
+
+
+
+
+
+
+/*
+ $button_tray = new XoopsFormElementTray('', '');
+ $button_tray->addElement(new XoopsFormHidden('requestid', $requestid));
+ $button_tray->addElement(new XoopsFormHidden('lid', (int)$modification->getVar('lid')));
+ $hidden = new XoopsFormHidden('op', 'modification.change');
+ $button_tray->addElement($hidden);
+ if (!$modification->isNew()) {
+ $approve_button = new XoopsFormButton('', '', _AM_WFDOWNLOADS_BAPPROVE, 'submit');
+ $approve_button->setExtra('onclick="this.form.elements.op.value=\'modification.change\'"');
+ $button_tray->addElement($approve_button);
+ }
+ $ignore_button = new XoopsFormButton('', '', _AM_WFDOWNLOADS_BIGNORE, 'submit');
+ $ignore_button->setExtra('onclick="this.form.elements.op.value=\'modification.ignore\'"');
+ $button_tray->addElement($ignore_button);
+ $sform->addElement($button_tray);
+ $sform->display();
+*/
+
+
+
xoops_cp_footer();
exit();
break;
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/class/download.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/class/download.php 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/class/download.php 2013-10-10 12:50:52 UTC (rev 12168)
@@ -407,7 +407,8 @@
$download['is_updated'] = ($this->getVar('updated') > 0) ? _MD_WFDOWNLOADS_UPDATEDON : _MD_WFDOWNLOADS_SUBMITDATE;
if (is_object($xoopsUser) && $download['isadmin'] != true) {
- $download['useradminlink'] = ((int)($xoopsUser->getvar('uid')) == $this->getVar('submitter')) ? true : false;
+ $download['useradminlink'] = ((int)($xoopsUser->getvar('uid')) == $this->getVar('submitter')) ? true : false; // this definition is not removed for backward compatibility issues
+ $download['issubmitter'] = ((int)($xoopsUser->getvar('uid')) == $this->getVar('submitter')) ? true : false;
}
$sql2 = "SELECT rated FROM " . $xoopsDB->prefix('wfdownloads_reviews') . " WHERE lid = '" . intval($download['id']) . "' AND submit = '1'";
Added: XoopsModules/wfdownloads/trunk/wfdownloads/class/multicolumnsthemeform.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/class/multicolumnsthemeform.php (rev 0)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/class/multicolumnsthemeform.php 2013-10-10 12:50:52 UTC (rev 12168)
@@ -0,0 +1,210 @@
+<?php
+/*
+ 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.
+ */
+/**
+ * WfdownloadsMulticolumnsThemeForm Class
+ *
+ * @copyright The XOOPS Project http://sourceforge.net/projects/xoops/
+ * @license http://www.fsf.org/copyleft/gpl.html GNU public license
+ * @author lucio <luc...@gm...>
+ * @package Wfdownloads
+ * @since 3.23
+ * @version $Id:$
+ */
+
+defined('XOOPS_ROOT_PATH') or die('Restricted access');
+
+xoops_load('XoopsForm');
+
+/**
+ * Form that will output formatted as a HTML table
+ *
+ * No styles and no JavaScript to check for required fields.
+ */
+class WfdownloadsMulticolumnsThemeForm extends XoopsForm
+{
+ /**
+ * number of two-dimensional array (matrix) rows
+ *
+ * @var int
+ */
+ var $_rows = 0;
+
+ /**
+ * return number of rows
+ *
+ * @return int
+ */
+ public function getCountRows()
+ {
+ return $this->_rows;
+ }
+
+ /**
+ * number of two-dimensional array (matrix) columns
+ *
+ * @var int
+ */
+ var $_columns = 0;
+
+ /**
+ * return number of columns
+ *
+ * @return int
+ */
+ public function getCountColumns()
+ {
+ return $this->_columns;
+ }
+
+ /**
+ * two-dimensional array (matrix) of {@link XoopsFormElement} objects
+ *
+ * @var array
+ */
+ var $_elements = array();
+
+ /**
+ * Add an element to the form
+ *
+ * @param object $ &$formElement reference to a {@link XoopsFormElement}
+ * @param bool $required is this a "required" element?
+ * @param int $row two-dimensional array (matrix) row (0 first key)
+ * @param int $column two-dimensional array (matrix) column (0 first key)
+ */
+ public function addElement($formElement, $required = false, $row = null, $column = null)
+ {
+ if (is_null($row))
+ $row = $this->_rows;
+ if (is_null($column))
+ $column = ($this->_columns == 0) ? $this->_columns : $this->_columns - 1; // add new element as new row of the last column
+ if (is_string($formElement)) {
+ $this->_elements[$row][$column] = $formElement;
+ if ($row >= $this->_rows)
+ $this->_rows = $row + 1;
+ if ($column >= $this->_columns)
+ $this->_columns = $column + 1;
+ } elseif (is_subclass_of($formElement, 'xoopsformelement')) {
+ $this->_elements[$row][$column] = &$formElement;
+ if ($row >= $this->_rows)
+ $this->_rows = $row + 1;
+ if ($column >= $this->_columns)
+ $this->_columns = $column + 1;
+ if (! $formElement->isContainer()) {
+ if ($required) {
+ $formElement->_required = true;
+ $this->_required[] = &$formElement;
+ }
+ } else {
+ $required_elements = &$formElement->getRequired();
+ $count = count($required_elements);
+ for ($i = 0; $i < $count; $i ++) {
+ $this->_required[] = &$required_elements[$i];
+ }
+ }
+ }
+ }
+
+ public function addRow($elements)
+ {
+ foreach ($elements as $key => $element) {
+ $this->addElement($element, false, $this->_rows, $key);
+ }
+ }
+
+ public function addColumn($elements)
+ {
+ foreach ($elements as $key => $element) {
+ $this->addElement($element, false, $key, $this->_columns);
+ }
+ }
+
+ public function addForm($form)
+ {
+ foreach ($form->getElements() as $element) {
+ $this->addElement($element, $element->isRequired(), $key, $this->_columns);
+ }
+ }
+
+ /**
+ * create HTML to output the form as a theme-enabled table with validation.
+ *
+ * YOU SHOULD AVOID TO USE THE FOLLOWING Nocolspan METHOD, IT WILL BE REMOVED
+ *
+ * To use the noColspan simply use the following example:
+ *
+ * $colspan = new XoopsFormDhtmlTextArea( '', 'key', $value, '100%', '100%' );
+ * $colspan->setNocolspan();
+ * $form->addElement( $colspan );
+ *
+ * @return string
+ */
+ function render()
+ {
+ $ele_name = $this->getName();
+ $ret = '';
+ $ret .= '<form name="' . $ele_name . '" id="' . $ele_name . '" action="' . $this->getAction() . '" method="' . $this->getMethod() . '" onsubmit="return xoopsFormValidate_' . $ele_name . '();"' . $this->getExtra() . '>' . NWLINE;
+ $ret .= '<table width="100%" class="outer" cellspacing="1">' . NWLINE;
+ $ret .= '<tr><th colspan="' . $this->_columns . '">' . $this->getTitle() . '</th></tr>' . NWLINE;
+ $hidden = '';
+ $class = 'even';
+ for ($row = 0; $row < $this->_rows; $row++) {
+ $ret .= "<tr>";
+ for ($column = 0; $column < $this->_columns; $column++) {
+ $ret .= "<td class='{$class}'>";
+ if (isset($this->_elements[$row][$column])) {
+ $ele = $this->_elements[$row][$column];
+ } else {
+ $ele = ' ';
+ }
+ if (!is_object($ele)) {
+ $ret .= $ele;
+ } else if (!$ele->isHidden()) {
+ if (!$ele->getNocolspan()) {
+ //$ret .= '<tr valign="top" align="left"><td class="head">';
+ if (($caption = $ele->getCaption()) != '') {
+ $ret .= '<div class="xoops-form-element-caption' . ($ele->isRequired() ? '-required' : '') . '">';
+ $ret .= '<span class="caption-text">' . $caption . '</span>';
+ $ret .= '<span class="caption-marker">*</span>';
+ $ret .= '</div>';
+ }
+ if (($desc = $ele->getDescription()) != '') {
+ $ret .= '<div class="xoops-form-element-help">' . $desc . '</div>';
+ }
+ //$ret .= '</td><td class="' . $class . '">';
+ $ret .= $ele->render();
+ //$ret .= '</td></tr>' . NWLINE;
+ } else {
+ //$ret .= '<tr valign="top" align="left"><td class="head" colspan="2">';
+ if (($caption = $ele->getCaption()) != '') {
+ $ret .= '<div class="xoops-form-element-caption' . ($ele->isRequired() ? '-required' : '') . '">';
+ $ret .= '<span class="caption-text">' . $caption . '</span>';
+ $ret .= '<span class="caption-marker">*</span>';
+ $ret .= '</div>';
+ }
+ //$ret .= '</td></tr>' . NWLINE;
+ //$ret .= '<tr valign="top" align="left"><td class="' . $class . '" colspan="' . $this->_columns . '">';
+ $ret .= $ele->render();
+ //$ret .= '</td></tr>' . NWLINE;
+ }
+ } else {
+ $hidden .= $ele->render();
+ }
+ $ret .= "</td>";
+ }
+ $ret .= "</tr>";
+ }
+ $ret .= '</table>' . NWLINE;
+ $ret .= ' ' . $hidden . NWLINE;
+ $ret .= '</form>' . NWLINE;
+ $ret .= $this->renderValidationJS(true);
+ return $ret;
+ }
+}
\ No newline at end of file
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/class/wfdownloads.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/class/wfdownloads.php 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/class/wfdownloads.php 2013-10-10 12:50:52 UTC (rev 12168)
@@ -42,9 +42,6 @@
if (!$instance) {
$instance = new self($debug);
}
-//error_log("istance: [" . print_r($istance,true) . "]");
-//phpinfo();
-//debug_print_backtrace ();
return $instance;
}
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/docs/changelog.txt
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/docs/changelog.txt 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/docs/changelog.txt 2013-10-10 12:50:52 UTC (rev 12168)
@@ -1,4 +1,4 @@
-<b><u>=> Version 3.23 Beta (2013-10-08)</u></b>
+<b><u>=> Version 3.23 Beta (2013-10-10)</u></b>
- standardization of English language files (cesag)
- fixed: typos in english folder (cesag)
- module standardization: header.php, admin/admin_header.php, xoops_version.php
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/include/common.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/include/common.php 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/include/common.php 2013-10-10 12:50:52 UTC (rev 12168)
@@ -38,6 +38,7 @@
include_once WFDOWNLOADS_ROOT_PATH . '/class/wfdownloads.php';
include_once WFDOWNLOADS_ROOT_PATH . '/class/request.php';
include_once WFDOWNLOADS_ROOT_PATH . '/class/breadcrumb.php';
+include_once WFDOWNLOADS_ROOT_PATH . '/class/multicolumnsthemeform.php';
$debug = false;
$wfdownloads = WfdownloadsWfdownloads::getInstance($debug);
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/include/functions.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/include/functions.php 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/include/functions.php 2013-10-10 12:50:52 UTC (rev 12168)
@@ -623,24 +623,24 @@
global $xoopsUser;
$wfdownloads = WfdownloadsWfdownloads::getInstance();
- $submissions = 0;
+ $isSubmissionAllowed = false;
if (is_object($xoopsUser)
&& ($wfdownloads->getConfig('submissions') == _WFDOWNLOADS_SUBMISSIONS_DOWNLOAD
|| $wfdownloads->getConfig('submissions') == _WFDOWNLOADS_SUBMISSIONS_BOTH)
) {
$groups = $xoopsUser->getGroups();
- if (array_intersect($wfdownloads->getConfig('submitarts'), $groups)) {
- $submissions = 1;
+ if (count(array_intersect($wfdownloads->getConfig('submitarts'), $groups)) > 0) {
+ $isSubmissionAllowed = true;
}
} elseif (!is_object($xoopsUser)
&& ($wfdownloads->getConfig('anonpost') == _WFDOWNLOADS_ANONPOST_DOWNLOAD
|| $wfdownloads->getConfig('anonpost') == _WFDOWNLOADS_ANONPOST_BOTH)
) {
- $submissions = 1;
+ $isSubmissionAllowed = true;
}
$toolbar = "[ ";
- if ($submissions == 1) {
+ if ($isSubmissionAllowed == true) {
$category_suffix = !empty($_GET['cid']) ? "?cid=" . (int)$_GET['cid'] : ""; //Added by Lankford
$toolbar .= "<a href='submit.php{$category_suffix}'>" . _MD_WFDOWNLOADS_SUBMITDOWNLOAD . "</a> | ";
}
@@ -1160,10 +1160,12 @@
} else {
$criteria->add(new Criteria('mime_user', true));
}
- $mimetypes = $wfdownloads->getHandler('mimetype')->getObjects($criteria);
- $mimetype = $mimetypes[0];
- $ret = explode(' ', $mimetype->getVar('mime_types'));
-
+ if ($mimetypes = $wfdownloads->getHandler('mimetype')->getObjects($criteria)) {
+ $mimetype = $mimetypes[0];
+ $ret = explode(' ', $mimetype->getVar('mime_types'));
+ } else {
+ $ret = array();
+ }
return $ret;
}
@@ -1192,12 +1194,16 @@
$onlyImages = false
) {
$wfdownloads = WfdownloadsWfdownloads::getInstance();
-
$file = array();
if (empty($allowedMimetypes)) {
$allowedMimetypes = wfdownloads_allowedMimetypes($_FILES['userfile']['name'], $isAdmin);
}
+ if (empty($allowedMimetypes)) {
+ $errors = 'MIME type not allowed';
+ redirect_header($redirectURL, 4, $errors);
+ }
+
$uploadDirectory = $uploadDirectory . '/';
$file_name = $_FILES['userfile']['name'];
@@ -1205,23 +1211,27 @@
$maxImageWidth = $wfdownloads->getConfig('maximgwidth');
$maxImageHeight = $wfdownloads->getConfig('maximgheight');
+ // TO DO: use Xoops XoopsMediaUploader class
if ($onlyImages) {
include_once XOOPS_ROOT_PATH . '/modules/wfdownloads/class/img_uploader.php';
+ //xoops_load('XoopsMediaUploader');
$uploader = new XoopsMediaImgUploader($uploadDirectory, $allowedMimetypes, $maxFileSize, $maxImageWidth, $maxImageHeight);
} else {
include_once XOOPS_ROOT_PATH . '/modules/wfdownloads/class/uploader.php';
+ //xoops_load('XoopsMediaUploader');
$uploader = new XoopsMediaUploader($uploadDirectory, $allowedMimetypes, $maxFileSize, $maxImageWidth, $maxImageHeight);
}
+
$uploader->noAdminSizeCheck(1);
if ($uploader->fetchMedia($_POST['xoops_upload_file'][0])) {
if (!$uploader->upload()) {
$errors = $uploader->getErrors();
unlink($uploadDirectory . $uploader->savedFileName);
- redirect_header($redirectURL, 2, $errors);
+ redirect_header($redirectURL, 4, $errors);
} else {
if ($redirect) {
- redirect_header($redirectURL, 1, _AM_WFDOWNLOADS_UPLOADFILE);
+ redirect_header($redirectURL, 4, _AM_WFDOWNLOADS_UPLOADFILE);
} else {
if (is_file($uploader->savedDestination)) {
// $file['url'] = XOOPS_URL . '/' . $uploadDirectory . '/';
@@ -1236,7 +1246,7 @@
} else {
$errors = $uploader->getErrors();
unlink($uploadDirectory . $uploader->savedFileName);
- redirect_header($redirectURL, 1, $errors);
+ redirect_header($redirectURL, 4, $errors);
}
}
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/index.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/index.php 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/index.php 2013-10-10 12:50:52 UTC (rev 12168)
@@ -31,7 +31,7 @@
) {
// if user is a registered user
$groups = $xoopsUser->getGroups();
- if (array_intersect($xoopsModuleConfig['submitarts'], $groups)) {
+ if (count(array_intersect($wfdownloads->getConfig('submitarts'), $groups)) > 0) {
$isSubmissionAllowed = true;
}
} else {
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/language/english/modinfo.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/language/english/modinfo.php 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/language/english/modinfo.php 2013-10-10 12:50:52 UTC (rev 12168)
@@ -76,13 +76,13 @@
define('_MI_WFDOWNLOADS_CAT_IMGHEIGHT', "Categories images display height");
define('_MI_WFDOWNLOADS_CAT_IMGHEIGHTDSC', "Display height for category image.");
define('_MI_WFDOWNLOADS_ANONPOST', "[submissions] Anonymous user submission");
-define('_MI_WFDOWNLOADS_ANONPOSTDSC', "Allow Anonymous users to submit new Downloads/Mirrors to your website.");
+define('_MI_WFDOWNLOADS_ANONPOSTDSC', "Allow Anonymous users to submit new Downloads and/or Mirrors to your website.");
define('_MI_WFDOWNLOADS_ANONPOST1', "None");
define('_MI_WFDOWNLOADS_ANONPOST2', "Download only");
define('_MI_WFDOWNLOADS_ANONPOST3', "Mirror only");
define('_MI_WFDOWNLOADS_ANONPOST4', "Both");
-define('_MI_WFDOWNLOADS_AUTOAPPROVE', "[submissions] Auto approve submitted Downloads/Mirrors");
-define('_MI_WFDOWNLOADS_AUTOAPPROVEDSC', "Select to approve submitted Downloads/Mirrors without moderation.");
+define('_MI_WFDOWNLOADS_AUTOAPPROVE', "[submissions] Auto approve submitted Downloads and/or Mirrors");
+define('_MI_WFDOWNLOADS_AUTOAPPROVEDSC', "Select to approve submitted Downloads and/or Mirrors without moderation.");
define('_MI_WFDOWNLOADS_AUTOAPPROVE1', "None");
define('_MI_WFDOWNLOADS_AUTOAPPROVE2', "Download only");
define('_MI_WFDOWNLOADS_AUTOAPPROVE3', "Mirror only");
@@ -110,7 +110,7 @@
define('_MI_WFDOWNLOADS_UPLOADMINPOSTS', "Minimum posts required to upload");
define('_MI_WFDOWNLOADS_UPLOADMINPOSTSDSC', "Enter the minimum number of posts required to upload a file.");
define('_MI_WFDOWNLOADS_ALLOWSUBMISS', "[submissions] User submissions");
-define('_MI_WFDOWNLOADS_ALLOWSUBMISSDSC', "Allow users to submit new Downloads/Mirrors.");
+define('_MI_WFDOWNLOADS_ALLOWSUBMISSDSC', "Allow users to submit new Downloads and/or Mirrors.");
define('_MI_WFDOWNLOADS_ALLOWSUBMISS1', "None");
define('_MI_WFDOWNLOADS_ALLOWSUBMISS2', "Download only");
define('_MI_WFDOWNLOADS_ALLOWSUBMISS3', "Mirror only");
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/submit.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/submit.php 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/submit.php 2013-10-10 12:50:52 UTC (rev 12168)
@@ -22,15 +22,15 @@
include 'header.php';
// Check if submissions are allowed
-$submissionsAllowed = false;
+$isSubmissionAllowed = false;
if (is_object($xoopsUser)
&& ($wfdownloads->getConfig('submissions') == _WFDOWNLOADS_SUBMISSIONS_DOWNLOAD
|| $wfdownloads->getConfig('submissions') == _WFDOWNLOADS_SUBMISSIONS_BOTH)
) {
// if user is a registered user
$groups = $xoopsUser->getGroups();
- if (array_intersect($wfdownloads->getConfig('submitarts'), $groups)) {
- $submissionsAllowed = true;
+ if (count(array_intersect($wfdownloads->getConfig('submitarts'), $groups)) > 0) {
+ $isSubmissionAllowed = true;
}
} else {
// if user is ANONYMOUS
@@ -38,7 +38,7 @@
&& ($wfdownloads->getConfig('anonpost') == _WFDOWNLOADS_ANONPOST_DOWNLOAD
|| $wfdownloads->getConfig('anonpost') == _WFDOWNLOADS_ANONPOST_BOTH)
) {
- $submissionsAllowed = true;
+ $isSubmissionAllowed = true;
} else {
redirect_header(XOOPS_URL . '/user.php', 5, _MD_WFDOWNLOADS_MUSTREGFIRST);
}
@@ -46,12 +46,11 @@
// Get categories where user can submit
$categories = $wfdownloads->getHandler('category')->getUserUpCategories();
if (count($categories) == 0) {
- $submissionsAllowed = false;
+ $isSubmissionAllowed = false;
}
-if (!$submissionsAllowed) {
+if ($isSubmissionAllowed == false) {
redirect_header('index.php', 5, _MD_WFDOWNLOADS_NOTALLOWESTOSUBMIT);
}
-
// Check posts if user is not an ADMIN
if (is_object($xoopsUser) && !$xoopsUser->isAdmin()) {
if ($xoopsUser->getVar('posts') < $wfdownloads->getConfig('upload_minposts')) {
@@ -207,9 +206,7 @@
$title = trim($_POST['title']);
} else {
$isAdmin = wfdownloads_userIsAdmin();
-
- $down = wfdownloads_uploading($_FILES, $wfdownloads->getConfig('uploaddir'), '', '', 0, false, $isAdmin);
-
+ $down = wfdownloads_uploading($_FILES, $wfdownloads->getConfig('uploaddir'), '', $currentFile, 0, true, $isAdmin);
$url = ($_POST['url'] != "http://") ? $_POST['url'] : '';
$size = $down['size'];
$filename = $down['filename'];
@@ -453,7 +450,7 @@
) {
$notification_handler->triggerEvent('global', 0, 'new_file', $tags);
$notification_handler->triggerEvent('category', $cid, 'new_file', $tags);
- redirect_header('index.php', 2, _MD_WFDOWNLOADS_ISAPPROVED . "");
+ redirect_header('index.php', 2, _MD_WFDOWNLOADS_ISAPPROVED);
} else {
$tags['WAITINGFILES_URL'] = WFDOWNLOADS_URL . '/admin/downloads.php';
$notification_handler->triggerEvent('global', 0, 'file_submit', $tags);
@@ -478,10 +475,11 @@
$tags = array();
$tags['FILE_NAME'] = $title;
$tags['FILE_URL'] = WFDOWNLOADS_URL . "/singlefile.php?cid={$cid}&lid={$lid}";
-
$category = $wfdownloads->getHandler('category')->get($cid);
$tags['CATEGORY_NAME'] = $category->getVar('title');
$tags['CATEGORY_URL'] = WFDOWNLOADS_URL . "/viewcat.php?cid={$cid}";
+ $notification_handler->triggerEvent('global', 0, 'file_modify', $tags);
+ redirect_header('index.php', 2, _MD_WFDOWNLOADS_ISAPPROVED);
} else {
$updated = (isset($_POST['up_dated']) && $_POST['up_dated'] == 0) ? 0 : time();
$download->setVar('updated', $updated);
@@ -494,8 +492,9 @@
$tags = array();
$tags['MODIFYREPORTS_URL'] = WFDOWNLOADS_URL . '/admin/reportsmodifications.php';
$notification_handler->triggerEvent('global', 0, 'file_modify', $tags);
+ redirect_header('index.php', 2, _MD_WFDOWNLOADS_THANKSFORINFO);
}
- redirect_header('index.php', 2, _MD_WFDOWNLOADS_THANKSFORINFO);
+
}
break;
}
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_download.html
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_download.html 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_download.html 2013-10-10 12:50:52 UTC (rev 12168)
@@ -1,8 +1,10 @@
<div>
<b><a href="singlefile.php?cid=<{$download.cid}>&lid=<{$download.id}>" title="<{$smarty.const._MD_WFDOWNLOADS_VIEWDETAILS}>"><{$download.title}></a></b> <{$download.icons}>
- <{if ($download.isadmin == true)}>
+ <{if ($download.isadmin == true or $download.issubmitter == true)}>
<a href="submit.php?op=download.edit&lid=<{$download.id}>"><img src="<{xoModuleIcons16 edit.png}>" title="<{$smarty.const._EDIT}>"
alt="<{$smarty.const._EDIT}>"/></a>
+ <{/if}>
+ <{if ($download.isadmin == true)}>
<a href="admin/downloads.php?op=download.delete&lid=<{$download.id}>"><img src="<{xoModuleIcons16 delete.png}>"
title="<{$smarty.const._DELETE}>" alt="<{$smarty.const._DELETE}>"/></a>
<{/if}>
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_viewcat.html
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_viewcat.html 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/templates/wfdownloads_viewcat.html 2013-10-10 12:50:52 UTC (rev 12168)
@@ -250,7 +250,7 @@
<div>
<{include file="db:wfdownloads_download.html" download=$download}>
</div>
- <br/>
+ <br />
<{/foreach}>
<!-- End link loop -->
<div style="clear:both"></div>
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/viewcat.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/viewcat.php 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/viewcat.php 2013-10-10 12:50:52 UTC (rev 12168)
@@ -48,7 +48,7 @@
) {
// if user is a registered user
$groups = $xoopsUser->getGroups();
- if (array_intersect($xoopsModuleConfig['submitarts'], $groups)) {
+ if (count(array_intersect($wfdownloads->getConfig('submitarts'), $groups)) > 0) {
$isSubmissionAllowed = true;
}
} else {
Modified: XoopsModules/wfdownloads/trunk/wfdownloads/xoops_version.php
===================================================================
--- XoopsModules/wfdownloads/trunk/wfdownloads/xoops_version.php 2013-10-09 18:17:16 UTC (rev 12167)
+++ XoopsModules/wfdownloads/trunk/wfdownloads/xoops_version.php 2013-10-10 12:50:52 UTC (rev 12168)
@@ -42,9 +42,9 @@
$modversion['onUpdate'] = 'include/module.php';
$modversion['onUninstall'] = 'include/module.php';
-$modversion['date'] = '2013-10-08';
-$modversion['release_date'] = '2013/10/08';
-$modversion['releasedate'] = '2013-10-08';
+$modversion['date'] = '2013-10-10';
+$modversion['release_date'] = '2013/10/10';
+$modversion['releasedate'] = '2013-10-10';
$modversion['status'] = 'BETA 1';
$modversion['teammembers'] = "Bender, David, FrankBlack, Xpider, M0nty, Mithrandir, Marcan, felix[fx2024], Sudhaker, Jegelstaff";
@@ -159,7 +159,7 @@
) {
// if user is a registered user
$groups = $xoopsUser->getGroups();
- if (array_intersect($xoopsModuleConfig['submitarts'], $groups)) {
+ if (count(array_intersect($xoopsModuleConfig['submitarts'], $groups)) > 0) {
$isSubmissionAllowed = true;
}
} else {
|