Use PDO MySQL driver instead of MySQLi.
Use PDO MySQL driver instead of MySQLi.

File last commit:

881a86f051f9
217732d0fffa
Show More
post-page.php
104 lines | 3.2 KiB | text/x-php | XmlPhpLexer
/ post-page.php
Add most necessary files for admin interface.
r1 <?php
/* This is a blank form for new pages to be started.
It does not read past page information.
Some fields will be prefilled based on current author. */
require_once('include/admin.inc.php');
auth_redirect(); // Require logged in user to access this page.
adminhead('Write Static Page');
adminmenu('post-page.php');
?>
<script language="javascript" type="text/javascript" src="include/tiny_mce/tiny_mce.js"></script>
<script language="javascript" type="text/javascript">
tinyMCE.init({
mode : "exact",
elements: "content",
theme : "advanced",
theme_advanced_buttons1 : "bold,italic,underline,separator,strikethrough,justifyleft,justifycenter,justifyright,justifyfull,bullist,numlist,undo,redo,link,unlink,code,formatselect",
theme_advanced_buttons2 : "",
theme_advanced_buttons3 : "",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
theme_advanced_path_location : "bottom",
extended_valid_elements : "a[name|href|target|title|onclick],img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name],hr[class|width|size|noshade],font[face|size|color|style],span[class|align|style]",
theme_advanced_blockformats : "p,h3,h4,h5,h6"
});
</script>
<h2>Create New Page</h2>
<form enctype="multipart/form-data" action="edit-page.php" method="post" name="post" id="post">
<?php nonce_field('new-page'); ?>
<input type="hidden" name="action" value="new_page" />
<div id="poststuff">
<div id="moremeta">
<div id="grabit" class="dbx-group">
<fieldset id="pagenamediv" class="dbx-box">
<h3 class="dbx-handle">Page URL Name</h3>
<div class="dbx-content">
<input type="text" name="page_name" />
</div>
</fieldset>
<fieldset id="statusdiv" class="dbx-box">
<h3 class="dbx-handle">Published Status</h3>
<div class="dbx-content">
<label><input type="radio" name="page_status" value="draft" checked="checked"/>Draft</label>
<label><input type="radio" name="page_status" value="published"/>Published</label>
</div>
</fieldset>
</div>
</div>
<fieldset id="titlediv">
<legend>Title</legend>
<div><input type="text" name="title" size="40" tabindex="1" value="" id="title" /></div>
</fieldset>
<fieldset id="postdivrich">
<legend>Page</legend>
Clean up extraneous spaces at the ends of lines.
r8
Add most necessary files for admin interface.
r1 <style type="text/css">
#postdivrich table, #postdivrich #quicktags {border-top: none;}
#quicktags {border-bottom: none; padding-bottom: 2px; margin-bottom: -1px;}
#edButtons {border-bottom: 1px solid #ccc;}
</style>
<div><textarea class="mceEditor" rows="13" cols="40" name="content" tabindex="3" id="content"></textarea></div>
</fieldset>
<p class="submit">
<input name="save" type="submit" id="save" tabindex="3" value="Save and Continue Editing" style="font-weight: bold;" />
<input name="publish" type="submit" id="publish" tabindex="5" accesskey="p" value="Publish" />
</p>
<div class="dbx-b-ox-wrapper">
<fieldset id="cssdivrich">
<legend>Optional CSS</legend>
Clean up extraneous spaces at the ends of lines.
r8
Add most necessary files for admin interface.
r1 <style type="text/css">
#postdivrich table, #postdivrich #quicktags {border-top: none;}
#quicktags {border-bottom: none; padding-bottom: 2px; margin-bottom: -1px;}
#edButtons {border-bottom: 1px solid #ccc;}
</style>
<div><textarea rows="13" cols="40" name="style" tabindex="6" id="style"></textarea></div>
</fieldset>
</div>
</div>
</form>
<?php adminfooter() ?>