From: Andreas K. <la...@us...> - 2002-12-29 21:29:01
|
Update of /cvsroot/pn-modules/PN_Shoutbox/html/modules/Shoutbox/pnblocks In directory sc8-pr-cvs1:/tmp/cvs-serv28217/PN_Shoutbox/html/modules/Shoutbox/pnblocks Modified Files: shoutbox.php Log Message: update Index: shoutbox.php =================================================================== RCS file: /cvsroot/pn-modules/PN_Shoutbox/html/modules/Shoutbox/pnblocks/shoutbox.php,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** shoutbox.php 2 Dec 2002 16:44:29 -0000 1.3 --- shoutbox.php 29 Dec 2002 21:28:58 -0000 1.4 *************** *** 46,55 **** function blocks_shoutbox_block($row) { ! // config should move to module-vars ASAP ! $SB_dir = "modules/Shoutbox"; ! $SB_csvfile = $SB_dir."/shout.csv"; ! $SB_width = 150; ! $SB_height = 150; ! $SB_size = 20; $smiley[':green'] = "biggrin.gif"; --- 46,53 ---- function blocks_shoutbox_block($row) { ! $SB_csvfile = "modules/Shoutbox/shout.csv"; ! $sb_width = pnModGetVar('Shoutbox', 'sb_width'); ! $sb_height = pnModGetVar('Shoutbox', 'sb_height'); ! $sb_size = pnModGetVar('Shoutbox', 'sb_size'); $smiley[':green'] = "biggrin.gif"; *************** *** 106,110 **** if ($iframe) { // iframe capable browser goes here ! $output= "<IFRAME NAME=\"SB_shoutbox\" SRC=\"$SB_dir/show.php\" WIDTH=\"$SB_width\" HEIGHT=\"$SB_height\" FRAMEBORDER=\"0\"></IFRAME>"; $boxstuff = $output; } else { --- 104,108 ---- if ($iframe) { // iframe capable browser goes here ! $output= "<IFRAME NAME=\"SB_shoutbox\" SRC=\"modules.php?op=modload&name=Shoutbox&file=index&req=show\" WIDTH=\"$sb_width\" HEIGHT=\"$sb_height\" FRAMEBORDER=\"0\"></IFRAME>"; $boxstuff = $output; } else { *************** *** 144,165 **** $boxstuff .= "}</SCRIPT>\n"; ! $boxstuff .= "\n<FORM ACTION=\"modules.php?op=modload&name=Shoutbox&file=index\" METHOD=\"post\" NAME=\"SB_form\">\n"; // display some buttons ;) if (!pnSecAuthAction(0, 'Shoutbox_Block::', "$row[title]::", ACCESS_COMMENT)) { ! // anonymous user can't shout $boxstuff .= " "._SB_YOUAREANON."<br>"; } else { // user is at least allowed to comment ! if (pnUserLoggedIn()) { ! // user is logged in, get his name ! $username = pnUserGetVar('uname'); ! } else { ! // user is not logged in, get config var for anonymous ! $username = pnConfigGetVar('anonymous'); ! } ! $boxstuff .= "<INPUT TYPE='text' NAME='SB_text' size='$SB_size' MAXLENGTH='180'><BR>\n"; ! $boxstuff .= "<INPUT TYPE='hidden' NAME='username' value='$username'>\n"; $boxstuff .= "<INPUT TYPE='submit' VALUE='"._SB_SHOUT."'>\n"; } --- 142,156 ---- $boxstuff .= "}</SCRIPT>\n"; ! $boxstuff .= "\n<FORM ACTION=\"modules.php?op=modload&name=Shoutbox&file=index&req=shout\" METHOD=\"post\" NAME=\"SB_form\">\n"; // display some buttons ;) if (!pnSecAuthAction(0, 'Shoutbox_Block::', "$row[title]::", ACCESS_COMMENT)) { ! // not authorized to shout $boxstuff .= " "._SB_YOUAREANON."<br>"; } else { // user is at least allowed to comment ! $boxstuff .= "<INPUT TYPE='text' NAME='SB_text' size='$sb_size' MAXLENGTH='180'><BR>\n"; ! $boxstuff .= "<INPUT TYPE='hidden' name='authid' value='".pnSecGenAuthKey()."'>\n"; $boxstuff .= "<INPUT TYPE='submit' VALUE='"._SB_SHOUT."'>\n"; } *************** *** 182,186 **** $count = $count+1; if ($count==6) {$boxstuff.="<br>";} ! $boxstuff.="<a href=\"javascript:SB_smilie('$i')\" title='$i'><img src='$SB_dir/smileys/$sm' border='0'></a> \n"; } } --- 173,177 ---- $count = $count+1; if ($count==6) {$boxstuff.="<br>";} ! $boxstuff.="<a href=\"javascript:SB_smilie('$i')\" title='$i'><img src='modules/Shoutbox/smileys/$sm' border='0'></a> \n"; } } |