gUIFile("CKEditorSetup.php")); # HTML page setup $Heading = ($H_DisplayMode == "Adding") ? "Add New Page" : "Edit Page"; $AF->setPageTitle($Heading); $AllowedKeywords = Pages::getInstance()->getAllowedInsertionKeywords(); $InsertLeftButton = new HtmlButton("← Insert-L"); $InsertRightButton = new HtmlButton("Insert-R →"); $DeleteImageButton = new HtmlButton("Delete"); $DeleteImageButton->setIcon("Delete.svg"); $DeleteImageButton->addSemanticClass("btn-danger"); $DeleteImageButton->makeSubmitButton(); $UploadImageButton = new HtmlButton("Upload"); $UploadImageButton->setIcon("Upload.svg"); $LinkFileButton = new HtmlButton("Link"); $LinkFileButton->setIcon("Check.svg"); $DeleteFileButton = new HtmlButton("Delete"); $DeleteFileButton->setIcon("Delete.svg"); $DeleteFileButton->addSemanticClass("btn-danger"); $DeleteFileButton->makeSubmitButton(); $UploadFileButton = new HtmlButton("Upload"); $UploadFileButton->setIcon("Upload.svg"); $SubmitChangesButton = new HtmlButton($H_DisplayMode == "Adding" ? "Add" : "Save"); $SubmitChangesButton->setIcon($H_DisplayMode == "Adding" ? "Check.svg" : "Disk.svg"); $CancelButton = new HtmlButton("Cancel"); $CancelButton->setIcon("Cross.svg"); # ----- DISPLAY -------------------------------------------------------------- print "

# ".$Heading."

\n"; # display any error messages if (isset($H_ErrorMsgs)) { ?>

".$Msg."\n"; } ?>

Title |  | Displayed in the browser title bar, and also used by search engines who index the page.
Page Content | <?= htmlspecialchars($AF->escapeInsertionKeywords( $H_Content, $AllowedKeywords )) ?>
Summary | <?= htmlspecialchars($AF->escapeInsertionKeywords( $H_Summary, $AllowedKeywords )) ?> | Displayed in search results, both on the site and by external search engines like Google. If left blank, this will be auto-generated from the page content.
Keywords |  | Additional keywords that might be used to search for this page. (OPTIONAL)
Clean URL Path |  | If a "clean URL" path (e.g. my/new/page) is set, the page will be reachable at that address.
Images | get("Images", true); foreach ($Images as $Image) { $Id = $Image->id(); $ImageUrl = $Image->url("mv-image-preview"); $SafeAltText = htmlspecialchars($Image->AltText(), ENT_QUOTES | ENT_HTML5); $InsertLeftCommand = defaulthtmlentities( "mv_insertImage(" ."CKEDITOR.instances['F_Content']," ."'left'," ."'".$ImageUrl."'," ."'".$SafeAltText."'," ."false" .");" ); $InsertRightCommand = defaulthtmlentities( "mv_insertImage(" ."CKEDITOR.instances['F_Content']," ."'right'," ."'".$ImageUrl."'," ."'".$SafeAltText."'," ."false" .");" ); $InsertLeftButton->setOnclick($InsertLeftCommand); $InsertRightButton->setOnclick($InsertRightCommand); $DeleteImageButton->setOnclick("$('#ImageToDelete').val('" . $Id . "')"); ?>
"> | Alt Text: | getHtml(); ?> getHtml(); ?> getHtml(); ?>
| Alt Text: | getHtml(); ?>
Files | get("Files", true); foreach ($Files as $File) { $Id = $File->id(); $LinkCmd = defaulthtmlentities( "CKEDITOR.instances['F_Content'].mode != 'wysiwyg'" ."? alert('Link button only works in rich text mode')" .": CKEDITOR.instances['F_Content'].insertHtml(" ."'getLink()."\">'" ."+CKEDITOR.instances['F_Content'].getSelection()" .".getSelectedText()+'');" ); $LinkFileButton->setOnclick("$LinkCmd"); $DeleteFileButton->setOnclick("$('#FileToDelete').val('" . $Id . "');"); ?>
name()); ?> | getHtml(); ?> getHtml(); ?>
| getHtml(); ?>
Privileges Required for Viewing Page: | displaySet("ViewingPrivs", $H_Privileges); ?>
Created: | get("Added By Id", true)); $Created = StdLib::getPrettyTimestamp($H_Page->get("Creation Date"), true) ." by ".(($User instanceof User) ? $User->name() : "(unknown)").""; $Created = str_replace(" ", " ", $Created); print $Created; ?>
Last Modified: | get("Last Modified By Id", true)); $Modified = StdLib::getPrettyTimestamp($H_Page->get("Date Last Modified"), true) ." by ".(($User instanceof User) ? $User->name() : "(unknown)").""; $Modified = str_replace(" ", " ", $Modified); print $Modified; ?>
| getHtml(); ?> getHtml(); ?>