@@ -29,28 +29,28 @@ |
||
| 29 | 29 | parent::__construct($form_caption, ' '); |
| 30 | 30 | if ('' !== $object->getVar('url')) { |
| 31 | 31 | $caption = '' !== $object->getVar('caption') ? $object->getVar('caption') : $object->getVar('url'); |
| 32 | - $this->addElement(new \XoopsFormLabel('', _CO_SOBJECT_CURRENT_FILE . "<a href='" . str_replace('{XOOPS_URL}', XOOPS_URL, $object->getVar('url')) . "' target='_blank' >" . $caption . '</a><br><br>')); |
|
| 32 | + $this->addElement(new \XoopsFormLabel('', _CO_SOBJECT_CURRENT_FILE."<a href='".str_replace('{XOOPS_URL}', XOOPS_URL, $object->getVar('url'))."' target='_blank' >".$caption.'</a><br><br>')); |
|
| 33 | 33 | //$this->addElement( new \XoopsFormLabel( '', "<br><a href = '".SMARTOBJECT_URL."admin/file.php?op=del&fileid=".$object->id()."'>"._CO_SOBJECT_DELETE_FILE."</a>")); |
| 34 | 34 | } |
| 35 | 35 | |
| 36 | 36 | // require_once SMARTOBJECT_ROOT_PATH . 'class/form/elements/smartformfileuploadelement.php'; |
| 37 | 37 | if ($object->isNew()) { |
| 38 | 38 | $this->addElement(new SmartFormFileUploadElement($object, $key)); |
| 39 | - $this->addElement(new \XoopsFormLabel('', '<br><br><small>' . _CO_SOBJECT_URL_FILE_DSC . '</small>')); |
|
| 40 | - $this->addElement(new \XoopsFormLabel('', '<br>' . _CO_SOBJECT_URL_FILE)); |
|
| 41 | - $this->addElement(new SmartFormTextElement($object, 'url_' . $key)); |
|
| 39 | + $this->addElement(new \XoopsFormLabel('', '<br><br><small>'._CO_SOBJECT_URL_FILE_DSC.'</small>')); |
|
| 40 | + $this->addElement(new \XoopsFormLabel('', '<br>'._CO_SOBJECT_URL_FILE)); |
|
| 41 | + $this->addElement(new SmartFormTextElement($object, 'url_'.$key)); |
|
| 42 | 42 | } |
| 43 | - $this->addElement(new \XoopsFormLabel('', '<br>' . _CO_SOBJECT_CAPTION)); |
|
| 44 | - $this->addElement(new SmartFormTextElement($object, 'caption_' . $key)); |
|
| 45 | - $this->addElement(new \XoopsFormLabel('', '<br>' . _CO_SOBJECT_DESC . '<br>')); |
|
| 46 | - $this->addElement(new \XoopsFormTextArea('', 'desc_' . $key, $object->getVar('description'))); |
|
| 43 | + $this->addElement(new \XoopsFormLabel('', '<br>'._CO_SOBJECT_CAPTION)); |
|
| 44 | + $this->addElement(new SmartFormTextElement($object, 'caption_'.$key)); |
|
| 45 | + $this->addElement(new \XoopsFormLabel('', '<br>'._CO_SOBJECT_DESC.'<br>')); |
|
| 46 | + $this->addElement(new \XoopsFormTextArea('', 'desc_'.$key, $object->getVar('description'))); |
|
| 47 | 47 | |
| 48 | 48 | if (!$object->isNew()) { |
| 49 | - $this->addElement(new \XoopsFormLabel('', '<br>' . _CO_SOBJECT_CHANGE_FILE)); |
|
| 49 | + $this->addElement(new \XoopsFormLabel('', '<br>'._CO_SOBJECT_CHANGE_FILE)); |
|
| 50 | 50 | $this->addElement(new SmartFormFileUploadElement($object, $key)); |
| 51 | - $this->addElement(new \XoopsFormLabel('', '<br><br><small>' . _CO_SOBJECT_URL_FILE_DSC . '</small>')); |
|
| 52 | - $this->addElement(new \XoopsFormLabel('', '<br>' . _CO_SOBJECT_URL_FILE)); |
|
| 53 | - $this->addElement(new SmartFormTextElement($object, 'url_' . $key)); |
|
| 51 | + $this->addElement(new \XoopsFormLabel('', '<br><br><small>'._CO_SOBJECT_URL_FILE_DSC.'</small>')); |
|
| 52 | + $this->addElement(new \XoopsFormLabel('', '<br>'._CO_SOBJECT_URL_FILE)); |
|
| 53 | + $this->addElement(new SmartFormTextElement($object, 'url_'.$key)); |
|
| 54 | 54 | } |
| 55 | 55 | } |
| 56 | 56 | } |
@@ -29,7 +29,7 @@ |
||
| 29 | 29 | $var = $object->vars[$key]; |
| 30 | 30 | $control = $object->controls[$key]; |
| 31 | 31 | |
| 32 | - parent::__construct($var['form_caption'], '<br><br>', $key . '_signature_tray'); |
|
| 32 | + parent::__construct($var['form_caption'], '<br><br>', $key.'_signature_tray'); |
|
| 33 | 33 | |
| 34 | 34 | $signature_textarea = new \XoopsFormDhtmlTextArea('', $key, $object->getVar($key, 'e')); |
| 35 | 35 | $this->addElement($signature_textarea); |
@@ -28,7 +28,7 @@ discard block |
||
| 28 | 28 | { |
| 29 | 29 | $this->SmartFormFileElement($object, $key); |
| 30 | 30 | // Override name for upload purposes |
| 31 | - $this->setName('upload_' . $key); |
|
| 31 | + $this->setName('upload_'.$key); |
|
| 32 | 32 | } |
| 33 | 33 | |
| 34 | 34 | /** |
@@ -38,8 +38,8 @@ discard block |
||
| 38 | 38 | */ |
| 39 | 39 | public function render() |
| 40 | 40 | { |
| 41 | - return "<input type='hidden' name='MAX_FILE_SIZE' value='" . $this->getMaxFileSize() . "'> |
|
| 42 | - <input type='file' name='" . $this->getName() . "' id='" . $this->getName() . "'" . $this->getExtra() . "> |
|
| 43 | - <input type='hidden' name='smart_upload_image[]' id='smart_upload_image[]' value='" . $this->getName() . "'>"; |
|
| 41 | + return "<input type='hidden' name='MAX_FILE_SIZE' value='".$this->getMaxFileSize()."'> |
|
| 42 | + <input type='file' name='" . $this->getName()."' id='".$this->getName()."'".$this->getExtra()."> |
|
| 43 | + <input type='hidden' name='smart_upload_image[]' id='smart_upload_image[]' value='" . $this->getName()."'>"; |
|
| 44 | 44 | } |
| 45 | 45 | } |
@@ -32,7 +32,7 @@ |
||
| 32 | 32 | global $xoopsDB; |
| 33 | 33 | $ret = []; |
| 34 | 34 | $limit = $start = 0; |
| 35 | - $sql = 'SELECT uid, uname FROM ' . $xoopsDB->prefix('users'); |
|
| 35 | + $sql = 'SELECT uid, uname FROM '.$xoopsDB->prefix('users'); |
|
| 36 | 36 | $sql .= ' ORDER BY uname ASC'; |
| 37 | 37 | |
| 38 | 38 | $result = $xoopsDB->query($sql); |
@@ -28,18 +28,18 @@ |
||
| 28 | 28 | { |
| 29 | 29 | parent::__construct($form_caption, ' '); |
| 30 | 30 | |
| 31 | - $this->addElement(new \XoopsFormLabel('', '<br>' . _CO_SOBJECT_URLLINK_URL)); |
|
| 32 | - $this->addElement(new SmartFormTextElement($object, 'url_' . $key)); |
|
| 31 | + $this->addElement(new \XoopsFormLabel('', '<br>'._CO_SOBJECT_URLLINK_URL)); |
|
| 32 | + $this->addElement(new SmartFormTextElement($object, 'url_'.$key)); |
|
| 33 | 33 | |
| 34 | - $this->addElement(new \XoopsFormLabel('', '<br>' . _CO_SOBJECT_CAPTION)); |
|
| 35 | - $this->addElement(new SmartFormTextElement($object, 'caption_' . $key)); |
|
| 34 | + $this->addElement(new \XoopsFormLabel('', '<br>'._CO_SOBJECT_CAPTION)); |
|
| 35 | + $this->addElement(new SmartFormTextElement($object, 'caption_'.$key)); |
|
| 36 | 36 | |
| 37 | - $this->addElement(new \XoopsFormLabel('', '<br>' . _CO_SOBJECT_DESC . '<br>')); |
|
| 38 | - $this->addElement(new \XoopsFormTextArea('', 'desc_' . $key, $object->getVar('description'))); |
|
| 37 | + $this->addElement(new \XoopsFormLabel('', '<br>'._CO_SOBJECT_DESC.'<br>')); |
|
| 38 | + $this->addElement(new \XoopsFormTextArea('', 'desc_'.$key, $object->getVar('description'))); |
|
| 39 | 39 | |
| 40 | - $this->addElement(new \XoopsFormLabel('', '<br>' . _CO_SOBJECT_URLLINK_TARGET)); |
|
| 40 | + $this->addElement(new \XoopsFormLabel('', '<br>'._CO_SOBJECT_URLLINK_TARGET)); |
|
| 41 | 41 | $targ_val = $object->getVar('target'); |
| 42 | - $targetRadio = new \XoopsFormRadio('', 'target_' . $key, '' !== $targ_val ? $targ_val : '_blank'); |
|
| 42 | + $targetRadio = new \XoopsFormRadio('', 'target_'.$key, '' !== $targ_val ? $targ_val : '_blank'); |
|
| 43 | 43 | $control = $object->getControl('target'); |
| 44 | 44 | $targetRadio->addOptionArray($control['options']); |
| 45 | 45 | |
@@ -32,10 +32,10 @@ |
||
| 32 | 32 | if (is_array($this->getValue())) { |
| 33 | 33 | $ret = ''; |
| 34 | 34 | foreach ($this->getValue() as $value) { |
| 35 | - $ret .= "<input type='hidden' name='" . $this->getName() . "[]' id='" . $this->getName() . "' value='" . $value . "'>\n"; |
|
| 35 | + $ret .= "<input type='hidden' name='".$this->getName()."[]' id='".$this->getName()."' value='".$value."'>\n"; |
|
| 36 | 36 | } |
| 37 | 37 | } else { |
| 38 | - $ret = "<input type='hidden' name='" . $this->getName() . "' id='" . $this->getName() . "' value='" . $this->getValue() . "'>"; |
|
| 38 | + $ret = "<input type='hidden' name='".$this->getName()."' id='".$this->getName()."' value='".$this->getValue()."'>"; |
|
| 39 | 39 | } |
| 40 | 40 | |
| 41 | 41 | return $ret; |
@@ -34,23 +34,23 @@ |
||
| 34 | 34 | if ('' !== $object->getVar($key) |
| 35 | 35 | && (0 === strpos($object->getVar($key), 'http') |
| 36 | 36 | || 0 === strpos($object->getVar($key), '{XOOPS_URL}'))) { |
| 37 | - $this->addElement(new \XoopsFormLabel('', "<img src='" . str_replace('{XOOPS_URL}', XOOPS_URL, $object->getVar($key)) . "' alt=''><br><br>")); |
|
| 37 | + $this->addElement(new \XoopsFormLabel('', "<img src='".str_replace('{XOOPS_URL}', XOOPS_URL, $object->getVar($key))."' alt=''><br><br>")); |
|
| 38 | 38 | } elseif ('' !== $object->getVar($key)) { |
| 39 | - $this->addElement(new \XoopsFormLabel('', "<img src='" . $object_imageurl . $object->getVar($key) . "' alt=''><br><br>")); |
|
| 39 | + $this->addElement(new \XoopsFormLabel('', "<img src='".$object_imageurl.$object->getVar($key)."' alt=''><br><br>")); |
|
| 40 | 40 | } |
| 41 | 41 | |
| 42 | 42 | // require_once SMARTOBJECT_ROOT_PATH . 'class/form/elements/smartformfileuploadelement.php'; |
| 43 | 43 | $this->addElement(new SmartFormFileUploadElement($object, $key)); |
| 44 | 44 | |
| 45 | - $this->addElement(new \XoopsFormLabel('<div style="height: 10px; padding-top: 8px; font-size: 80%;">' . _CO_SOBJECT_URL_FILE_DSC . '</div>', '')); |
|
| 45 | + $this->addElement(new \XoopsFormLabel('<div style="height: 10px; padding-top: 8px; font-size: 80%;">'._CO_SOBJECT_URL_FILE_DSC.'</div>', '')); |
|
| 46 | 46 | // require_once SMARTOBJECT_ROOT_PATH . 'class/form/elements/smartformtextelement.php'; |
| 47 | 47 | // require_once SMARTOBJECT_ROOT_PATH . 'class/form/elements/smartformcheckelement.php'; |
| 48 | 48 | |
| 49 | - $this->addElement(new \XoopsFormLabel('', '<br>' . _CO_SOBJECT_URL_FILE)); |
|
| 50 | - $this->addElement(new SmartFormTextElement($object, 'url_' . $key)); |
|
| 49 | + $this->addElement(new \XoopsFormLabel('', '<br>'._CO_SOBJECT_URL_FILE)); |
|
| 50 | + $this->addElement(new SmartFormTextElement($object, 'url_'.$key)); |
|
| 51 | 51 | $this->addElement(new \XoopsFormLabel('', '<br><br>')); |
| 52 | - $delete_check = new SmartFormCheckElement('', 'delete_' . $key); |
|
| 53 | - $delete_check->addOption(1, '<span style="color:red;">' . _CO_SOBJECT_DELETE . '</span>'); |
|
| 52 | + $delete_check = new SmartFormCheckElement('', 'delete_'.$key); |
|
| 53 | + $delete_check->addOption(1, '<span style="color:red;">'._CO_SOBJECT_DELETE.'</span>'); |
|
| 54 | 54 | $this->addElement($delete_check); |
| 55 | 55 | } |
| 56 | 56 | } |
@@ -33,7 +33,7 @@ discard block |
||
| 33 | 33 | */ |
| 34 | 34 | protected function __construct($debug = false) |
| 35 | 35 | { |
| 36 | - $this->debug = $debug; |
|
| 36 | + $this->debug = $debug; |
|
| 37 | 37 | parent::__construct(basename(dirname(__DIR__))); |
| 38 | 38 | } |
| 39 | 39 | |
@@ -71,7 +71,7 @@ discard block |
||
| 71 | 71 | { |
| 72 | 72 | $ret = false; |
| 73 | 73 | $db = \XoopsDatabaseFactory::getDatabaseConnection(); |
| 74 | - $class = '\\XoopsModules\\' . ucfirst(strtolower(basename(dirname(__DIR__)))) . '\\' . $name . 'Handler'; |
|
| 74 | + $class = '\\XoopsModules\\'.ucfirst(strtolower(basename(dirname(__DIR__)))).'\\'.$name.'Handler'; |
|
| 75 | 75 | $ret = new $class($db); |
| 76 | 76 | return $ret; |
| 77 | 77 | } |
@@ -20,7 +20,7 @@ discard block |
||
| 20 | 20 | * |
| 21 | 21 | */ |
| 22 | 22 | |
| 23 | -require_once __DIR__ . '/../../include/common.php'; |
|
| 23 | +require_once __DIR__.'/../../include/common.php'; |
|
| 24 | 24 | |
| 25 | 25 | /** |
| 26 | 26 | * Class Configurator |
@@ -45,7 +45,7 @@ discard block |
||
| 45 | 45 | $moduleDirName = basename(dirname(__DIR__)); |
| 46 | 46 | $capsDirName = strtoupper($moduleDirName); |
| 47 | 47 | |
| 48 | - require_once __DIR__ . '/../../include/config.php'; |
|
| 48 | + require_once __DIR__.'/../../include/config.php'; |
|
| 49 | 49 | $config = getConfig(); |
| 50 | 50 | |
| 51 | 51 | $this->name = $config->name; |