%%document-view-editor-html%%
progmin : / (context #156)
2002-06-11 21:37:51

%%preprocess%%
 // format the object for display
$this->beryliumToHtml(); 
$this->getBaseUrl();
$this->timeFormat();

if ($this->id=="") {
	header("HTTP/1.0 404 Not Found");
	}
else {
	$this->context->commentsRow= "
	<tr>
		<td valign=top><a name='comments'>&nbsp;</a></td>
		<td><span class=documentTitle>Discussion of <i>$this->title</i>:</span>
			{list:SELECT obj.* FROM comment AS obj WHERE obj.rank>=100 AND obj.siteid='$site->id' AND obj.parentobjtype='document' AND obj.parentid='$this->id' $this->statuswhere $this->publicwhere ORDER BY obj.created ASC;list}</td>
		<td>&nbsp;</td>
	</tr>
	";
	$this->parseCBML("commentsRow");
	$this->commentsRow= $this->context->commentsRow;
	}

// get proper icon for private object
if (!$this->public) $this->iconpvt= "-pvt";
else $this->ispublic= "| <b>This item is public</b>";

// show sitemember if no author defined
$this->safeauthor= urlencode($this->author);
if ($this->author== "") $this->author="<a href='$site->baseUrl/sitemember-$this->sitememberid.html'>sitemember:$this->sitememberid</a>";
else $this->author="<a href='$site->baseUrl/sitemember-$this->safeauthor.html'>$this->author</a>";

// author icon should be here.

// show title in place of headline if no headline
if ($this->headline== "") $this->headline=$this->title;
	
// show default icon or alt icon from imageid
if ($this->imageid!="0") {
	$this->altIconTag= "<td rowspan=3 width=100 align=center valign=middle>".bparsebml("[image:$this->imageid;100,75]")."</td>";
	}
else $this->altIconTag= "";

$this->iconTag= "<img src='/bicons/document$this->iconpvt.png' border=0 alt='document:$this->id' title='document:$this->id' align=middle>";




%%header%%



%%css%%
.documentInfo {font-size: 12px; color: #999999; }
.documentInfo b {font-size: 12px; color: #aa9999; font-weight: bold; }
.documentTable TD {padding: 0px; margin: 0px; }
.documentFlavor {font-size: 12px; }
.documentTitle {font-size: 18px; line-height: 24px; font-weight: bold; color: #006699; }
.documentHeadline {font-size: 18px; line-height: 24px; font-weight: bold; color: #006699; }
.documentByline {font-size: 12px; line-height: 18px; }
.documentBody { font-family: Times New Roman, Times, serif; color: #333344; font-size: 12pt; line-height: 15pt; text-align: left; }
.documentBody IMG { margin-right: 10px; margin-left: 10px; margin-top: 4px; margin-bottom: 4px; }
.documentDescription {font-size: 12px; line-height: 18px; font-style: italic; color: #7a7a88; }

.documentBody .celltable {border: 0px;}
.documentBody .celltable .cell { font-family: Times New Roman, Times, serif; color: #333344; font-size: 12pt; line-height: 15pt; text-align: left; }
.documentBody .celltable .cellodd IMG { margin-right: 0px; margin-left: 10px; margin-top: 0px; margin-bottom: 0px; border: 1px; }
.documentBody .celltable .celleven IMG { margin-right: 10px; margin-left: 0px; margin-top: 0px; margin-bottom: 0px; border: 1px; }



%%template%%
<table border=0 class=documentTable>
	<tr>
		<td width='1%'><img src='/bicons/spacer.png' border=0 alt=document width=20 height=1></td>
		<td width='99%' class='documentFlavor'>$this->flavor:</td>
		$this->altIconTag
	</tr>
	<tr>
		<td colspan=2 class="documentHeadline">$this->iconTag $this->headline</td>
	</tr>
	<tr>
		<td>&nbsp;</td>
		<td>
			<span class='documentDescription'><blockquote>$this->description</blockquote></span>
			<span class="documentByline">By $this->author on $this->created.</span>
			<span class='documentInfo'><br>status: $this->status | rank: $this->rank $this->ispublic | <a href='#comments'>comments</a></span>
		</td>
	</tr>
</table>
<table border=0 class=documentTable>
	<tr>
		<td width='1%'><img src='/bicons/spacer.png' border=0 alt=document width=20 height=1></td>
		<td width='98%'>&nbsp;</td>
		<td width='1%'><img src='/bicons/spacer.png' border=0 alt=document width=20 height=1></td>
	</tr>
	<tr>
		<td>&nbsp;</td>
		<td class='documentBody'>$this->body</td>
		<td>&nbsp;</td>
	</tr>
	<tr>
		<td>&nbsp;</td>
		<td class='buttons' align=right>
			<a href='$refreshURL?method=edit$session->cgi'><img src='/bicons/$object->objtype$object->iconpvt.png' border=0 alt='edit $object->objtype' title='edit $object->objtype #$object->id' align=middle></a>&nbsp;<a href='$object->baseUrl?method=edit$session->cgi'>edit this $object->objtype</a> 
			| <a href='$session->refreshURL'><img src='/bicons/refresh.png' border=0 alt='refresh page' title='refresh page' align=middle></a>&nbsp;<a href='$session->refreshURL'>refresh</a>
			| <a href='$folder->baseUrl?method=view$session->cgi'><img src='/bicons/folder-open.png' border=0 alt='parent folder' title='parent folder' align=middle></a>&nbsp;<a href='$folder->baseUrl?method=view$session->cgi'>$folder->title</a></td>
		<td>&nbsp;</td>
	</tr>
</table>




%%listrow%%
 



%%nullobject%%
<p><img src='/bicons/warning.png' alt='Warning' align=left><br>
	<b>The document you requested was not found.</b></p>
<p><a href='$session->scriptname$folder->name/document-.html?method=listall$session->cgi'>Here is a list</a> of all the documents in this folder.</p> 




%%footer%%
<table border=0 class=documentTable>
	<tr>
		<td width='1%'><img src='/bicons/spacer.png' border=0 alt=document width=20 height=1></td>
		<td width='98%'>&nbsp;</td>
		<td width='1%'><img src='/bicons/spacer.png' border=0 alt=document width=20 height=1></td>
	</tr>
	$this->commentsRow
</table>




%%postprocess%%



%%end of context%%
