[ Príspevok: 1 ] 
AutorSpráva
Offline

Prevádzkovateľ fóra
Prevádzkovateľ fóra
Hide Post Buttons

Registrovaný: 01.05.05
Príspevky: 12422
Témy: 1447 | 1447
Bydlisko: Bratislava
Vek: 32
NapísalOffline : 14.10.2006 15:06 | Hide Post Buttons

Kód:
##############################################################
## MOD Title:      Hide Post Buttons
## MOD Author: OXPUS < webmaster@oxpus.de > (Karsten Ude) http://www.oxpus.de
## MOD Description:   If a user haves no auth to post a new topic or reply to a post this
##         mod will hide the buttons to do this.
##         A more friendly version before displaying the auth message.
## MOD Version:      1.1.1
##
## Installation Level:   Intermediate
## Installation Time:   5-8 Minutes
## Files To Edit:   4
##         viewforum.php
##         viewtopic.php
##         templates/subSilver/viewforum_body.tpl
##         templates/subSilver/viewtopic_body.tpl
##
## Included Files:   n/a
##############################################################
## For Security Purposes, Please Check: http://www.phpbb.com/mods/ for the
## latest version of this MOD. Downloading this MOD from other sites could cause malicious code
## to enter into your phpBB Forum. As such, phpBB will not offer support for MOD's not offered
## in our MOD-Database, located at: http://www.phpbb.com/mods/
##############################################################
## Author Notes:
##
##############################################################
## MOD History:
##
##   2005-01-21 - Version 1.1.1
##      - FIX little typo to enable the buttons for users
##
##   2004-12-09 - Version 1.1.0
##      - ADD hide quote button on posts, too.
##
##   2004-10-30 - Version 1.0.0
##      - First release
##
##############################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##############################################################

#
#-----[ OPEN ]------------------------------------------
#
viewforum.php

#
#-----[ FIND ]------------------------------------------
#
//
// Post URL generation for templating vars
//

#
#-----[ AFTER, ADD ]------------------------------------------
#
if ($is_auth['auth_post'] || $is_auth['auth_mod'])
{
   $temp_url = append_sid("posting.$phpEx?mode=newtopic&amp;" . POST_FORUM_URL . "=$forum_id");
   $u_post_new_topic = '<a href="'.$temp_url.'">';   
   $temp_image = ( $forum_row['forum_status'] == FORUM_LOCKED ) ? $images['post_locked'] : $images['post_new'];
   $u_post_new_topic_image = '<img src="'.$temp_image.'" border="0" />';
   $u_post_new_topic .= $u_post_new_topic_image . '</a>';
}
else
{
   $u_post_new_topic = ( $forum_row['forum_status'] == FORUM_LOCKED ) ? '<img src="'.$images['post_locked'].'" border="0" />' : '';
}

#
#-----[ FIND ]------------------------------------------
#
   'U_POST_NEW_TOPIC' => append_sid("posting.$phpEx?mode=newtopic&amp;" . POST_FORUM_URL . "=$forum_id"),

#
#-----[ REPLACE WITH ]------------------------------------------
#
   'U_POST_NEW_TOPIC' => $u_post_new_topic,

#
#-----[ FIND ]------------------------------------------
#
   'POST_IMG' => ( $forum_row['forum_status'] == FORUM_LOCKED ) ? $images['post_locked'] : $images['post_new'],

#
#-----[ REPLACE WITH ]------------------------------------------
#
//   'POST_IMG' => ( $forum_row['forum_status'] == FORUM_LOCKED ) ? $images['post_locked'] : $images['post_new'],

#
#-----[ OPEN ]------------------------------------------
#
viewtopic.php

#
#-----[ FIND ]------------------------------------------
#
$new_topic_url = append_sid("posting.$phpEx?mode=newtopic&amp;" . POST_FORUM_URL . "=$forum_id");

#
#-----[ IN-LINE FIND ]------------------------------------------
#
append_sid(

#
#-----[ IN-LINE BEFORE, ADD ]------------------------------------------
#
($is_auth['auth_post']) ? '<a href="'.

#
#-----[ IN_LINE FIND ]------------------------------------------
#
")

#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#
.'">' : ''

#
#-----[ FIND ]------------------------------------------
#
$reply_topic_url = append_sid("posting.$phpEx?mode=reply&amp;" . POST_TOPIC_URL . "=$topic_id");

#
#-----[ IN-LINE FIND ]------------------------------------------
#
append_sid(

#
#-----[ IN-LINE BEFORE, ADD ]------------------------------------------
#
($is_auth['auth_reply']) ? '<a href="'.

#
#-----[ IN_LINE FIND ]------------------------------------------
#
")

#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#
.'">' : ''

#
#-----[ FIND ]------------------------------------------
#
$reply_img = ( $forum_topic_data['forum_status'] == FORUM_LOCKED || $forum_topic_data['topic_status'] == TOPIC_LOCKED ) ? $images['reply_locked'] : $images['reply_new'];
$reply_alt = ( $forum_topic_data['forum_status'] == FORUM_LOCKED || $forum_topic_data['topic_status'] == TOPIC_LOCKED ) ? $lang['Topic_locked'] : $lang['Reply_to_topic'];
$post_img = ( $forum_topic_data['forum_status'] == FORUM_LOCKED ) ? $images['post_locked'] : $images['post_new'];
$post_alt = ( $forum_topic_data['forum_status'] == FORUM_LOCKED ) ? $lang['Forum_locked'] : $lang['Post_new_topic'];

#
#-----[ AFTER, ADD ]------------------------------------------
#
$new_topic_url .= ($is_auth['auth_post']) ? '<img src="'.$post_img.'" alt="'.$post_alt.'" border="0" /></a>' : '';
$reply_topic_url .= ($is_auth['auth_reply']) ? '<img src="'.$reply_img.'" alt="'.$reply_alt.'" border="0" /></a>' : '';

#
#-----[ FIND ]------------------------------------------
#
   'POST_IMG' => $post_img,

#
#-----[ REPLACE WITH ]------------------------------------------
#
//   'POST_IMG' => $post_img,

#
#-----[ FIND ]------------------------------------------
#
   'REPLY_IMG' => $reply_img,

#
#-----[ REPLACE WITH ]------------------------------------------
#
//   'REPLY_IMG' => $reply_img,

#
#-----[ FIND ]------------------------------------------
#
   $temp_url = append_sid("posting.$phpEx?mode=quote&amp;lpid=$last_post_id&amp;" . POST_POST_URL . "=" . $postrow[$i]['post_id']);
   $quote_img = '<a href="' . $temp_url . '"><img src="' . $images['icon_quote'] . '"  border="0" /></a>';
   $quote = '<a href="' . $temp_url . '">' . $lang['Reply_with_quote'] . '</a>';

#
#-----[ REPLACE WITH ]------------------------------------------
#
   if ($is_auth['auth_reply'])
   {
      $temp_url = append_sid("posting.$phpEx?mode=quote&amp;lpid=$last_post_id&amp;" . POST_POST_URL . "=" . $postrow[$i]['post_id']);
      $quote_img = '<a href="' . $temp_url . '"><img src="' . $images['icon_quote'] . '"  border="0" /></a>';
      $quote = '<a href="' . $temp_url . '">' . $lang['Reply_with_quote'] . '</a>';
   }
   else
   {
      $quote_img = '';
      $quote = '';
   }

#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/viewforum_body.tpl

#
#-----[ FIND ]------------------------------------------
#
<a href="{U_POST_NEW_TOPIC}"><img src="{POST_IMG}" border="0" /></a>

#
#-----[ REPLACE WITH ]------------------------------------------
#
{U_POST_NEW_TOPIC}

#
#-----[ FIND ]------------------------------------------
#
<a href="{U_POST_NEW_TOPIC}"><img src="{POST_IMG}" border="0" /></a>

#
#-----[ REPLACE WITH ]------------------------------------------
#
{U_POST_NEW_TOPIC}

#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/viewtopic_body.tpl

#
#-----[ FIND ]------------------------------------------
#
<a href="{U_POST_NEW_TOPIC}"><img src="{POST_IMG}" border="0" align="middle" /></a>

#
#-----[ REPLACE WITH ]------------------------------------------
#
{U_POST_NEW_TOPIC}

#
#-----[ FIND ]------------------------------------------
#
<a href="{U_POST_REPLY_TOPIC}"><img src="{REPLY_IMG}" border="0" align="middle" /></a>

#
#-----[ REPLACE WITH ]------------------------------------------
#
{U_POST_REPLY_TOPIC}

#
#-----[ FIND ]------------------------------------------
#
<a href="{U_POST_NEW_TOPIC}"><img src="{POST_IMG}" border="0" align="middle" /></a>

#
#-----[ REPLACE WITH ]------------------------------------------
#
{U_POST_NEW_TOPIC}

#
#-----[ FIND ]------------------------------------------
#
<a href="{U_POST_REPLY_TOPIC}"><img src="{REPLY_IMG}" border="0" align="middle" /></a>

#
#-----[ REPLACE WITH ]------------------------------------------
#
{U_POST_REPLY_TOPIC}


#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM


_________________
SilverStone SST CS01 | Corsair SF600 600W SFX | ASRock X99E-ITX/ac | Intel Xeon E5-2683 v4 (16 Cores / 32 Threads) & Noctua NH-U9DX i4 | Kingston HyperX Savage 32 GB DDR4 2400 MHz | PNY NVIDIA Quadro K1200 DP 4 GB DDR5 | Intel SSD 750 1.2 TB NVMe & Intel SSD 730 240 GB SATA & Seagate BackUp Plus Portable 12 TB USB | 31.5" 4K LCD EIZO FlexScan EV3237 & 2 x 24" LCD EIZO FlexScan EV2451 | Ergotron LX Wall Mount Keyboard Arm | Logitech Craft | Logitech Wireless G700s | Harman Kardon Nova | Microsoft Windows 7 Ultimate | APC Back-UPS ES 700 | Lenovo ThinkPad X250 - Intel Core i7 5600U, 8 GB DDR3 1600 MHz, Intel HD Graphics 5500, SanDisk SSD 512 GB, 12.5 FHD LED IPS, WWAN 3G 4G LTE, Microsoft Windows 7 Ultimate | Nintendo Classic Mini | BlackBerry Passport 96 GB
 [ Príspevok: 1 ] 


Hide Post Buttons



Podobné témy

 Témy  Odpovede  Zobrazenia  Posledný príspevok 
V tomto fóre nie sú ďalšie neprečítané témy.

post funkcia a post pole

v PHP, ASP

15

346

28.05.2014 13:21

Kamahl

V tomto fóre nie sú ďalšie neprečítané témy.

Faceboom vlastny buttons

v Sociálne siete

1

82

12.05.2014 12:01

haffen

V tomto fóre nie sú ďalšie neprečítané témy.

agama web buttons PROBLEM

v Webdesign

1

562

04.05.2007 14:53

Tominator

V tomto fóre nie sú ďalšie neprečítané témy.

Program Quick Launch Buttons prestal pracovat na HP 6730s

v Notebooky a netbooky

0

1029

24.04.2009 11:44

maly1

V tomto fóre nie sú ďalšie neprečítané témy.

Hide IP

v Bezpečnosť a firewally

3

806

08.06.2009 11:36

citizen

V tomto fóre nie sú ďalšie neprečítané témy.

Hide IP

v Sieťové a internetové programy

9

480

18.08.2010 14:10

riki137

V tomto fóre nie sú ďalšie neprečítané témy.

jQuery hide

v JavaScript, VBScript, Ajax

11

549

08.11.2009 15:05

lama2d

V tomto fóre nie sú ďalšie neprečítané témy.

easy hide ip

v Ostatné programy

2

160

31.08.2017 13:32

xman™

V tomto fóre nie sú ďalšie neprečítané témy.

Hide IP Platinum

v Sieťové a internetové programy

3

666

22.10.2013 10:49

Lulu_Zulu

V tomto fóre nie sú ďalšie neprečítané témy.

Virtual cd hide

v Ostatné programy

0

690

21.04.2007 23:40

Hunter551

V tomto fóre nie sú ďalšie neprečítané témy.

Show/Hide div a SEO

v Internetový marketing, SEO, reklama

0

321

10.08.2011 22:31

jostoga

V tomto fóre nie sú ďalšie neprečítané témy.

select onchange show hide divs

v JavaScript, VBScript, Ajax

2

288

03.08.2010 21:01

Ďuri

V tomto fóre nie sú ďalšie neprečítané témy.

show/hide na vsetky polozky vo forme

v JavaScript, VBScript, Ajax

0

198

09.05.2010 18:12

metalface

V tomto fóre nie sú ďalšie neprečítané témy.

Potreba open/hide casti textu pod odkaz

v JavaScript, VBScript, Ajax

4

464

30.09.2008 21:21

salamoon

V tomto fóre nie sú ďalšie neprečítané témy.

Nieco ako show/hide pre jeden paragraf

v JavaScript, VBScript, Ajax

1

250

18.11.2010 19:30

shaggy

V tomto fóre nie sú ďalšie neprečítané témy.

HIDE FOLDER a ine programy na skrytie zloziek

v Ostatné programy

13

621

24.07.2011 0:48

OmeGa



© 2005 - 2017 PCforum, edited by JanoF