| @@ 429-497 (lines=69) @@ | ||
| 426 | * @param $variable |
|
| 427 | * @return string |
|
| 428 | */ |
|
| 429 | public static function getServiceLinks($variable) |
|
| 430 | { |
|
| 431 | global $xoopsUser, $xoopsDB, $xoopsModule, $xoopsModuleConfig, $xoopsConfig, $entrytype; |
|
| 432 | ||
| 433 | /** @var XoopsModuleHandler $moduleHandler */ |
|
| 434 | $moduleHandler = xoops_getHandler('module'); |
|
| 435 | $moduleInfo = $moduleHandler->get($xoopsModule->getVar('mid')); |
|
| 436 | $pathIcon16 = \Xmf\Module\Admin::iconUrl('', 16); |
|
| 437 | ||
| 438 | $srvlinks = ''; |
|
| 439 | if ($xoopsUser) { |
|
| 440 | if ($xoopsUser->isAdmin()) { |
|
| 441 | $srvlinks .= "<a TITLE=\"" |
|
| 442 | . _EDIT |
|
| 443 | . "\" href=\"admin/entry.php?op=mod&entryID=" |
|
| 444 | . $variable['id'] |
|
| 445 | . "\" target=\"_blank\"><img src=\"" |
|
| 446 | . $pathIcon16 . "/edit.png\" border=\"0\" alt=\"" |
|
| 447 | . _MD_LEXIKON_EDITTERM |
|
| 448 | . "\" width=\"16\" height=\"16\"></a> <a TITLE=\"" |
|
| 449 | . _DELETE |
|
| 450 | . "\" href=\"admin/entry.php?op=del&entryID=" |
|
| 451 | . $variable['id'] |
|
| 452 | . "\" target=\"_self\"><img src=\"" |
|
| 453 | . $pathIcon16 . "/delete.png\" border=\"0\" alt=\"" |
|
| 454 | . _MD_LEXIKON_DELTERM |
|
| 455 | . "\" width=\"16\" height=\"16\"></a> "; |
|
| 456 | } |
|
| 457 | } |
|
| 458 | if ($entrytype != '1') { |
|
| 459 | $srvlinks .= "<a TITLE=\"" |
|
| 460 | . _MD_LEXIKON_PRINTTERM |
|
| 461 | . "\" href=\"print.php?entryID=" |
|
| 462 | . $variable['id'] |
|
| 463 | . "\" target=\"_blank\"><img src=\"" |
|
| 464 | . $pathIcon16 . "/printer.png\" border=\"0\" alt=\"" |
|
| 465 | . _MD_LEXIKON_PRINTTERM |
|
| 466 | . "\" width=\"16\" height=\"16\"></a> <a TITLE=\"" |
|
| 467 | . _MD_LEXIKON_SENDTOFRIEND |
|
| 468 | . "\" href=\"mailto:?subject=" |
|
| 469 | . sprintf(_MD_LEXIKON_INTENTRY, $xoopsConfig['sitename']) |
|
| 470 | . '&body=' |
|
| 471 | . sprintf(_MD_LEXIKON_INTENTRYFOUND, $xoopsConfig['sitename']) |
|
| 472 | . ': ' |
|
| 473 | . XOOPS_URL |
|
| 474 | . '/modules/' |
|
| 475 | . $xoopsModule->dirname() |
|
| 476 | . '/entry.php?entryID=' |
|
| 477 | . $variable['id'] |
|
| 478 | . " \" target=\"_blank\"><img src=\"" |
|
| 479 | . $pathIcon16 . "/mail_replay.png\" border=\"0\" alt=\"" |
|
| 480 | . _MD_LEXIKON_SENDTOFRIEND |
|
| 481 | . "\" width=\"16\" height=\"16\"></a> "; |
|
| 482 | if (($xoopsModuleConfig['com_rule'] != 0) |
|
| 483 | && (!empty($xoopsModuleConfig['com_anonpost']) |
|
| 484 | || is_object($xoopsUser)) |
|
| 485 | ) { |
|
| 486 | $srvlinks .= "<a TITLE=\"" |
|
| 487 | . _COMMENTS |
|
| 488 | . "?\" href=\"comment_new.php?com_itemid=" |
|
| 489 | . $variable['id'] |
|
| 490 | . "\" target=\"_parent\"><img src=\"assets/images/comments.gif\" border=\"0\" alt=\"" |
|
| 491 | . _COMMENTS |
|
| 492 | . "?\" width=\"16\" height=\"16\"></a> "; |
|
| 493 | } |
|
| 494 | } |
|
| 495 | ||
| 496 | return $srvlinks; |
|
| 497 | } |
|
| 498 | ||
| 499 | // entry footer |
|
| 500 | /** |
|
| @@ 203-224 (lines=22) @@ | ||
| 200 | */ |
|
| 201 | ||
| 202 | // Functional links |
|
| 203 | function lx_serviceLinks ( $variable ) { |
|
| 204 | global $xoopsUser, $xoopsDB, $xoopsModule, $xoopsModuleConfig, $xoopsConfig, $entrytype; |
|
| 205 | ||
| 206 | $module_handler = xoops_gethandler('module'); |
|
| 207 | $moduleInfo = $module_handler->get($xoopsModule->getVar('mid')); |
|
| 208 | $pathIcon16 = $xoopsModule->getInfo('icons16'); |
|
| 209 | ||
| 210 | $srvlinks = ""; |
|
| 211 | if ( $xoopsUser ) { |
|
| 212 | if ( $xoopsUser->isAdmin() ) { |
|
| 213 | $srvlinks .= "<a title=\"" |
|
| 214 | . _EDIT |
|
| 215 | . "\" href=\"admin/entry.php?op=mod&entryID=" |
|
| 216 | . $variable['id'] |
|
| 217 | . "\" target=\"_blank\"><img src=\"" |
|
| 218 | . $pathIcon16 |
|
| 219 | . "/edit.png\" alt=\"" |
|
| 220 | . _MD_LEXIKON_EDITTERM |
|
| 221 | . "\" style=\"width:16px; height:16px;\"></a> <a TITLE=\"" |
|
| 222 | . _DELETE |
|
| 223 | . "\" href=\"admin/entry.php?op=del&entryID=" |
|
| 224 | . $variable['id'] |
|
| 225 | . "\" target=\"_self\"><img src=\"" |
|
| 226 | . $pathIcon16 |
|
| 227 | . "/delete.png\" alt=\"" |
|