Jetzt kostenlos Anmelden!

Catman Männlich

ist gerade angekommen

Beiträge: 33

Geschlecht: Männlich

PHPKIT Version: 1.6.4

1

Donnerstag, 24. Juli 2008, 15:02

IM´s (PN´s) ausdrucken

Um IM´s bzw. PN´s ausdrucken zu können müssen folgende Änderungen vorgenommen werden.

neue Datei erstellen= pkinc/public/imcenter_print.php:

PHP-Quelltext

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 

if(!defined('pkFRONTEND') || pkFRONTEND!='public') 
die('Direct access to this location is not permitted.'); 


$modehash=array('print'); 
$mode=(isset($_REQUEST['mode']) && in_array($_REQUEST['mode'],$modehash)) ? $_REQUEST['mode'] : NULL; 

switch($mode) 
{ 
case 'print' pkLoadClass($BBCODE,'bbcode'); 

$pkDISPLAYPRINT=true$imid=(isset($_REQUEST['imid']) && intval($_REQUEST['imid'])>0) ? intval($_REQUEST['imid']) : 0$iminfo=$SQL->fetch_assoc($SQL->query("SELECT * FROM ".$db_tab['im']." where im_id='".$imid."'")); 

$im_title=pkEntities($iminfo['im_title']); 

$userinfo_im_to=$SQL->fetch_array($SQL->query("SELECT user_id, user_nick FROM ".pkSQLTAB_USER." WHERE user_id='".$iminfo['im_to']."' LIMIT 1")); 
$im_to=pkEntities($userinfo_im_to['user_nick']); 

$userinfo=$SQL->fetch_array($SQL->query("SELECT user_id, user_nick FROM ".pkSQLTAB_USER." WHERE user_id='".$iminfo['im_autor']."' LIMIT 1")); 
$im_autor=pkEntities($userinfo['user_nick']); 
$im_text=$BBCODE->parse($iminfo['im_text'],0,$config['text_ubb'],$config['text_smilies'],$config['text_images'],1,pkGetConfig('user_imageresize'),pkGetConfig('user_textwrap')); 

$im_time=formattime($iminfo['im_time']); 
$print_time=formattime(); 

eval("\$site_body.= \"".pkTpl("im_print")."\";"); 
break; 
unset ($iminfo); 
} 
?>



neue Datei erstellen= pkinc/publictpl/im_print.htm:

Quellcode

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
<table class="print" width="500" border="0" cellpadding="1" cellspacing="0"> 
<tr> 
<td class="print" align="left">$config[site_name]</td><td class="print" align="right">Pers&ouml;nliche Nachricht</td> 
</tr> 
<tr> 
<td class="print" align="center" colspan="2"> 
<img border="0" height="1" width="100%" alt="" title="" src="images/black.gif" /></td> 
</tr> 
<tr> 
<td class="print"><i><b>$im_title</b></i></td> 
<td class="print" align="right">$im_time</td> 
</tr> 
<tr> 
<td class="print" align="left" colspan="2">von: $im_autor</td> 
</tr> 
<tr> 
<td class="print" align="left" colspan="2">an: $im_to</td> 
</tr> 
<tr> 
<td class="print" align="left" colspan="2"><br />$im_text<br /></td> 
</tr> 
<tr> 
<td class="print" align="left" colspan="2"> 
<br /><font class="printsmall">gedruckt am $print_time</font></td> 
</tr> 
<tr> 
<td colspan="2"><img border="0" height="1" width="100%" alt="" title="" src="images/black.gif" /></td> 
</tr> 
<tr> 
<td class="print" align="left" colspan="2"><font class="printsmall">Message ID: $imid</font></td> 
</tr> 
</table>


editiere Datei: pkinc/publictpl/imcenter_receive_row.htm

suche:

Quellcode

1
2
3
<tr> 
<td width="50%" align="center"><a href="include.php?path=privatemessages&reply=$iminfo[im_id]&writeim=1"><img align="top" border="0" alt="Antworten" src="images/reply.gif" width="20" height="16" /></a></td> 
<td width="50%" align="center"><input class="checkbox" type="checkbox" name="delim_received[]" value="$iminfo[im_id]"></td>


ändern in:

Quellcode

1
2
3
4
<tr> 
<td width="33%" align="center"><a href="include.php?path=privatemessages&reply=$iminfo[im_id]&writeim=1"><img align="top" border="0" alt="Antworten" src="images/reply.gif" width="20" height="16" /></a></td> 
<td width="33%" align="center"><a target="printable" title="druckbare Version anzeigen" href="include.php?path=imcenter_print&mode=print&imid=$iminfo[im_id]"><img src="images/print.gif" border="0" alt="druckbare Version anzeigen" width="20" height="16" align="top" /></a></td> 
<td width="34%" align="center"><input class="checkbox" type="checkbox" name="delim_received[]" value="$iminfo[im_id]"></td>



editiere Datei: pkinc/publictpl/imcenter_show_received_option.htm

ganz am Anfang der Datei einfügen:

Quellcode

1
<a target="printable" title="druckbare Version anzeigen" href="include.php?path=imcenter_print&mode=print&imid=$iminfo[im_id]"><img src="images/print.gif" border="0" alt="druckbare Version anzeigen" width="20" height="16" align="top" /></a>



editiere Datei: pkinc/publictpl/imcenter_send_row.htm

suche:

Quellcode

1
2
3
<tr> 
<td width="50%" align="center"><a href="include.php?path=privatemessages&userid=$iminfo[im_to]"><img align="top" border="0" alt="Weitere Nachricht an $userinfo[user_nick]" src="images/sendim.gif" width="20" height="16" /></a></td> 
<td width="50%" align="center"><input class="checkbox" type="checkbox" name="delim_send[]" value="$iminfo[im_id]"></td>


ändern in:

Quellcode

1
2
3
4
<tr> 
<td width="33%" align="center"><a href="include.php?path=privatemessages&userid=$iminfo[im_to]"><img align="top" border="0" alt="Weitere Nachricht an $userinfo[user_nick]" src="images/sendim.gif" width="20" height="16" /></a></td> 
<td width="33%" align="center"><a target="printable" title="druckbare Version anzeigen" href="include.php?path=imcenter_print&mode=print&imid=$iminfo[im_id]"><img src="images/print.gif" border="0" alt="druckbare Version anzeigen" width="20" height="16" align="top" /></a></td> 
<td width="34%" align="center"><input class="checkbox" type="checkbox" name="delim_send[]" value="$iminfo[im_id]"></td>



editiere Datei: pkinc/publictpl/imcenter_show_delete_option.htm

ganz am Anfang der Datei einfügen:

Quellcode

1
<a target="printable" title="druckbare Version anzeigen" href="include.php?path=imcenter_print&mode=print&imid=$iminfo[im_id]"><img src="images/print.gif" border="0" alt="druckbare Version anzeigen" width="20" height="16" align="top" /></a>
  • Zum Seitenanfang
  • Zum Seitenende

Jan-Lukas Männlich

findet sich zurecht

Beiträge: 141

Geschlecht: Männlich

Wohnort: Das schöne Neandertal

PHPKIT Version: 1.6.5

2

Donnerstag, 24. Juli 2008, 20:06

SUPER,

wollte ich immer schon mal widerhaben, für die 1.6.03 gab es das ja.

Werde ich nachher einbauen

Danke
  • Zum Seitenanfang
  • Zum Seitenende