| 1 |
wakaba |
1.1 |
<? |
| 2 |
|
|
header("Expires: ".gmdate("D, d M Y H:i:s",time()+(3600*24))." GMT"); |
| 3 |
|
|
include "config.inc"; |
| 4 |
|
|
include "$file_newsportal"; |
| 5 |
|
|
|
| 6 |
|
|
$url=explode("/",trim($PATH_INFO)); |
| 7 |
|
|
$id = "<".urldecode($url[1]).">"; |
| 8 |
|
|
$message=read_message($id); |
| 9 |
|
|
if (!$message) { |
| 10 |
|
|
$group=$url[1]; |
| 11 |
|
|
$id=str_replace(".html","",$url[2]); |
| 12 |
|
|
$message=read_message($id,0,$group); |
| 13 |
|
|
if (!$message) { |
| 14 |
|
|
header ("HTTP/1.0 404 Not Found"); |
| 15 |
|
|
$subject=$title; |
| 16 |
|
|
$title.=' - Article not found'; |
| 17 |
|
|
} else { |
| 18 |
|
|
$subject=htmlspecialchars($message->header->subject); |
| 19 |
|
|
$title.= ' - '.$subject; |
| 20 |
|
|
} |
| 21 |
|
|
} else { |
| 22 |
|
|
$group=$message->header->newsgroups; |
| 23 |
|
|
$subject=htmlspecialchars($message->header->subject); |
| 24 |
|
|
$title.= ' - '.$subject; |
| 25 |
|
|
} |
| 26 |
|
|
include "body.inc"; |
| 27 |
|
|
?> |
| 28 |
|
|
|
| 29 |
wakaba |
1.2 |
<h1><? echo $subject; ?></h1> |
| 30 |
wakaba |
1.1 |
|
| 31 |
wakaba |
1.2 |
<p> |
| 32 |
wakaba |
1.1 |
<? |
| 33 |
|
|
if ((!$readonly) && ($message)) |
| 34 |
wakaba |
1.2 |
echo '[<a href="../../'.$file_post.'?type=reply&id='.urlencode($id). |
| 35 |
wakaba |
1.1 |
'&group='.urlencode($group).'">'.$text_article["button_answer"].'</a>]'."\n"; |
| 36 |
|
|
echo '[<a href="../../'.$file_thread.'/'.urlencode($group).'/">'.$group.'</a>]'; |
| 37 |
|
|
?> |
| 38 |
|
|
</p> |
| 39 |
|
|
<p> |
| 40 |
|
|
<? |
| 41 |
|
|
flush(); |
| 42 |
|
|
// Code for the next and previous button |
| 43 |
|
|
/* |
| 44 |
|
|
$spoolopenmodus=0; |
| 45 |
|
|
$ns=OpenNNTPconnection(); |
| 46 |
|
|
$headers = readOverview($ns,$group,1,$spoolopenmodus); |
| 47 |
|
|
$next = $headers[$message->header->id]; |
| 48 |
|
|
echo "-".$next->subject."-"; |
| 49 |
wakaba |
1.2 |
echo '[<a href="'.$next->number.'.html">Next</a>]'; |
| 50 |
wakaba |
1.1 |
*/ |
| 51 |
|
|
?> |
| 52 |
|
|
</p> |
| 53 |
wakaba |
1.2 |
<table> |
| 54 |
|
|
<tr><td> |
| 55 |
wakaba |
1.1 |
|
| 56 |
|
|
<? |
| 57 |
|
|
if (!$message) |
| 58 |
|
|
echo $text_error["article_not_found"]; |
| 59 |
|
|
else |
| 60 |
|
|
show_article($group,$id,0,$message); |
| 61 |
|
|
?> |
| 62 |
|
|
|
| 63 |
|
|
</td></tr></table> |
| 64 |
|
|
|
| 65 |
|
|
<? include "footer.inc";?> |