Source for file publish.php
Documentation is available at publish.php
//header('location: ../index.php?show=admin-write&mode=published');
$post->SetAuthor("admin");
if(isset ($_POST['title']))
$post->SetTitle($_POST['title']);
$post->SetTitle("Untitled");
if(isset ($_POST['content']))
if(strcmp($blog->GetSetting("HTML IN CONTENT"), 'YES') == 0) // HTML in content is activated.
$post->SetContent($_POST['content']);
// The following two lines manipulate any HTML tags in the content, so that it doesn't mess with our XML. May change to use regular expressions.
$post->SetContent(str_replace(PHP_EOL, "<br />", $content)); // If HTML in content is not activated, we replace all endlines with <br /> tags
if(isset ($_POST['tags']))
$post->SetTags($_POST['tags']);
$blog->PublishPost($post);
|