<td width="16" class="item<?php echo $i % 2 == 0 ? "Alt" : ""; ?> "> <img src="<?php echo iconUrl; ?> /section.gif" width="16" height="16" alt="" title="" /> </td> <td width="60%" class="item<?php echo $i % 2 == 0 ? "Alt" : ""; ?> "> <?php echo '<a href="' . $references[$i][2] . '">' . validateTextLength($references[$i][0], 60) . '</a>'; ?> </td> <td width="40%" class="small1 item<?php echo $i % 2 == 0 ? "Alt" : ""; ?> "> <?php echo $references[$i][3]; ?> </td> </tr> <?php } ?>
/** * Print blog index. * @param $categoryId Identifier of category. */ function printBlog($categoryId = -1) { global $dbi, $login, $site; if (!empty($this->id)) { if ($this->hasReadPermission()) { // Include language include scriptPath . "/" . folderBlog . "/include/language/" . $this->language . "/general.php"; if (!empty($this->id)) { // Get get values $day = getGetValue("day"); $month = getGetValue("month"); $year = getGetValue("year"); // Add meta links if ($this->hasAdministerPermission()) { $site->addMetaLink(scriptUrl . "/" . folderBlog . "/" . fileBlogEdit . "?blogId=" . $this->id, $lBlog["EditBlog"], "edit"); $site->addMetaLink(scriptUrl . "/" . folderUsers . "/" . fileEditPermissions . "?moduleContentTypeId=" . blogContentId . "&moduleContentId=" . $this->id, $lBlog["EditPermissions"], "permission"); } $site->addMetaLink($this->getBlogLink(), "", "direct"); $site->addMetaLink($this->getBlogLink() . "&print=1", "", "print"); $site->addMetaLink(scriptUrl . "/" . fileSendToFriend . "?url=" . urlencode($this->getBlogLink()) . "&title=" . urlencode($this->title) . "&summary=" . urlencode(validateTextLength($this->description, 100)), "", "recommend"); // Add navigation links $site->addNavigationLink(scriptUrl . "/" . folderBlog . "/" . fileBlogIndex, $lBlogIndex["Header"]); $site->addNavigationLink($this->getBlogLink(), $this->title); if ($categoryId != -1) { $category = new Category($categoryId); $site->addNavigationLink(scriptUrl . "/" . folderBlog . "/" . fileBlog . "?blogId=" . $this->id . "&categoryId=" . $categoryId, $categoryId == 0 ? $lBlogPost["Uncategorized"] : $category->title); } else { if (!empty($month) && !empty($year)) { $site->addNavigationLink(scriptUrl . "/" . folderBlog . "/" . fileBlog . "?blogId=" . $this->id . "&month=" . $month . "&year=" . $year, intToMonth($month) . " " . $year); } } // Register rss feeds $site->registerRSSFeed(scriptUrl . "/" . folderBlog . "/" . fileBlogPostRSS . "?blogId=" . $this->id, $this->title); $site->registerRSSFeed(scriptUrl . "/" . folderBlog . "/" . fileBlogCommentRSS . "?blogId=" . $this->id, $this->title . " - " . $lBlogPost["Comments"]); // Set website path $site->setPath(folderBlog); // Print common header $site->printHeader(); // Print blog body $this->printBlogBody($categoryId); // Print common footer $site->printFooter(); } } else { $login->printLoginForm(); exit; } } else { redirect(scriptUrl . "/" . folderBlog . "/" . fileBlogIndex); } }
echo "</td>"; echo "<td class=\"indexHeader\" align=\"center\"><b>" . $lCommentIndex["Spam"] . "</b></td>"; echo "</tr>"; $comment = new Comment(); for ($i = 0; list($id) = $result->fetchrow_array(); $i++) { $comment->init($id); $moduleContentTypeObject = $module->getModuleContentTypeObject($comment->moduleContentTypeId); echo "<tr>"; echo "<td height=\"30\" class=\"item" . ($i % 2 == 0 ? "Alt" : "") . "\">"; echo "<input type=\"checkbox\" name=\"comments[]\" value=\"" . $comment->id . "\" />"; echo "</td>"; echo "<td width=\"16\" class=\"item" . ($i % 2 == 0 ? "Alt" : "") . "\">"; echo "<a href=\"" . scriptUrl . "/" . folderComment . "/" . fileCommentEdit . "?commentId=" . $comment->id . "&return=1&" . (showPopup ? "popup=1" : "return=1") . "\"><img src=\"" . iconUrl . "/edit.gif\" border=\"0\" title=\"\" alt=\"\" /></a>"; echo "</td>"; echo "<td width=\"40%\" class=\"item" . ($i % 2 == 0 ? "Alt" : "") . "\">"; echo "<a href=\"" . $moduleContentTypeObject->getLink($comment->moduleContentId) . "#" . $comment->id . "\"" . (showPopup ? " target=\"_blank\"" : "") . ">" . (!empty($comment->subject) ? validateTextLength($comment->subject, 30) : "-") . "</a>"; echo "</td>"; echo "<td width=\"40%\" nowrap=\"nowrap\" class=\"small1 item" . ($i % 2 == 0 ? "Alt" : "") . "\">"; if (!empty($comment->userId)) { $user = new User($comment->userId); $name = printPopup(scriptUrl . "/" . fileUserProfile . "?profileId=" . $user->id . "&popup=1", $user->name); } else { $name = !empty($comment->mail) ? "<a href=\"mailto:" . $comment->mail . "\">" . (!empty($comment->name) ? $comment->name : "-") . "</a>" : (!empty($comment->name) ? $comment->name : "-"); } echo $name; echo "</td>"; echo "<td width=\"20%\" nowrap=\"nowrap\" class=\"small1 item" . ($i % 2 == 0 ? "Alt" : "") . "\">"; echo $site->generateTimestamp($comment->posted, true); echo "</td>"; echo "<td class=\"small1 item" . ($i % 2 == 0 ? "Alt" : "") . "\" align=\"center\">"; echo !$comment->spam ? "<a href=\"" . scriptUrl . "/" . folderComment . "/" . fileCommentIndex . "?commentId=" . $comment->id . "&spam=1\"><img src=\"" . iconUrl . "/spam.gif\" border=\"0\" alt=\"" . $lButtons["MarkSpam"] . "\" title=\"" . $lButtons["MarkSpam"] . "\" /></a>" : "<a href=\"" . scriptUrl . "/" . folderComment . "/" . fileCommentIndex . "?commentId=" . $comment->id . "&spam=0\"><img src=\"" . iconUrl . "/notspam.gif\" border=\"0\" alt=\"" . $lButtons["MarkNotSpam"] . "\" title=\"" . $lButtons["MarkNotSpam"] . "\" /></a>";
function setMetaKeywords($metaKeywords) { $metaKeywords = stripHtml(validateTextLength(parseString($metaKeywords), 300)); $this->metaKeywords = $metaKeywords; }
?> " border="0" /></a> </td> <td class="<?php echo $class; ?> "> <a href="<?php echo scriptUrl . "/" . folderFiles . "/" . fileFilesGetFile; ?> ?fileId=<?php echo $file->id; ?> " target="_blank"><?php echo validateTextLength($file->name, 30); ?> </a> </td> <td nowrap="nowrap" align="right" class="small1 <?php echo $class; ?> "> <?php $site->printFormattedSize($file->getSize()); ?> </td> <td nowrap="nowrap" class="small1 <?php echo $class;
<td width="40%" class="small1 item<?php echo $i % 2 == 0 ? "Alt" : ""; ?> "> <?php $moduleContentType = $module->getModuleContentTypeObject($moduleContentTypeId); if ($moduleContentType != null) { if (method_exists($moduleContentType, "getName")) { $name = trim($moduleContentType->getName($moduleContentId)); $link = method_exists($moduleContentType, "getLink") ? $moduleContentType->getLink($moduleContentId) : ""; if (!empty($name) && !empty($link)) { echo '<a href="' . $link . '">' . validateTextLength($name, 30) . '</a>'; } else { if (!empty($name)) { echo validateTextLength($name, 30); } else { echo "-"; } } } else { echo "-"; } } else { echo "-"; } ?> </td> <td width="20%" class="small1 item<?php echo $i % 2 == 0 ? "Alt" : "";