doNotCacheCurrentPage(); # display error message indicating no ID ?>
You do not have the permissions required to view this page.
get("Title")); # display edit and delete buttons if appropriate if ($Page->userCanEdit($User)) { $Editor = new \Metavus\InlineEditingUI( "index.php?P=P_Pages_InlineEdit&ID=".$Id ); $RestingControls = [ ".cw-pages-controls.cw-pages-delete", ".cw-pages-controls.cw-folders-addresource", ]; $EditingControls = [ ".cw-pages-controls.cw-pages-edit", ]; $Editor->onDiscardShowSelectors($RestingControls); $Editor->onCancelShowSelectors($RestingControls); $Editor->onSaveShowSelectors($RestingControls); $Editor->onEditShowSelectors($EditingControls); print ''; $DeleteButton = new HtmlButton("Delete"); $DeleteButton->setIcon("Delete.svg"); $DeleteButton->setSize(HtmlButton::SIZE_SMALL); $DeleteButton->addClass("float-end cw-pages-delete"); $DeleteButton->addSemanticClass("btn-danger"); $DeleteButton->setLink("index.php?P=P_Pages_DeletePage&ID=" . $Id); $FullEditorButton = new HtmlButton("Full Editor"); $FullEditorButton->setIcon("Pencil.svg"); $FullEditorButton->setSize(HtmlButton::SIZE_SMALL); $FullEditorButton->addClass("float-end cw-pages-edit"); $FullEditorButton->setLink("index.php?P=P_Pages_EditPage&ID=" . $Id); print $DeleteButton->getHtml(); print $FullEditorButton->getHtml(); $AF->signalEvent( "EVENT_HTML_INSERTION_POINT", [ $AF->getPageName(), "Resource Display Buttons", ["Resource" => $Page] ] ); ?> getEditingControlsHtml(); } # add meta tag for page description $Plugin = Pages::getInstance(); $Summary = $Page->get("Summary"); if ($Summary !== null) { $Summary = $AF->escapeInsertionKeywords( $Summary, $Plugin->getAllowedInsertionKeywords() ); $AF->addMetaTag([ "name" => "description", "content" => $Summary, ]); } # retrieve page content $PageContent = $Page->get("Content"); if ($PageContent === null) { $PageContent = ""; } # keep a copy of the unmodified version $SourceData = $PageContent; # if page contains tabs if ($Page->containsTabs()) { # make sure JavaScript and CSS files needed for tabs are loaded $AF->requireUIFile('jquery-ui.js'); $AF->requireUIFile('jquery-ui.css', ApplicationFramework::ORDER_FIRST); # add in tab markup $PageContent = Page::processTabMarkup($PageContent); } # make sure only allowed insertion keywords are expanded $PageContent = $AF->escapeInsertionKeywords( $PageContent, $Plugin->getAllowedInsertionKeywords() ); # ensure all tags in the content are closed $PageContent = StdLib::closeOpenTags($PageContent); # signal view of page $AF->signalEvent( "EVENT_FULL_RECORD_VIEW", ["ResourceId" => $Page->id()] ); # display the page $AF->requireUIFile('Pages_Controls.css'); print "{{PAGES-BEFORECONTENT}}"; print " "; print "