Coś popsułem !!! Tylko co...

Jeśli masz problem z nie autoryzowaną modyfikacją, nie możesz jej zainstalować lub występują błędy po jej instalacji to pisz w tym dziale.
DarCo
Posty: 9
Rejestracja: 20 czerwca 2005, 11:02
Lokalizacja: Poznań
Kontakt:

Coś popsułem !!! Tylko co...

Post autor: DarCo » 20 czerwca 2005, 18:37

Ech, chciałem zrobić complete_quick_reply i coś se popsułem. Robiłem napewno wszystko tak jak pisze tu

Kod: Zaznacz cały

#################################################################
## Mod Title: Complete Quick Reply Mod
## Mod Author: Logeen [www.kurshtml.boo.pl]
## Mod Version: 1.4
## Mod Based on: Advanced Quick Reply Mod [RustyDragon <dev@RustyDragon.com>  http://www.phpbbhacks.com]
## Mod Based on description: This will allow users to use quick reply form 
##		which is placed below every topic.
##		It will only display when user has the Reply access
##		User have a option to quote the last message.
##      A list of 24 smilies is shown below input area.
##		Users can paste names of users just by clicking on it.
##      Also they can select any text on a page and quote it to the input area.
##
##      Last 3 options were absent in Quick Reply Mod with Quote on which
##      this mod is based.
##		Additional feature - uses of template for quick reply form.
##		So you can change a look of the mod to whatever you want.
## Mod description: Additional options
##	- Quote selected button works also in browsers other than Internet Explorer
##	- Quoting selected text with author's name
##	- Quote selected button placed in every post
##	- BBCode buttons in quick reply
##	- Every user can hide Quick Reply panel
##
## Installation Level: Easy
## Installation Time: 5-10 Minutes
##
## Files To Edit: 6
##	language/[your_language]/lang_main.php
##	templates/[your_template]/[your_template].cfg
##	templates/[your_template]/viewtopic_body.tpl
##	viewtopic.php
##	templates/[your_template]/profile_add_body.tpl
##	includes/usecp_register.php
##
## Files To Add: 3
##	templates/[your_template]/images/[your_language]/icon_quick_quote.gif
##	quick_reply.tpl
##	quick_reply.php
##
#################################################################
##
## Author (RustyDragon) Note:
##  If you want to have different number of smilies displayed find a line
##  $max_smilies = 30;
##  in a file quick_reply.php and replace 30 with whatever you want. Setting this variable to zero 
##  will disable  smilies row.
##
##  This MOD is based on Quick Reply Mod with Quote from Smartor <smartor_xp@hotmail.com>
##  
##  This mod will increase the size of your topic page by approx 9kb (Logeen's modification: 17kb) 
##  and execute one additional (but simple) SQL query for every page load.
##
##	The Quick-Quote Feature was an idea from Nexialys (www.bebeabord.org)
##
##	You should change all your templates and language pack
##
#################################################################
##
##  Complete Quick Reply Mod is Copyright &copy; Logeen [www.kurshtml.boo.pl], 2004
##
##  Advanced Quick Reply Mod is Copyright &copy; RustyDragon, 2002
##
##	Quick Reply Mod with Quote is Copyright &copy; Smartor, 2002
##	updated to support phpbb 2.0.4 by danb00
##
##	Quick Reply Mod with Quote is Copyright &copy; Smartor, 2002
##	updated to support phpbb 2.0.4 by danb00
##   
##	(Any changes to this MOD must retain these Copyright Notices)
##
#################################################################


# 
#-----[ SQL ]-------------------------------- 
# 

ALTER TABLE `phpbb_users` ADD `hide_quick_reply` TINYINT( 1 ) DEFAULT '0' NOT NULL;

#
#-----[ COPY ]------------------------------------------
#

copy icon_quick_quote.gif to templates/[your_template]/images/[your_language]
copy quick_reply.tpl to templates/[your_template]
copy quick_reply.php to /

#
#-----[ OPEN ]------------------------------------------
#

lang/lang_english/lang_main.php

#
#-----[ FIND ]------------------------------------------
#
//
// That's all Folks!

#
#-----[ BEFORE, ADD ]------------------------------------
#

// Complete Quick Reply Mod
$lang['Quick_Reply'] = 'Quick Reply';
$lang['Hide_quick_reply'] = 'Hide Quick Reply panel';
$lang['Hide_panel_in_profile'] = 'You can hide this panel in your profile';
$lang['Insert_author_quote'] = 'Insert author\'s name to quick quote';
$lang['Quick_quote'] = 'Quote last message';
$lang['Quote_selected'] = 'Quote selected';
$lang['QuoteSelelectedEmpty'] = 'Select a text anywhere on a page and try again';

#
#-----[ OPEN ]------------------------------------------
#

lang/lang_polish/lang_main.php

#
#-----[ FIND ]------------------------------------------
#
//
// That's all Folks!

#
#-----[ BEFORE, ADD ]------------------------------------
#

// Complete Quick Reply Mod
$lang['Quick_Reply'] = 'Szybka odpowiedź';
$lang['Hide_quick_reply'] = 'Ukryj panel szybkiej odpowiedzi';
$lang['Hide_panel_in_profile'] = 'Możesz ukryć ten panel w swoim profilu';
$lang['Insert_author_quote'] = 'Wstaw autora do szybkiej odpowiedzi';
$lang['Quick_quote'] = 'Cytuj ostatni post';
$lang['Quote_selected'] = 'Zacytuj zaznaczone';
$lang['QuoteSelelectedEmpty'] = 'Zaznacz jakiś tekst na stronie i spróbuj jeszcze raz';

#
#-----[ OPEN ]------------------------------------------
#

templates/[your_template]/[your_template].cfg

#
#-----[ FIND ]------------------------------------------
#

$images['icon_quote'] = "$current_template_images/{LANG}/icon_quote.gif";

#
#-----[ BEFORE, ADD ]------------------------------------
#

$images['icon_quick_quote'] = "$current_template_images/{LANG}/icon_quick_quote.gif";

#
#-----[ OPEN ]------------------------------------------
#

templates/[your_template]/viewtopic_body.tpl

#
#-----[ FIND ]------------------------------------------
#

{postrow.POSTER_NAME}

#
#-----[ REPLACE WITH ]------------------------------------
#

<span style="cursor: pointer" onclick="if (document.post && document.post.message) emoticon("[b]{postrow.POSTER_NAME}[/b]")" title="{postrow.L_INSERT_AUTHOR_QUOTE}">{postrow.POSTER_NAME}</span>

#
#-----[ FIND ]------------------------------------------
#

{postrow.QUOTE_IMG}

#
#-----[ BEFORE, ADD ]------------------------------------
#

{postrow.QUICK_QUOTE_IMG} 

#
#-----[ FIND ]------------------------------------------
#

><span class="postbody">{postrow.MESSAGE}

#
#-----[ BEFORE, ADD ]------------------------------------
#

 onmouseup="if (document.getSelection && document.getSelection() || document.selection && document.selection.createRange && document.selection.createRange().text) quoteAuthor = "{postrow.POSTER_NAME}""

#
#-----[ FIND ]------------------------------------------
#

<table width="100%" cellspacing="2" border="0" align="center">
  <tr> 
	<td width="40%" valign="top" nowrap="nowrap" align="left"><span class="gensmall">{S_WATCH_TOPIC}</span><br />
	  &nbsp;<br />
	  {S_TOPIC_ADMIN}</td>
	<td align="right" valign="top" nowrap="nowrap">{JUMPBOX}<span class="gensmall">{S_AUTH_LIST}</span></td>
  </tr>
</table>

#
#-----[ BEFORE, ADD ]------------------------------------
#


{QUICKREPLY_OUTPUT}


#
#-----[ OPEN ]------------------------------------------
#

viewtopic.php

#
#-----[ FIND ]------------------------------------------
#

	$quote_img = 

#
#-----[ BEFORE, ADD ]------------------------------------
#

	$quick_quote_img = '<a href="javascript:void(null)" onclick="if (document.post && document.post.message) quoteSelection(); return false" onmouseover="if (document.getSelection) selectedText = document.getSelection()"><img src="' . $images['icon_quick_quote'] . '" alt="' . $lang['Quote_selected'] . '" title="' . $lang['Quote_selected'] . '" border="0" /></a>';

#
#-----[ FIND ]------------------------------------------
#

		'QUOTE_IMG' => $quote_img,


#
#-----[ BEFORE, ADD ]------------------------------------
#

		'L_INSERT_AUTHOR_QUOTE' => ( $userdata['user_id'] == ANONYMOUS || !$userdata['hide_quick_reply'] ) ? $lang['Insert_author_quote'] : '',
		'QUICK_QUOTE_IMG' => ( $userdata['user_id'] == ANONYMOUS || !$userdata['hide_quick_reply'] ) ? $quick_quote_img : '',

#
#-----[ FIND ]------------------------------------------
#

$template->pparse('body');

include($phpbb_root_path . 'includes/page_tail.'.$phpEx);

#
#-----[ BEFORE, ADD ]------------------------------------
#

//
// Quick Reply
//
if ($userdata['user_id'] == ANONYMOUS || !$userdata['hide_quick_reply']) include($phpbb_root_path . 'quick_reply.'.$phpEx);

#
#-----[ OPEN ]------------------------------------------
#

templates/[your_template]/profile_add_body.tpl

#
#-----[ FIND ]------------------------------------------
#

	<tr> 
	  <td class="row1"><span class="gen">{L_POPUP_ON_PRIVMSG}:</span><br /><span class="gensmall">{L_POPUP_ON_PRIVMSG_EXPLAIN}</span></td>
	  <td class="row2"> 
		<input type="radio" name="popup_pm" value="1" {POPUP_PM_YES} />
		<span class="gen">{L_YES}</span>&nbsp;&nbsp; 
		<input type="radio" name="popup_pm" value="0" {POPUP_PM_NO} />
		<span class="gen">{L_NO}</span></td>
	</tr>

#
#-----[ AFTER, ADD ]------------------------------------
#

	<tr> 
	  <td class="row1"><span class="gen">{L_HIDE_QUICK_REPLY}:</span></td>
	  <td class="row2"> 
		<input type="radio" name="hide_quick_reply" value="1" {HIDE_QUICK_REPLY_YES} />
		<span class="gen">{L_YES}</span>&nbsp;&nbsp; 
		<input type="radio" name="hide_quick_reply" value="0" {HIDE_QUICK_REPLY_NO} />
		<span class="gen">{L_NO}</span></td>
	</tr>

#
#-----[ OPEN ]------------------------------------------
#

includes/usecp_register.php

#
#-----[ FIND ]------------------------------------------
#

	$popup_pm = ( isset($HTTP_POST_VARS['popup_pm']) ) ? ( ($HTTP_POST_VARS['popup_pm']) ? TRUE : 0 ) : TRUE;

#
#-----[ AFTER, ADD ]------------------------------------
#

	$hide_quick_reply = ( isset($HTTP_POST_VARS['hide_quick_reply']) ) ? ( ($HTTP_POST_VARS['hide_quick_reply']) ? TRUE : 0 ) : 0;

#
#-----[ FIND ]------------------------------------------
#

$sql = "UPDATE " . USERS_TABLE . "
				SET " . $username_sql . $passwd_sql . "user_email = '" . str_replace("\'", "''", $email) ."', user_icq = '" . str_replace("\'", "''", $icq) . "', user_website = '" . str_replace("\'", "''", $website) . "', user_occ = '" . str_replace("\'", "''", $occupation) . "', user_from = '" . str_replace("\'", "''", $location) . "', user_interests = '" . str_replace("\'", "''", $interests) . "', user_sig = '" . str_replace("\'", "''", $signature) . "', user_sig_bbcode_uid = '$signature_bbcode_uid', user_viewemail = $viewemail, user_aim = '" . str_replace("\'", "''", str_replace(' ', '+', $aim)) . "', user_tlen = '" . str_replace("\'", "''", $tlen) . "', user_gg = '" . str_replace("\'", "''", $gg) . "', user_gg_mod = $gg_mod, user_yim = '" . str_replace("\'", "''", $yim) . "', user_msnm = '" . str_replace("\'", "''", $msn) . "', user_attachsig = $attachsig, user_allowsmile = $allowsmilies, user_allowhtml = $allowhtml, user_allowbbcode = $allowbbcode, user_allow_viewonline = $allowviewonline, user_notify = $notifyreply, user_notify_pm = $notifypm, user_popup_pm = $popup_pm, hide_quick_reply = $hide_quick_reply, user_timezone = $user_timezone, user_dateformat = '" . str_replace("\'", "''", $user_dateformat) . "', user_lang = '" . str_replace("\'", "''", $user_lang) . "', user_style = $user_style, user_active = $user_active, user_actkey = '" . str_replace("\'", "''", $user_actkey) . "'" . $avatar_sql . ", user_gender = '$gender'
				WHERE user_id = $user_id";

#
#-----[ IN-LINE FIND ]------------------------------------------
#

 user_popup_pm = $popup_pm,

#
#-----[ AFTER, ADD ]------------------------------------
#

 hide_quick_reply = $hide_quick_reply,

#
#-----[ FIND ]------------------------------------------
#

	$popup_pm = $userdata['user_popup_pm'];

#
#-----[ AFTER, ADD ]------------------------------------
#

	$hide_quick_reply = $userdata['hide_quick_reply'];

#
#-----[ FIND ]------------------------------------------
#

		'POPUP_PM_YES' => ( $popup_pm ) ? 'checked="checked"' : '',
		'POPUP_PM_NO' => ( !$popup_pm ) ? 'checked="checked"' : '',

#
#-----[ AFTER, ADD ]------------------------------------
#

		'L_HIDE_QUICK_REPLY' => $lang['Hide_quick_reply'],
		'HIDE_QUICK_REPLY_YES' => ( $hide_quick_reply ) ? 'checked="checked"' : '',
		'HIDE_QUICK_REPLY_NO' => ( !$hide_quick_reply ) ? 'checked="checked"' : '',



#
#-----[ SAVE/CLOSE ALL FILES ]--------------------------
#
#EoM
A objawy sami zobaczcie tutaj ->

Kod: Zaznacz cały

http://members.lycos.co.uk/darcoforum2005/
A przedtem język był polski. A jak chce go spowrotem zmienić na polski to:

Kod: Zaznacz cały

Template->make_filename(): Error - file ./templates/subSilver/message_body.tpl does not exist 
Najwyżej zainstaluje je jeszcze raz. :roll: Bo kopii raczej niezrobiłem. :roll:

Awatar użytkownika
Negatyf
Posty: 50
Rejestracja: 14 maja 2005, 15:31
Kontakt:

Post autor: Negatyf » 21 czerwca 2005, 15:10

Nie wklejaj całej instrukcji na forum :wink:
Nie masz pliku message_body.tpl

Kod: Zaznacz cały

./templates/subSilver/message_body.tpl does not exist

DarCo
Posty: 9
Rejestracja: 20 czerwca 2005, 11:02
Lokalizacja: Poznań
Kontakt:

Post autor: DarCo » 21 czerwca 2005, 17:37

Nie wklejaj całej instrukcji na forum
Poprostu lubie jak wszystko jest jasne. :D
Nie masz pliku message_body.tpl
Faktycznie niebyło go, co też mogło się z nim stać. :D Ikony już są widoczne. Ale jeszcze musze język poprawić bo polski jest nadal "popsuty". :P

Zablokowany

Wróć do „Pomoc”