summaryrefslogtreecommitdiff
path: root/htdocs/new-post.php
blob: e6f4035acd5f0b6338c9aee015fe2b6640302fd1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<?php

/* Foursquare Community Site
 * 
 * Copyright (C) 2011 Foursquare Church.
 * 
 * Developers: Jesse Morgan <jmorgan@foursquarestaff.com>
 *
 */

require_once "src/base.inc.php";

require_once "src/header.inc.php";

echo "<h2>Submit Post</h2>";

echo "<form action=\"submit-post.php\" method=\"post\">";
echo "<p><label>Category: <select name=\"category\">";
foreach (Category::getCategories() as $short => $name) {
    echo "<option name=\"$short\">$name</option>";
}
echo "</select></label</p>";

echo "<p><label>Title: <input type=\"text\" name=\"title\" /></label></p>";

echo "<p><label for=\"desc\">Description:</label></p>";
echo "<p><textarea name=\"description\" id=\"desc\" rows=\"10\""
        . " cols=\"80\"></textarea></p>";

// TODO: Link to terms of service.
echo "<p><label><input type=\"checkbox\" name=\"tos\" value=\"1\" /> I agree to the terms of service.</label></p>";

echo "<p><input type=\"submit\" value=\"Submit\" /></p></form>";

require_once "src/footer.inc.php";

?>