@@ -69,14 +69,14 @@ |
||
| 69 | 69 | { |
| 70 | 70 | $ret = ''; |
| 71 | 71 | if (is_array($selector)) { |
| 72 | - $ret .= $t . implode("\n", $selector) . ' {'; |
|
| 72 | + $ret .= $t.implode("\n", $selector).' {'; |
|
| 73 | 73 | } else { |
| 74 | - $ret .= $selector . ' {'; |
|
| 74 | + $ret .= $selector.' {'; |
|
| 75 | 75 | } |
| 76 | 76 | if (is_array($content)) { |
| 77 | - $ret .= $t . implode("\n", $content) . ';'; |
|
| 77 | + $ret .= $t.implode("\n", $content).';'; |
|
| 78 | 78 | } else { |
| 79 | - $ret .= $content . ';'; |
|
| 79 | + $ret .= $content.';'; |
|
| 80 | 80 | } |
| 81 | 81 | $ret = '}'; |
| 82 | 82 | |
@@ -110,9 +110,9 @@ |
||
| 110 | 110 | </div> |
| 111 | 111 | EOT; |
| 112 | 112 | if ('english' !== $language) { |
| 113 | - $this->create($moduleDirname, 'language/' . $language . '/help', $filename, $content, _AM_TDMCREATE_FILE_CREATED, _AM_TDMCREATE_FILE_NOTCREATED); |
|
| 113 | + $this->create($moduleDirname, 'language/'.$language.'/help', $filename, $content, _AM_TDMCREATE_FILE_CREATED, _AM_TDMCREATE_FILE_NOTCREATED); |
|
| 114 | 114 | } |
| 115 | - $this->create($moduleDirname, 'language/' . $GLOBALS['xoopsConfig']['language'] . '/help', $filename, $content, _AM_TDMCREATE_FILE_CREATED, _AM_TDMCREATE_FILE_NOTCREATED); |
|
| 115 | + $this->create($moduleDirname, 'language/'.$GLOBALS['xoopsConfig']['language'].'/help', $filename, $content, _AM_TDMCREATE_FILE_CREATED, _AM_TDMCREATE_FILE_NOTCREATED); |
|
| 116 | 116 | |
| 117 | 117 | return $this->renderFile(); |
| 118 | 118 | } |
@@ -101,7 +101,7 @@ |
||
| 101 | 101 | webmaster |
| 102 | 102 | {X_ADMINMAIL} |
| 103 | 103 | EOT; |
| 104 | - $this->create($moduleDirname, 'language/' . $GLOBALS['xoopsConfig']['language'] . '/mail_template', $filename, $content, _AM_TDMCREATE_FILE_CREATED, _AM_TDMCREATE_FILE_NOTCREATED); |
|
| 104 | + $this->create($moduleDirname, 'language/'.$GLOBALS['xoopsConfig']['language'].'/mail_template', $filename, $content, _AM_TDMCREATE_FILE_CREATED, _AM_TDMCREATE_FILE_NOTCREATED); |
|
| 105 | 105 | |
| 106 | 106 | return $this->renderFile(); |
| 107 | 107 | } |
@@ -41,16 +41,16 @@ |
||
| 41 | 41 | */ |
| 42 | 42 | public function render() |
| 43 | 43 | { |
| 44 | - $ret = ($this->getTitle() ? '<div class=" center head ">' . $this->getTitle() . '</div>' : ''); |
|
| 45 | - $ret .= '<form name="' . $this->getName() . '" id="' . $this->getName() . '" action="' . $this->getAction() . '" method="' . $this->getMethod() . '"' . $this->getExtra() . '>' . NWLINE; |
|
| 44 | + $ret = ($this->getTitle() ? '<div class=" center head ">'.$this->getTitle().'</div>' : ''); |
|
| 45 | + $ret .= '<form name="'.$this->getName().'" id="'.$this->getName().'" action="'.$this->getAction().'" method="'.$this->getMethod().'"'.$this->getExtra().'>'.NWLINE; |
|
| 46 | 46 | foreach ($this->getElements() as $ele) { |
| 47 | 47 | if (!$ele->isHidden()) { |
| 48 | - $ret .= '<div class="' . $ele->getClass() . '"><strong>' . $ele->getCaption() . '</strong>' . $ele->render() . '</div>' . NWLINE; |
|
| 48 | + $ret .= '<div class="'.$ele->getClass().'"><strong>'.$ele->getCaption().'</strong>'.$ele->render().'</div>'.NWLINE; |
|
| 49 | 49 | } else { |
| 50 | 50 | $ret .= $ele->render(); |
| 51 | 51 | } |
| 52 | 52 | } |
| 53 | - $ret .= NWLINE . '</form>'; |
|
| 53 | + $ret .= NWLINE.'</form>'; |
|
| 54 | 54 | |
| 55 | 55 | return $ret; |
| 56 | 56 | } |
@@ -51,11 +51,11 @@ discard block |
||
| 51 | 51 | } |
| 52 | 52 | $ret .= '<td class="radio">'; |
| 53 | 53 | } |
| 54 | - $ret .= '<input type="radio" name="' . $ele_name . '" id="' . $ele_name . '[' . $value . ']' . $id_ele . '" title = "' . htmlspecialchars($ele_title, ENT_QUOTES) . '" value="' . htmlspecialchars($value, ENT_QUOTES) . '"'; |
|
| 54 | + $ret .= '<input type="radio" name="'.$ele_name.'" id="'.$ele_name.'['.$value.']'.$id_ele.'" title = "'.htmlspecialchars($ele_title, ENT_QUOTES).'" value="'.htmlspecialchars($value, ENT_QUOTES).'"'; |
|
| 55 | 55 | if (isset($ele_value) && $value == $ele_value) { |
| 56 | 56 | $ret .= ' checked'; |
| 57 | 57 | } |
| 58 | - $ret .= $ele_extra . ' />' . "<label name='xolb_{$ele_name}' for='" . $ele_name . '[' . $value . ']' . $id_ele . "'><span><span></span></span>" . $name . '</label>' . $ele_delimeter; |
|
| 58 | + $ret .= $ele_extra.' />'."<label name='xolb_{$ele_name}' for='".$ele_name.'['.$value.']'.$id_ele."'><span><span></span></span>".$name.'</label>'.$ele_delimeter; |
|
| 59 | 59 | if (!empty($this->columns)) { |
| 60 | 60 | $ret .= '</td>'; |
| 61 | 61 | if (0 == ++$i % $this->columns) { |
@@ -66,7 +66,7 @@ discard block |
||
| 66 | 66 | if (!empty($this->columns)) { |
| 67 | 67 | $span = $i % $this->columns; |
| 68 | 68 | if ($span) { |
| 69 | - $ret .= '<td colspan="' . ($this->columns - $span) . '"></td></tr>'; |
|
| 69 | + $ret .= '<td colspan="'.($this->columns - $span).'"></td></tr>'; |
|
| 70 | 70 | } |
| 71 | 71 | $ret .= '</table>'; |
| 72 | 72 | } |
@@ -4,12 +4,12 @@ discard block |
||
| 4 | 4 | * @see http://www.php-fig.org/psr/psr-4/examples/ |
| 5 | 5 | */ |
| 6 | 6 | spl_autoload_register( |
| 7 | - static function ($class) { |
|
| 7 | + static function($class) { |
|
| 8 | 8 | // project-specific namespace prefix |
| 9 | - $prefix = 'XoopsModules\\' . ucfirst(basename(dirname(__DIR__))); |
|
| 9 | + $prefix = 'XoopsModules\\'.ucfirst(basename(dirname(__DIR__))); |
|
| 10 | 10 | |
| 11 | 11 | // base directory for the namespace prefix |
| 12 | - $baseDir = __DIR__ . '/../class/'; |
|
| 12 | + $baseDir = __DIR__.'/../class/'; |
|
| 13 | 13 | |
| 14 | 14 | // does the class use the namespace prefix? |
| 15 | 15 | $len = mb_strlen($prefix); |
@@ -24,7 +24,7 @@ discard block |
||
| 24 | 24 | // replace the namespace prefix with the base directory, replace namespace |
| 25 | 25 | // separators with directory separators in the relative class name, append |
| 26 | 26 | // with .php |
| 27 | - $file = $baseDir . str_replace('\\', '/', $relativeClass) . '.php'; |
|
| 27 | + $file = $baseDir.str_replace('\\', '/', $relativeClass).'.php'; |
|
| 28 | 28 | |
| 29 | 29 | // if the file exists, require it |
| 30 | 30 | if (file_exists($file)) { |
@@ -21,7 +21,7 @@ discard block |
||
| 21 | 21 | |
| 22 | 22 | use Xmf\Request; |
| 23 | 23 | |
| 24 | -include __DIR__ . '/header.php'; |
|
| 24 | +include __DIR__.'/header.php'; |
|
| 25 | 25 | |
| 26 | 26 | $adminObject = \Xmf\Module\Admin::getInstance(); |
| 27 | 27 | |
@@ -60,12 +60,12 @@ discard block |
||
| 60 | 60 | $fb_content = Request::getText('fb_content', ''); |
| 61 | 61 | $fb_content = str_replace(["\r\n", "\n", "\r"], '<br>', $fb_content); //clean line break from dhtmltextarea |
| 62 | 62 | |
| 63 | - $title = constant('CO_' . $moduleDirNameUpper . '_' . 'FB_SEND_FOR') . $GLOBALS['xoopsModule']->getVar('dirname'); |
|
| 64 | - $body = constant('CO_' . $moduleDirNameUpper . '_' . 'FB_NAME') . ': ' . $your_name . '<br>'; |
|
| 65 | - $body .= constant('CO_' . $moduleDirNameUpper . '_' . 'FB_MAIL') . ': ' . $your_mail . '<br>'; |
|
| 66 | - $body .= constant('CO_' . $moduleDirNameUpper . '_' . 'FB_SITE') . ': ' . $your_site . '<br>'; |
|
| 67 | - $body .= constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE') . ': ' . $fb_type . '<br><br>'; |
|
| 68 | - $body .= constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE_CONTENT') . ':<br>'; |
|
| 63 | + $title = constant('CO_'.$moduleDirNameUpper.'_'.'FB_SEND_FOR').$GLOBALS['xoopsModule']->getVar('dirname'); |
|
| 64 | + $body = constant('CO_'.$moduleDirNameUpper.'_'.'FB_NAME').': '.$your_name.'<br>'; |
|
| 65 | + $body .= constant('CO_'.$moduleDirNameUpper.'_'.'FB_MAIL').': '.$your_mail.'<br>'; |
|
| 66 | + $body .= constant('CO_'.$moduleDirNameUpper.'_'.'FB_SITE').': '.$your_site.'<br>'; |
|
| 67 | + $body .= constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE').': '.$fb_type.'<br><br>'; |
|
| 68 | + $body .= constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE_CONTENT').':<br>'; |
|
| 69 | 69 | $body .= $fb_content; |
| 70 | 70 | $xoopsMailer = xoops_getMailer(); |
| 71 | 71 | $xoopsMailer->useMail(); |
@@ -77,7 +77,7 @@ discard block |
||
| 77 | 77 | $xoopsMailer->setBody($body); |
| 78 | 78 | $ret = $xoopsMailer->send(); |
| 79 | 79 | if ($ret) { |
| 80 | - redirect_header('index.php', 3, constant('CO_' . $moduleDirNameUpper . '_' . 'FB_SEND_SUCCESS')); |
|
| 80 | + redirect_header('index.php', 3, constant('CO_'.$moduleDirNameUpper.'_'.'FB_SEND_SUCCESS')); |
|
| 81 | 81 | } |
| 82 | 82 | |
| 83 | 83 | // show form with content again |
@@ -87,11 +87,11 @@ discard block |
||
| 87 | 87 | $feedback->type = $fb_type; |
| 88 | 88 | $feedback->content = $fb_content; |
| 89 | 89 | echo '<div align="center" style="width: 80%; padding: 10px; border: 2px solid #ff0000; color: #ff0000; margin-right:auto;margin-left:auto;"> |
| 90 | - <h3>' . constant('CO_' . $moduleDirNameUpper . '_' . 'FB_SEND_ERROR') . '</h3> |
|
| 90 | + <h3>' . constant('CO_'.$moduleDirNameUpper.'_'.'FB_SEND_ERROR').'</h3> |
|
| 91 | 91 | </div>'; |
| 92 | 92 | $form = $feedback->getFormFeedback(); |
| 93 | 93 | $form->display(); |
| 94 | 94 | |
| 95 | 95 | break; |
| 96 | 96 | } |
| 97 | -require __DIR__ . '/footer.php'; |
|
| 97 | +require __DIR__.'/footer.php'; |
|
@@ -54,7 +54,7 @@ discard block |
||
| 54 | 54 | //--></script> |
| 55 | 55 | <!-- End Form Validation JavaScript //-->', |
| 56 | 56 | ]; |
| 57 | - $paypalform = [ |
|
| 57 | + $paypalform = [ |
|
| 58 | 58 | 0 => '<form action="https://www.paypal.com/cgi-bin/webscr" method="post">', |
| 59 | 59 | 1 => '<input name="cmd" value="_s-xclick" type="hidden">', |
| 60 | 60 | 2 => '<input name="hosted_button_id" value="%s" type="hidden">', |
@@ -67,11 +67,11 @@ discard block |
||
| 67 | 67 | case 2: |
| 68 | 68 | $donationform[$key] = sprintf( |
| 69 | 69 | $donationform[$key], |
| 70 | - $GLOBALS['xoopsConfig']['sitename'] . ' - ' . ('' != $GLOBALS['xoopsUser']->getVar('name') ? $GLOBALS['xoopsUser']->getVar('name') . ' [' . $GLOBALS['xoopsUser']->getVar('uname') . ']' : $GLOBALS['xoopsUser']->getVar('uname')), |
|
| 70 | + $GLOBALS['xoopsConfig']['sitename'].' - '.('' != $GLOBALS['xoopsUser']->getVar('name') ? $GLOBALS['xoopsUser']->getVar('name').' ['.$GLOBALS['xoopsUser']->getVar('uname').']' : $GLOBALS['xoopsUser']->getVar('uname')), |
|
| 71 | 71 | $GLOBALS['xoopsUser']->getVar('email'), |
| 72 | 72 | XOOPS_LICENSE_KEY, |
| 73 | 73 | mb_strtoupper($GLOBALS['xoopsModule']->getVar('dirname')), |
| 74 | - mb_strtoupper($GLOBALS['xoopsModule']->getVar('dirname')) . ' ' . $GLOBALS['xoopsModule']->getVar('name') |
|
| 74 | + mb_strtoupper($GLOBALS['xoopsModule']->getVar('dirname')).' '.$GLOBALS['xoopsModule']->getVar('name') |
|
| 75 | 75 | ); |
| 76 | 76 | break; |
| 77 | 77 | } |
@@ -33,14 +33,14 @@ |
||
| 33 | 33 | $donationform = [ |
| 34 | 34 | 0 => '<form name="donation" id="donation" action="http://www.txmodxoops.org/modules/xdonations/" method="post" onsubmit="return xoopsFormValidate_donation();">', |
| 35 | 35 | 1 => '<table class="outer" cellspacing="1" width="100%"><tbody><tr><th colspan="2">' |
| 36 | - . _AM_TDMCREATE_ABOUT_MAKE_DONATION |
|
| 37 | - . '</th></tr><tr align="left" valign="top"><td class="head"><div class="xoops-form-element-caption-required"><span class="caption-text">' |
|
| 38 | - . _AM_TDMCREATE_DONATION_AMOUNT |
|
| 39 | - . '</span><span class="caption-marker">*</span></div></td><td class="even"><select size="1" name="item[A][amount]" id="item[A][amount]" title="Donation Amount"><option value="5">5.00 EUR</option><option value="10">10.00 EUR</option><option value="20">20.00 EUR</option><option value="40">40.00 EUR</option><option value="60">60.00 EUR</option><option value="80">80.00 EUR</option><option value="90">90.00 EUR</option><option value="100">100.00 EUR</option><option value="200">200.00 EUR</option></select></td></tr><tr align="left" valign="top"><td class="head"></td><td class="even"><input class="formButton" name="submit" id="submit" value="' |
|
| 40 | - . _SUBMIT |
|
| 41 | - . '" title="' |
|
| 42 | - . _SUBMIT |
|
| 43 | - . '" type="submit"></td></tr></tbody></table>', |
|
| 36 | + . _AM_TDMCREATE_ABOUT_MAKE_DONATION |
|
| 37 | + . '</th></tr><tr align="left" valign="top"><td class="head"><div class="xoops-form-element-caption-required"><span class="caption-text">' |
|
| 38 | + . _AM_TDMCREATE_DONATION_AMOUNT |
|
| 39 | + . '</span><span class="caption-marker">*</span></div></td><td class="even"><select size="1" name="item[A][amount]" id="item[A][amount]" title="Donation Amount"><option value="5">5.00 EUR</option><option value="10">10.00 EUR</option><option value="20">20.00 EUR</option><option value="40">40.00 EUR</option><option value="60">60.00 EUR</option><option value="80">80.00 EUR</option><option value="90">90.00 EUR</option><option value="100">100.00 EUR</option><option value="200">200.00 EUR</option></select></td></tr><tr align="left" valign="top"><td class="head"></td><td class="even"><input class="formButton" name="submit" id="submit" value="' |
|
| 40 | + . _SUBMIT |
|
| 41 | + . '" title="' |
|
| 42 | + . _SUBMIT |
|
| 43 | + . '" type="submit"></td></tr></tbody></table>', |
|
| 44 | 44 | 2 => '<input name="op" id="op" value="createinvoice" type="hidden"><input name="plugin" id="plugin" value="donations" type="hidden"><input name="donation" id="donation" value="1" type="hidden"><input name="drawfor" id="drawfor" value="Chronolabs Co-Operative" type="hidden"><input name="drawto" id="drawto" value="%s" type="hidden"><input name="drawto_email" id="drawto_email" value="%s" type="hidden"><input name="key" id="key" value="%s" type="hidden"><input name="currency" id="currency" value="EUR" type="hidden"><input name="weight_unit" id="weight_unit" value="kgs" type="hidden"><input name="item[A][cat]" id="item[A][cat]" value="XDN%s" type="hidden"><input name="item[A][name]" id="item[A][name]" value="Donation for %s" type="hidden"><input name="item[A][quantity]" id="item[A][quantity]" value="1" type="hidden"><input name="item[A][shipping]" id="item[A][shipping]" value="0" type="hidden"><input name="item[A][handling]" id="item[A][handling]" value="0" type="hidden"><input name="item[A][weight]" id="item[A][weight]" value="0" type="hidden"><input name="item[A][tax]" id="item[A][tax]" value="0" type="hidden"><input name="return" id="return" value="http://www.txmodxoops.org/modules/xdonations/success.php" type="hidden"><input name="cancel" id="cancel" value="http://www.txmodxoops.org/modules/xdonations/success.php" type="hidden"></form>', |
| 45 | 45 | 'D' => '', |
| 46 | 46 | 3 => '', |
@@ -6,17 +6,17 @@ |
||
| 6 | 6 | $moduleDirName = basename(dirname(__DIR__)); |
| 7 | 7 | |
| 8 | 8 | return (object)[ |
| 9 | - 'name' => mb_strtoupper($moduleDirName) . ' IconConfigurator', |
|
| 9 | + 'name' => mb_strtoupper($moduleDirName).' IconConfigurator', |
|
| 10 | 10 | 'icons' => [ |
| 11 | - 'edit' => "<img src='" . $pathIcon16 . "/edit.png' alt=" . _EDIT . "' align='middle'>", |
|
| 12 | - 'delete' => "<img src='" . $pathIcon16 . "/delete.png' alt='" . _DELETE . "' align='middle'>", |
|
| 13 | - 'clone' => "<img src='" . $pathIcon16 . "/editcopy.png' alt='" . _CLONE . "' align='middle'>", |
|
| 14 | - 'preview' => "<img src='" . $pathIcon16 . "/view.png' alt='" . _PREVIEW . "' align='middle'>", |
|
| 15 | - 'print' => "<img src='" . $pathIcon16 . "/printer.png' alt='" . _CLONE . "' align='middle'>", |
|
| 16 | - 'pdf' => "<img src='" . $pathIcon16 . "/pdf.png' alt='" . _CLONE . "' align='middle'>", |
|
| 17 | - 'add' => "<img src='" . $pathIcon16 . "/add.png' alt='" . _ADD . "' align='middle'>", |
|
| 18 | - '0' => "<img src='" . $pathIcon16 . "/0.png' alt='" . 0 . "' align='middle'>", |
|
| 19 | - '1' => "<img src='" . $pathIcon16 . "/1.png' alt='" . 1 . "' align='middle'>", |
|
| 11 | + 'edit' => "<img src='".$pathIcon16."/edit.png' alt="._EDIT."' align='middle'>", |
|
| 12 | + 'delete' => "<img src='".$pathIcon16."/delete.png' alt='"._DELETE."' align='middle'>", |
|
| 13 | + 'clone' => "<img src='".$pathIcon16."/editcopy.png' alt='"._CLONE."' align='middle'>", |
|
| 14 | + 'preview' => "<img src='".$pathIcon16."/view.png' alt='"._PREVIEW."' align='middle'>", |
|
| 15 | + 'print' => "<img src='".$pathIcon16."/printer.png' alt='"._CLONE."' align='middle'>", |
|
| 16 | + 'pdf' => "<img src='".$pathIcon16."/pdf.png' alt='"._CLONE."' align='middle'>", |
|
| 17 | + 'add' => "<img src='".$pathIcon16."/add.png' alt='"._ADD."' align='middle'>", |
|
| 18 | + '0' => "<img src='".$pathIcon16."/0.png' alt='".0."' align='middle'>", |
|
| 19 | + '1' => "<img src='".$pathIcon16."/1.png' alt='".1."' align='middle'>", |
|
| 20 | 20 | ], |
| 21 | 21 | ]; |
| 22 | 22 | } |