コード例 #1
0
require "HTML_top1.php";
?>

<title>Create/Edit Post &gt;&gt; ON DEMAND</title>
<?php 
require "styles.php";
require "scripts.php";
?>

<?php 
require "HTML_top2.php";
?>

<?php 
$class = getClassById($_GET["cid"]);
if (isset($_GET['pid'])) {
    $post = getPostById($_GET["pid"], $class->number);
}
require "topBar.php";
$uploadMsg = "Video files must be in .flv (Flash video) format and not exceed 10 MB in size.<br/>The video upload cap is currently subject to change, as we continue to optimize the site.<br/><br/>The video player on this site has a widescreen (16:9) aspect ratio with a resolution of 640x360 pixels.<br/>We suggest your video file match the video player's resolution or match 480x360 pixels if your video has a letterbox (4:3) aspect ratio.";
if (isset($_GET['pid'])) {
    echo '<h5>Edit Post: ' . $post->title . '</h5>';
    echo '<form action="post.php?cid=' . $_GET['cid'] . '&pid=' . $_GET['pid'] . '" method="post">';
    echo '<input type="text" name="edit_post_title" value="' . $post->title . '" size="50" /><br/>';
    echo '<input type="text" name="edit_post_topic" value="' . $post->topic . '" size="50" /><br/>';
    echo '<textarea name="edit_post_description" rows="10" cols="50">' . $post->description . '</textarea><br/>';
    echo '<input type="submit" name="edit_post" value="Submit Changes" />';
    echo '<a href="post.php?cid=' . $_GET['cid'] . '&pid=' . $_GET['pid'] . '"><input type="button" value="Cancel" /></a>';
    echo '</form><br/>';
    echo '<form action="class.php?cid=' . $_GET['cid'] . '" method="post" class="right" onsubmit="return confirm(\'Are you sure you want to delete this post?\')">';
コード例 #2
0
ファイル: roster.php プロジェクト: Clausi/tenebrae
<?php

if (!defined('IN_PHPBB')) {
    exit;
}
$query = "SELECT * FROM " . $TableNames['roster'] . " ORDER BY name";
$result = $db->sql_query($query);
while ($row = $db->sql_fetchrow($result)) {
    if ($row['active'] == 0) {
        $template->assign_block_vars('n_exMembers', array('NAME' => $row['name'], 'REALM' => $row['realm'], 'LEVEL' => $row['level'], 'ILEVEL' => $row['iLevel'], 'CLASS' => $row['class'], 'CLASSNAME' => getGermanClass(getClassById($row['class'])), 'RACE' => $row['race'], 'RACENAME' => getGermanRace(getRaceById($row['race'])), 'GENDER' => $row['gender'], 'LASTSEENTIMESTAMP' => strtotime($row['cache']), 'LASTSEEN' => $user->format_date(strtotime($row['cache']), false, true)));
    } else {
        $template->assign_block_vars('n_members', array('NAME' => $row['name'], 'RANK' => $row['rank'], 'RANKNAME' => getRank($row['rank'], $ranks), 'REALM' => $row['realm'], 'LEVEL' => $row['level'], 'ILEVEL' => $row['iLevel'], 'CLASS' => $row['class'], 'CLASSNAME' => getGermanClass(getClassById($row['class'])), 'RACE' => $row['race'], 'RACENAME' => getGermanRace(getRaceById($row['race'])), 'GENDER' => $row['gender'], 'ACHIEVEMENTPOINTS' => $row['achievementPoints']));
    }
}
$db->sql_freeresult($result);