File: commentdraw.inc

package info (click to toggle)
gallery 1.5-1sarge2
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 21,172 kB
  • ctags: 4,516
  • sloc: php: 26,456; sh: 427; perl: 188; makefile: 58; xml: 48
file content (49 lines) | stat: -rw-r--r-- 1,473 bytes parent folder | download
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
38
39
40
41
42
43
44
45
46
47
48
49
<?php /* $Id: commentdraw.inc,v 1.25 2004/12/15 15:26:25 jenst Exp $ */ ?>
<?php 

	global $commentdraw, $i, $index, $id;

// If the border color is not passed in, we do a black/white combo
if ($commentdraw["bordercolor"]) {
        $borderIn = $commentdraw["bordercolor"];
} else {
        $borderIn = "#FFFFFF";
}

$pixelImage = "<img src=\"" . getImagePath('pixel_trans.gif') . "\" width=\"1\" height=\"1\" alt=\"\">";

?>
<!-- Begin Comment -->
<table width="75%" align="center" border="0" class="commentbox" cellpadding="0" cellspacing="0">
<tr>
	<td class="commentboxhead"><?php echo _("From:") ?></td> 
	<td class="commentboxhead"><b><?php echo wordwrap($commentdraw["name"], 50, " ", 1) ?></b>
<?php
if ($gallery->user->isAdmin()) {
	echo "@ &nbsp;";
	echo $commentdraw["IPNumber"];
}
?>	</td>
	<td class="commentboxhead">(<?php echo $commentdraw["datePosted"] ?>)</td>
</tr>
<tr>
	<td colspan="3"><?php echo wordwrap($commentdraw["comment"], 100, " ", 1) ?></td>
</tr>

<?php
if ($gallery->user->canWriteToAlbum($gallery->album)) {
	echo "\n<tr>";
	echo "\n\t". '<td colspan="3" align="center" class="commentboxfooter">';
        $url = doCommand('delete-comment', 
				array('index'=> $commentdraw['index'], 
					'comment_index' => $i,
					'albumName' => $commentdraw['albumName'])
			);
	echo '<a href="#" onclick="javascript:' . popup($url,1) . '">['. _("delete comment") . ']</a>';
	echo "\n\t</td>";
	echo "\n</tr>";
}
?>
</table>
<br>
<!-- End Comment -->