Esempio n. 1
0
$old_slug = "";
$date = date("Y/m/d");
$status = "";
$content = "";
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Draft posts</title>
<link rel="stylesheet" type="text/css" href="admin.css" />

</head>

<body>
<h1>Draft posts</h1>
<?php 
include_once "menu.php";
?>
<table>
<?php 
$posts = loadPosts("DRAFT", "DATE");
foreach ($posts as $p) {
    echo "<tr><td width='1'>{$p["Publish Date"]}</td><td>{$p["Title"]}</td><td width='1'><nobr><a href='edit.php?uid={$p["UID"]}' class='button'>Edit</a> <a href='delete.php?uid={$p["UID"]}' class='button'>Delete</a></nobr></td>";
}
?>
</table>

</body>
</html>
Esempio n. 2
0
function performProcess()
{
    global $blogPath;
    echo '<p>Starting the process ... </p>';
    readConfig();
    writeConfig();
    loadPosts();
    echo '<p><strong>CONGRATULATIONS !! Your Pritlog installation has been updated to the 0.811</strong></p>';
    echo '<p><a href="' . $blogPath . '">Home page</a></p>';
    translationInfo();
}
Esempio n. 3
0
$old_slug = "";
$date = date("Y/m/d");
$status = "";
$content = "";
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Live posts</title>
<link rel="stylesheet" type="text/css" href="admin.css" />

</head>

<body>
<h1>Live posts</h1>
<?php 
include_once "menu.php";
?>
<table>
<?php 
$posts = loadPosts("LIVE", "DATE");
foreach ($posts as $p) {
    echo "<tr><td width='1'>{$p["Publish Date"]}</td><td>{$p["Title"]}</td><td width='1'><nobr><a href='edit.php?uid={$p["UID"]}' class='button'>Edit</a> <a href='delete.php?uid={$p["UID"]}' class='button'>Delete</a></nobr></td>";
}
?>
</table>

</body>
</html>
Esempio n. 4
0
function loadQueueItems($scope, $ct, $cv, $search, $tab_id, $lastid, $forumid, $postid)
{
    global $limit;
    global $control;
    global $nmDataService;
    global $start;
    global $logService;
    if (empty($tab_id) || $scope == 'watch' && !$control['watch'] || $scope == 'deleted' && !$control['deleted'] || $scope == 'unconfirmed' && !$control['unconfirmed']) {
        echo json_encode(array("success" => true, "total" => 0, "posts" => 0));
        return;
    }
    $status = 0;
    $st = $nmDataService->checkForumStatusByForumid($control['forumid']);
    //TODO made part of the control and also check public and role for the right combination
    if ($st) {
        $status = $st;
    }
    $lastids = [];
    if (is_array($forumid)) {
        $ret = loadPosts($scope, $ct, $cv, $search, $tab_id, $lastid, $forumid, $postid);
        $posts = $ret['posts'];
        $lastids = $ret['lastid'];
    } else {
        $posts = loadPosts($scope, $ct, $cv, $search, $tab_id, $lastid, $forumid, $postid);
        $lastids[] = 0;
    }
    //$posts=$postsA['res'];
    // $count=$postsA['total'];;
    // $actual=count($posts);
    //$logService->log('DEBUG','actual count='.$actual.' context=',$context,$global_username);
    /*if($count==$limit){
         // $count=2000;
         //  $count*=2;
          $count=$start+400;
      }*/
    if ($posts != false) {
        echo json_encode(array("success" => true, "lastids" => $lastids, "posts" => $posts, "control" => $control));
    } else {
        echo json_encode(array("success" => "true", "posts" => array(), "control" => $control));
    }
}