|
Revision 11, 1.1 kB
(checked in by sven, 3 years ago)
|
snapshot of elgg 0.301
|
| Line | |
|---|
| 1 |
<?php |
|---|
| 2 |
|
|---|
| 3 |
|
|---|
| 4 |
|
|---|
| 5 |
// Run includes |
|---|
| 6 |
require("../includes.php"); |
|---|
| 7 |
|
|---|
| 8 |
run("profile:init"); |
|---|
| 9 |
run("friends:init"); |
|---|
| 10 |
run("weblogs:init"); |
|---|
| 11 |
|
|---|
| 12 |
define("context", "weblog"); |
|---|
| 13 |
|
|---|
| 14 |
global $profile_id; |
|---|
| 15 |
global $individual; |
|---|
| 16 |
|
|---|
| 17 |
$individual = 1; |
|---|
| 18 |
|
|---|
| 19 |
if (isset($_REQUEST['post'])) { |
|---|
| 20 |
|
|---|
| 21 |
$post = (int) $_REQUEST['post']; |
|---|
| 22 |
|
|---|
| 23 |
$where = run("users:access_level_sql_where",$_SESSION['userid']); |
|---|
| 24 |
$post = db_query("select * from weblog_posts where ($where) and ident = $post"); |
|---|
| 25 |
$post = $post[0]; |
|---|
| 26 |
|
|---|
| 27 |
global $page_owner; |
|---|
| 28 |
global $profile_id; |
|---|
| 29 |
$profile_id = $post->weblog; |
|---|
| 30 |
$page_owner = $post->weblog; |
|---|
| 31 |
|
|---|
| 32 |
$title = run("profile:display:name") . " :: Weblog :: " . stripslashes($post->title); |
|---|
| 33 |
|
|---|
| 34 |
$time = gmdate("F d, Y",$post->posted); |
|---|
| 35 |
$body = "<h2 class=\"weblogdateheader\">$time</h2>\n"; |
|---|
| 36 |
|
|---|
| 37 |
$body .= run("weblogs:posts:view:individual",$post); |
|---|
| 38 |
|
|---|
| 39 |
$body = run("templates:draw", array( |
|---|
| 40 |
'context' => 'contentholder', |
|---|
| 41 |
'title' => $title, |
|---|
| 42 |
'body' => $body |
|---|
| 43 |
) |
|---|
| 44 |
); |
|---|
| 45 |
|
|---|
| 46 |
echo run("templates:draw:page", array( |
|---|
| 47 |
$title, $body |
|---|
| 48 |
) |
|---|
| 49 |
); |
|---|
| 50 |
|
|---|
| 51 |
} |
|---|
| 52 |
|
|---|
| 53 |
?> |
|---|