Ejemplo n.º 1
0
 /**
  * Constructor
  * @param	object    $object   reference to targetobject (@link icms_ipf_Object)
  * @param	string    $key      the form name
  */
 public function __construct($object, $key)
 {
     $var = $object->vars[$key];
     $control = $object->getControl($key);
     $object_imageurl = $object->getImageDir();
     parent::__construct($var['form_caption'], ' ');
     if (isset($objectArray['image'])) {
         $objectArray['image'] = str_replace('{ICMS_URL}', ICMS_URL, $objectArray['image']);
     }
     if ($object->getVar($key, 'e') != '' && (substr($object->getVar($key, 'e'), 0, 4) == 'http' || substr($object->getVar($key, 'e'), 0, 11) == '{ICMS_URL}')) {
         $this->addElement(new icms_form_elements_Label('', "<img src='" . str_replace('{ICMS_URL}', ICMS_URL, $object->getVar($key, 'e')) . "' alt='' /><br/><br/>"));
     } elseif ($object->getVar($key, 'e') != '') {
         $this->addElement(new icms_form_elements_Label('', "<img src='" . $object_imageurl . $object->getVar($key, 'e') . "' alt='' /><br/><br/>"));
     }
     $this->addElement(new icms_ipf_form_elements_Fileupload($object, $key));
     if (!isset($control['nourl']) || !$control['nourl']) {
         $this->addElement(new icms_form_elements_Label('<div style="padding-top: 8px; font-size: 80%;">' . _CO_ICMS_URL_FILE_DSC . '</div>', ''));
         $this->addElement(new icms_form_elements_Label('', '<br />' . _CO_ICMS_URL_FILE));
         $this->addElement(new icms_form_elements_Text('', 'url_' . $key, 50, 500));
     }
     if (!$object->isNew()) {
         $this->addElement(new icms_form_elements_Label('', '<br /><br />'));
         $delete_check = new icms_form_elements_Checkbox('', 'delete_' . $key);
         $delete_check->addOption(1, '<span style="color:red;">' . _CO_ICMS_DELETE . '</span>');
         $this->addElement($delete_check);
     }
 }
Ejemplo n.º 2
0
 /**
  * Constructor
  * @param	object    $object   reference to targetobject (@link icms_ipf_Object)
  * @param	string    $key      the form name
  */
 public function __construct($object, $key)
 {
     $var = $object->vars[$key];
     parent::__construct($var['form_caption'], '<br /><br />', $key . '_signature_tray');
     icms_loadLanguageFile('core', 'user');
     $signature_textarea = new icms_form_elements_Dhtmltextarea('', $key, $object->getVar($key, 'e'));
     $this->addElement($signature_textarea);
     $attach_checkbox = new icms_form_elements_Checkbox('', 'attachsig', $object->getVar('attachsig', 'e'));
     $attach_checkbox->addOption(1, _US_SHOWSIG);
     $this->addElement($attach_checkbox);
 }
Ejemplo n.º 3
0
foreach ($subject_icons as $iconfile) {
    $icons_radio->addOption($iconfile, '<img src="' . ICMS_IMAGES_URL . '/subject/' . $iconfile . '" alt="" />');
}
$cform->addElement($icons_radio);
$cform->addElement(new icms_form_elements_Dhtmltextarea(_CM_MESSAGE, 'message', $message, 10, 50), true);
$option_tray = new icms_form_elements_Tray(_OPTIONS, '<br />');
if (icms::$user) {
    if ($icmsConfig['anonpost'] == true) {
        $noname_checkbox = new icms_form_elements_Checkbox('', 'noname', $noname);
        $noname_checkbox->addOption(1, _POSTANON);
        $option_tray->addElement($noname_checkbox);
    }
    if (icms::$user->isAdmin($icmsModule->getVar('mid'))) {
        $nohtml_checkbox = new icms_form_elements_Checkbox('', 'nohtml', $nohtml);
        $nohtml_checkbox->addOption(1, _DISABLEHTML);
        $option_tray->addElement($nohtml_checkbox);
    }
}
$smiley_checkbox = new icms_form_elements_Checkbox('', 'nosmiley', $nosmiley);
$smiley_checkbox->addOption(1, _DISABLESMILEY);
$option_tray->addElement($smiley_checkbox);
$cform->addElement($option_tray);
$cform->addElement(new icms_form_elements_Hidden('pid', (int) $pid));
$cform->addElement(new icms_form_elements_Hidden('comment_id', (int) $comment_id));
$cform->addElement(new icms_form_elements_Hidden('item_id', (int) $item_id));
$cform->addElement(new icms_form_elements_Hidden('order', (int) $order));
$button_tray = new icms_form_elements_Tray('', '&nbsp;');
$button_tray->addElement(new icms_form_elements_Button('', 'preview', _PREVIEW, 'submit'));
$button_tray->addElement(new icms_form_elements_Button('', 'post', _CM_POSTCOMMENT, 'submit'));
$cform->addElement($button_tray);
$cform->display();
Ejemplo n.º 4
0
if ($icmsConfigUser['pass_level'] > 20) {
    icms_PasswordMeter();
}
$reg_form->addElement(new icms_form_elements_Password(_US_PASSWORD, "pass", 10, 255, icms_core_DataFilter::htmlSpecialChars($pass), false, $icmsConfigUser['pass_level'] ? 'password_adv' : ''), true);
$reg_form->addElement(new icms_form_elements_Password(_US_VERIFYPASS, "vpass", 10, 255, icms_core_DataFilter::htmlSpecialChars($vpass)), true);
$reg_form->addElement(new icms_form_elements_Text(_US_WEBSITE, "url", 25, 255, icms_core_DataFilter::htmlSpecialChars($url)));
$tzselected = $timezone_offset != "" ? $timezone_offset : $icmsConfig['default_TZ'];
$reg_form->addElement(new icms_form_elements_select_Timezone(_US_TIMEZONE, "timezone_offset", $tzselected));
//$reg_form->addElement($avatar_tray);
$reg_form->addElement(new icms_form_elements_Radioyn(_US_MAILOK, 'user_mailok', $user_mailok));
if ($icmsConfigUser['reg_dispdsclmr'] != 0 && $icmsConfigUser['reg_disclaimer'] != '') {
    $disc_tray = new icms_form_elements_Tray(_US_DISCLAIMER, '<br />');
    $disclaimer_html = '<div id="disclaimer">' . nl2br($icmsConfigUser['reg_disclaimer']) . '</div>';
    $disc_text = new icms_form_elements_Label('', $disclaimer_html, 'disclaimer');
    $disc_tray->addElement($disc_text);
    $agree_chk = new icms_form_elements_Checkbox('', 'agree_disc', $agree_disc);
    $agree_chk->addOption(1, _US_IAGREE);
    $eltname = $agree_chk->getName();
    $eltmsg = str_replace('"', '\\"', stripslashes(sprintf(_FORM_ENTER, _US_IAGREE)));
    $agree_chk->customValidationCode[] = "if (myform.{$eltname}.checked == false) { window.alert(\"{$eltmsg}\"); myform.{$eltname}.focus(); return false; }";
    $disc_tray->addElement($agree_chk, true);
    $reg_form->addElement($disc_tray);
}
$reg_form->addElement(new icms_form_elements_Hidden("actkey", icms_core_DataFilter::htmlSpecialChars($actkey)));
if ($icmsConfigUser['use_captcha'] == true) {
    $reg_form->addElement(new icms_form_elements_Captcha(_SECURITYIMAGE_GETCODE, "scode"), true);
    $reg_form->addElement(new icms_form_elements_Hidden("op", "finish"));
} else {
    $reg_form->addElement(new icms_form_elements_Hidden("op", "newuser"));
}
$reg_form->addElement(new icms_form_elements_Button("", "submit", _US_SUBMIT, "submit"));
Ejemplo n.º 5
0
    $criteria_tray->addElement($mailok_cbox);
    $criteria_tray->addElement($inactive_cbox);
    $criteria_tray->addElement($regd_min);
    $criteria_tray->addElement($regd_max);
    $form->addElement($criteria_tray);
}
$fname_text = new icms_form_elements_Text(_AM_MAILFNAME, "mail_fromname", 30, 255, htmlspecialchars($icmsConfig['sitename'], ENT_QUOTES));
$fromemail = !empty($icmsConfig['adminmail']) ? $icmsConfig['adminmail'] : icms::$user->getVar("email", "E");
$femail_text = new icms_form_elements_Text(_AM_MAILFMAIL, "mail_fromemail", 30, 255, $fromemail);
//$subject_caption = _AM_MAILSUBJECT . "<br /><br /><span style='font-size:x-small;font-weight:bold;'>" . _AM_MAILTAGS . "</span><br /><span style='font-size:x-small;font-weight:normal;'>" . _AM_MAILTAGS1 . "<br />" . _AM_MAILTAGS2 . "<br />" . _AM_MAILTAGS3 . "</span>";
$subject_caption = _AM_MAILSUBJECT . "<br /><br /><span style='font-size:x-small;font-weight:bold;'>" . _AM_MAILTAGS . "</span><br /><span style='font-size:x-small;font-weight:normal;'>" . _AM_MAILTAGS2 . "</span>";
$subject_text = new icms_form_elements_Text($subject_caption, "mail_subject", 50, 255);
$body_caption = _AM_MAILBODY . "<br /><br /><span style='font-size:x-small;font-weight:bold;'>" . _AM_MAILTAGS . "</span><br /><span style='font-size:x-small;font-weight:normal;'>" . _AM_MAILTAGS1 . "<br />" . _AM_MAILTAGS2 . "<br />" . _AM_MAILTAGS3 . "<br />" . _AM_MAILTAGS4 . "</span>";
$body_text = new icms_form_elements_Textarea($body_caption, "mail_body", "", 10);
$to_checkbox = new icms_form_elements_Checkbox(_AM_SENDTO, "mail_send_to", "mail");
$to_checkbox->addOption("mail", _AM_EMAIL);
$to_checkbox->addOption("pm", _AM_PM);
$start_hidden = new icms_form_elements_Hidden("mail_start", 0);
$op_hidden = new icms_form_elements_Hidden("op", "send");
$submit_button = new icms_form_elements_Button("", "mail_submit", _SEND, "submit");
$form->addElement($fname_text);
$form->addElement($femail_text);
$form->addElement($subject_text);
$form->addElement($body_text);
$form->addElement($to_checkbox);
$form->addElement($op_hidden);
$form->addElement($start_hidden);
$form->addElement($submit_button);
$form->setRequired($subject_text);
$form->setRequired($body_text);
//$form->setRequired($to_checkbox);
Ejemplo n.º 6
0
$icq_text = new icms_form_elements_Text(_AM_ICQ, "user_icq", 15, 15, $icq_value);
$aim_text = new icms_form_elements_Text(_AM_AIM, "user_aim", 18, 18, $aim_value);
$yim_text = new icms_form_elements_Text(_AM_YIM, "user_yim", 25, 25, $yim_value);
$msnm_text = new icms_form_elements_Text(_AM_MSNM, "user_msnm", 30, 100, $msnm_value);
$location_text = new icms_form_elements_Text(_AM_LOCATION, "user_from", 30, 100, $location_value);
$occupation_text = new icms_form_elements_Text(_AM_OCCUPATION, "user_occ", 30, 100, $occ_value);
$interest_text = new icms_form_elements_Text(_AM_INTEREST, "user_intrest", 30, 150, $interest_value);
$sig_tray = new icms_form_elements_Tray(_AM_SIGNATURE, "<br />");
if ($icmsConfigUser['allow_htsig'] == 0) {
    $sig_tarea = new icms_form_elements_Textarea("", "user_sig", $sig_value);
} else {
    $sig_tarea = new icms_form_elements_Dhtmltextarea("", "user_sig", $sig_value);
}
$sig_tray->addElement($sig_tarea);
$sig_cbox = new icms_form_elements_Checkbox("", "attachsig", $sig_cbox_value);
$sig_cbox->addOption(1, _US_SHOWSIG);
$sig_tray->addElement($sig_cbox);
$umode_select = new icms_form_elements_Select(_US_CDISPLAYMODE, "umode", $umode_value);
$umode_select->addOptionArray(array("nest" => _NESTED, "flat" => _FLAT, "thread" => _THREADED));
$uorder_select = new icms_form_elements_Select(_US_CSORTORDER, "uorder", $uorder_value);
$uorder_select->addOptionArray(array("0" => _OLDESTFIRST, "1" => _NEWESTFIRST));
// RMV-NOTIFY
icms_loadLanguageFile('core', 'notification');
include_once ICMS_ROOT_PATH . '/include/notification_constants.php';
$notify_method_select = new icms_form_elements_Select(_NOT_NOTIFYMETHOD, 'notify_method', $notify_method_value);
$notify_method_select->addOptionArray(array(XOOPS_NOTIFICATION_METHOD_DISABLE => _NOT_METHOD_DISABLE, XOOPS_NOTIFICATION_METHOD_PM => _NOT_METHOD_PM, XOOPS_NOTIFICATION_METHOD_EMAIL => _NOT_METHOD_EMAIL));
$notify_mode_select = new icms_form_elements_Select(_NOT_NOTIFYMODE, 'notify_mode', $notify_mode_value);
$notify_mode_select->addOptionArray(array(XOOPS_NOTIFICATION_MODE_SENDALWAYS => _NOT_MODE_SENDALWAYS, XOOPS_NOTIFICATION_MODE_SENDONCETHENDELETE => _NOT_MODE_SENDONCE, XOOPS_NOTIFICATION_MODE_SENDONCETHENWAIT => _NOT_MODE_SENDONCEPERLOGIN));
$bio_tarea = new icms_form_elements_Textarea(_US_EXTRAINFO, "bio", $bio_value);
$rank_select = new icms_form_elements_Select(_AM_RANK, "rank", $rank_value);
$ranklist = icms_getModuleHandler("userrank", "system")->getList(icms_buildCriteria(array('rank_special' => '1')));
Ejemplo n.º 7
0
/**
* Get {@link icms_form_Theme} for editing a user
*
* @param object $user {@link icms_member_user_Object} to edit
*
* @return object
*/
function getUserForm(&$user, $profile = false, $action = false)
{
    global $icmsConfig, $icmsConfigUser, $icmsConfigAuth;
    if ($action === false) {
        $action = $_SERVER['REQUEST_URI'];
    }
    $title = $user->isNew() ? _AM_PROFILE_ADDUSER : _MD_PROFILE_EDITPROFILE;
    icms_loadLanguageFile('core', 'user');
    $form = new icms_form_Theme($title, 'userinfo', $action, 'post', true);
    $profile_handler = icms_getModuleHandler('profile', basename(dirname(dirname(__FILE__))), 'profile');
    // Dynamic fields
    if (!$profile) {
        $profile_handler = icms_getModuleHandler('profile', basename(dirname(dirname(__FILE__))), 'profile');
        $profile = $profile_handler->get($user->getVar('uid'));
    }
    // Get fields
    $fields = $profile_handler->loadFields();
    // Get ids of fields that can be edited
    $gperm_handler = icms::handler('icms_member_groupperm');
    $editable_fields = $gperm_handler->getItemIds('profile_edit', icms::$user->getGroups(), icms::$module->getVar('mid'));
    $email_tray = new icms_form_elements_Tray(_MD_PROFILE_EMAIL, '<br />');
    if ($user->isNew() || icms::$user->isAdmin()) {
        $elements[0][] = array('element' => new icms_form_elements_Text(_US_LOGIN_NAME, 'login_name', 25, 75, $user->getVar('login_name', 'e')), 'required' => 1);
        $weights[0][] = 0;
        $elements[0][] = array('element' => new icms_form_elements_Text(_US_NICKNAME, 'uname', 25, 75, $user->getVar('uname', 'e')), 'required' => 1);
        $weights[0][] = 0;
        $elements[0][] = array('element' => new icms_form_elements_Text(_MD_PROFILE_EMAIL, 'email', 30, 60, $user->getVar('email')), 'required' => 1);
        $weights[0][] = 0;
    } else {
        $elements[0][] = array('element' => new icms_form_elements_Label(_US_LOGIN_NAME, $user->getVar('login_name', 'e')), 'required' => 0);
        $weights[0][] = 0;
        if ($icmsConfigUser['allow_chguname'] == 1) {
            $elements[0][] = array('element' => new icms_form_elements_Text(_US_NICKNAME, 'uname', 25, 75, $user->getVar('uname', 'e')), 'required' => 1);
        } else {
            $elements[0][] = array('element' => new icms_form_elements_Label(_US_NICKNAME, $user->getVar('uname')), 'required' => 0);
        }
        $weights[0][] = 0;
        $elements[0][] = array('element' => new icms_form_elements_Label(_MD_PROFILE_EMAIL, $user->getVar('email')), 'required' => 0);
        $weights[0][] = 0;
    }
    if ($icmsConfigAuth['auth_openid'] == 1) {
        $openid_tray = new icms_form_elements_Tray(_MD_PROFILE_OPENID, '<br />');
        $openid_tray->addElement(new icms_form_elements_Text('', 'openid', 30, 255, $user->getVar('openid')));
        $openid_checkbox = new icms_form_elements_Checkbox('', 'user_viewoid', $user->getVar('user_viewoid'));
        $openid_checkbox->addOption('1', _MD_PROFILE_OPENID_VIEW);
        $openid_tray->addElement($openid_checkbox);
        $elements[0][] = array('element' => $openid_tray, 'required' => 0);
        $weights[0][] = 0;
    }
    if (icms::$user->isAdmin() && $user->getVar('uid') != icms::$user->getVar('uid') or $user->getVar('uid') == icms::$user->getVar('uid')) {
        // ALTERED BY FREEFORM SOLUTIONS TO ALLOW USERS TO CHANGE THEIR OWN PASSWORDS
        //If the user is an admin and is editing someone else
        $pwd_text = new icms_form_elements_Password('', 'password', 10, 32, "", false, $icmsConfigUser['pass_level'] ? 'password_adv' : '');
        $pwd_text2 = new icms_form_elements_Password('', 'vpass', 10, 32);
        $pwd_tray = new icms_form_elements_Tray(_MD_PROFILE_PASSWORD . '<br />' . _MD_PROFILE_TYPEPASSTWICE);
        $pwd_tray->addElement($pwd_text, $user->isNew());
        $pwd_tray->addElement($pwd_text2, $user->isNew());
        $elements[0][] = array('element' => $pwd_tray, 'required' => 1);
        //cannot set an element tray required
        $weights[0][] = 0;
        if (icms::$user->isAdmin() && $user->getVar('uid') != icms::$user->getVar('uid')) {
            // ALTERED BY FREEFORM SOLUTIONS SO THAT USERS CAN'T ALTER THEIR OWN LEVEL
            $level_radio = new icms_form_elements_Radio(_MD_PROFILE_ACTIVEUSER, 'level', $user->getVar('level'));
            $level_radio->addOption(1, _MD_PROFILE_ACTIVE);
            $level_radio->addOption(0, _MD_PROFILE_INACTIVE);
            $level_radio->addOption(-1, _MD_PROFILE_DISABLED);
            $elements[0][] = array('element' => $level_radio, 'required' => 0);
            $weights[0][] = 0;
        }
    }
    $elements[0][] = array('element' => new icms_form_elements_Hidden('uid', $user->getVar('uid')), 'required' => 0);
    $weights[0][] = 0;
    $elements[0][] = array('element' => new icms_form_elements_Hidden('op', 'save'), 'required' => 0);
    $weights[0][] = 0;
    $profile_cat_handler = icms_getmodulehandler('category', basename(dirname(dirname(__FILE__))), 'profile');
    $categories = $profile_cat_handler->getObjects(null, true, false);
    foreach (array_keys($fields) as $i) {
        if (in_array($fields[$i]->getVar('fieldid'), $editable_fields)) {
            if ($fields[$i]->getVar('field_edit') == 1) {
                $fieldinfo['element'] = $fields[$i]->getEditElement($user, $profile);
                $fieldinfo['required'] = $fields[$i]->getVar('field_required');
                $key = $fields[$i]->getVar('catid');
                $elements[$key][] = $fieldinfo;
                $weights[$key][] = $fields[$i]->getVar('field_weight');
                // Image upload
                if ($fields[$i]->getVar('field_type') == "image") {
                    $form->setExtra('enctype="multipart/form-data"');
                }
            }
        }
    }
    if (icms::$user && icms::$user->isAdmin()) {
        icms_loadLanguageFile(basename(dirname(dirname(__FILE__))), 'admin');
        //If user has admin rights on groups
        include_once ICMS_ROOT_PATH . "/modules/system/constants.php";
        if ($gperm_handler->checkRight("system_admin", XOOPS_SYSTEM_GROUP, icms::$user->getGroups(), 1)) {
            //add group selection
            $group_select = new icms_form_elements_select_Group(_AM_PROFILE_GROUP, 'groups', false, $user->getGroups(), 15, true);
            // UPDATED BY FREEFORM SOLUTIONS - MAKE LIST TALLER
            $elements[0][] = array('element' => $group_select, 'required' => 0);
            $weights[0][] = 15000;
        }
    }
    ksort($elements);
    foreach (array_keys($elements) as $k) {
        array_multisort($weights[$k], SORT_ASC, array_keys($elements[$k]), SORT_ASC, $elements[$k]);
        $title = isset($categories[$k]) ? $categories[$k]['cat_title'] : _MD_PROFILE_DEFAULT;
        $desc = isset($categories[$k]) ? $categories[$k]['cat_description'] : "";
        $form->addElement(new icms_form_elements_Label($title, $desc), false);
        foreach (array_keys($elements[$k]) as $i) {
            $form->addElement($elements[$k][$i]['element'], $elements[$k][$i]['required']);
        }
    }
    $form->addElement(new icms_form_elements_Button('', 'submit', _MD_PROFILE_SAVECHANGES, 'submit'));
    return $form;
}
Ejemplo n.º 8
0
$criteria = new icms_db_criteria_Compo(new icms_db_criteria_Item('isactive', 1));
/* criteria added to see where the active user can view the debug mode (enable_debug)
 * administrators do not have explicit entries for this, do not filter
 */
if (!in_array(XOOPS_GROUP_ADMIN, $groups)) {
    $debug_mod = $gperm->getItemIds('enable_debug', $groups);
    $criteria->add(new icms_db_criteria_Item('mid', '(' . implode(',', $debug_mod) . ')', 'IN'));
}
$debug_mod_checkbox->addOptionArray($module_handler->getList($criteria));
$group_manager_checkbox = new icms_form_elements_Checkbox(_AM_GROUPMANAGER_PERM, "groupmanager_gids[]", $group_manager_value);
$criteria = new icms_db_criteria_Compo(new icms_db_criteria_Item('isactive', 1));
$groups = $member_handler->getGroups();
$gperm_handler = icms::handler('icms_member_groupperm');
foreach ($groups as $group) {
    if ($gperm_handler->checkRight('group_manager', $group->getVar('groupid'), icms::$user->getGroups())) {
        $group_manager_checkbox->addOption($group->getVar('groupid'), $group->getVar('name'));
    }
}
$icms_block_handler = icms::handler('icms_view_block');
$posarr = $icms_block_handler->getBlockPositions(true);
$block_checkbox = array();
$i = 0;
$groups = icms::$user->getGroups();
foreach ($posarr as $k => $v) {
    $tit = defined($posarr[$k]['title']) ? constant($posarr[$k]['title']) : $posarr[$k]['title'];
    $block_checkbox[$i] = new icms_form_elements_Checkbox('<strong">' . $tit . '</strong><br />', "read_bids[]", $r_block_value);
    $new_blocks_array = array();
    $blocks_array = $icms_block_handler->getAllBlocks("list", $k);
    /* compare to list of blocks the group can read, do not filter for administrator group */
    if (!in_array(XOOPS_GROUP_ADMIN, $groups)) {
        $r_blocks = $gperm->getItemIds('block_read', $groups);
Ejemplo n.º 9
0
        }
        $html_checkbox = new icms_form_elements_Checkbox('', 'dohtml', $dohtml);
        $html_checkbox->addOption(1, _CM_DOHTML);
        $option_tray->addElement($html_checkbox);
    } else {
        $cform->addElement(new icms_form_elements_Hidden('dohtml', $dohtml));
    }
}
$smiley_checkbox = new icms_form_elements_Checkbox('', 'dosmiley', $dosmiley);
$smiley_checkbox->addOption(1, _CM_DOSMILEY);
$option_tray->addElement($smiley_checkbox);
$xcode_checkbox = new icms_form_elements_Checkbox('', 'doxcode', $doxcode);
$xcode_checkbox->addOption(1, _CM_DOXCODE);
$option_tray->addElement($xcode_checkbox);
$br_checkbox = new icms_form_elements_Checkbox('', 'dobr', $dobr);
$br_checkbox->addOption(1, _CM_DOAUTOWRAP);
$option_tray->addElement($br_checkbox);
$cform->addElement($option_tray);
$cform->addElement(new icms_form_elements_Hidden('com_pid', (int) $com_pid));
$cform->addElement(new icms_form_elements_Hidden('com_rootid', (int) $com_rootid));
$cform->addElement(new icms_form_elements_Hidden('com_id', $com_id));
$cform->addElement(new icms_form_elements_Hidden('com_itemid', $com_itemid));
$cform->addElement(new icms_form_elements_Hidden('com_order', $com_order));
$cform->addElement(new icms_form_elements_Hidden('com_mode', $com_mode));
// add module specific extra params
if ('system' != $icmsModule->getVar('dirname')) {
    $comment_config = $icmsModule->getInfo('comments');
    if (isset($comment_config['extraParams']) && is_array($comment_config['extraParams'])) {
        foreach ($comment_config['extraParams'] as $extra_param) {
            // This routine is included from forms accessed via both GET and POST
            if (isset($_POST[$extra_param])) {