vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Reason for closing thread (https://vborg.vbsupport.ru/showthread.php?t=40190)

Xenon 07-16-2002 05:41 PM

Then it should look as seen on the screenshots.
It works as it should here, and seems no other has the problem you have, so i think you have made a little mistake in your templates

Schorsch 07-16-2002 09:47 PM

something in your installation.txt was wrong Xenon...

I changed the following in SHOWTHREAD Template:

Code:

<br>
$thread[closereason]
<br>

into:

Code:

<br>
$closereason
<br>

and now it works great :)

cu
Schorsch

Xenon 07-17-2002 08:51 AM

????

are you sure your showthread.php has this lines in it?
PHP Code:

if ($thread[open]) { 
  
$replyclose="{replyimage}"
  
$thread[closereason]=""
} else { 
  
$replyclose="{closedthreadimage}"
  if (
trim($thread[closereason])) { 
  
$thread[closereason]=bbcodeparse2($thread[closereason],0,1,1,1); 
  eval(
"\$thread[closereason] = \"".gettemplate("showthread_closereason")."\";"); 
  } else { 
    
$thread[closereason] = ""
  } 


because if you don't have this lines exactly like i posted here, you don't have installed the latest version, and then it's logical that you have to use other variables (because in the old version the variable was called $closereason ;))

Boofo 07-17-2002 09:10 AM

Here's the code you re-did for me because of the hack I have installed. Will this still work with your changes? This doesn't look the same in some areas as the new code. Just wanted to make sure after your last message. :)

PHP Code:

if ($thread[open]) {
  
$closereason="";
  eval(
"\$replyopenclosed = \"".gettemplate("showthread_replyopen")."\";");
} else {
  
$thread[closereason]=bbcodeparse2($thread[closereason],0,1,1,1);
  eval(
"\$closereason = \"".gettemplate("showthread_closereason")."\";");
  if (
ismoderator($thread[forumid],'canopenclose')) {
    eval(
"\$replyopenclosed = \"".gettemplate("showthread_replyclosedmod")."\";");
  } else {
    eval(
"\$replyopenclosed = \"".gettemplate("showthread_replyclosed")."\";");
   }



Xenon 07-17-2002 10:04 AM

yes it'll work.

the new code doesn't have strong codechanges, just a variable name has changed:
just replace all $closereason with $threadinfo[closereason] in this part of your code and in showthread template and you have the actualst version ;)

Boofo 07-17-2002 11:36 AM

I think you measn to replace it with "$thread[closereason]" not "threadinfo[closereason]", right? :)

Also, I am really confused here. In the third line, you have $closereason but in lines 7 and 8 you have $thread[closereason]. Shouldn't that second line be $thread[closereason], also? Or am I missing the point again? :) I'm just going by what you told me to replace in that last message.

PHP Code:

if ($thread[open]) { 
  
$replyclose="https://vborg.vbsupport.ru/images/reply.gif"
  
$closereason=""
} else { 
  
$replyclose="https://vborg.vbsupport.ru/images/threadclosed.gif"
  if (
trim($thread[closereason])) { 
  
$thread[closereason]=bbcodeparse2($thread[closereason],0,1,1,1); 
  eval(
"\$thread[closereason] = \"".gettemplate("showthread_closereason")."\";"); 
  } else { 
    
$thread[closereason] = ""
  } 



Quote:

Originally posted by Xenon
yes it'll work.

the new code doesn't have strong codechanges, just a variable name has changed:
just replace all $closereason with $threadinfo[closereason] in this part of your code and in showthread template and you have the actualst version ;)


Xenon 07-17-2002 11:13 PM

yes, i meant $thread[closereason], sorry seems to be a bit confused these days ;)

hmm i don't have $closereason in my file any more, you are correct it should also be $thread[closereason].
but it is here at my last file version ;)

Boofo 07-18-2002 12:31 AM

You might want to check that file in post #4 again then. It still has the following in it (on line 3 of the replace part and a couple of other spots in the file). (And I did clean my cache :))

PHP Code:

Step 2Edit Showthread.php   (1 Modification)
----------------------------------------------
Find:
if (
$thread[open]) { 
  
$replyclose="{replyimage}"
} else { 
  
$replyclose="{closedthreadimage}"



Replace with
if (
$thread[open]) { 
  
$replyclose="{replyimage}"
  
$closereason=""
} else { 
  
$replyclose="{closedthreadimage}"
  if (
trim($thread[closereason])) { 
  
$thread[closereason]=bbcodeparse2($thread[closereason],0,1,1,1); 
  eval(
"\$thread[closereason] = \"".gettemplate("showthread_closereason")."\";"); 
  } else { 
    
$thread[closereason] = ""
  } 


Quote:

Originally posted by Xenon
yes, i meant $thread[closereason], sorry seems to be a bit confused these days ;)

hmm i don't have $closereason in my file any more, you are correct it should also be $thread[closereason].
but it is here at my last file version ;)


TaP 07-18-2002 02:34 AM

i got every thing working right but i just wana know how to include date and time in message

PsYc 07-20-2002 10:27 AM

after re.open a closed thread the close reason still appeared at the top of the thread without the box around


problem fixed thanks Xenon :)

Xenon 07-20-2002 11:40 AM

have fixed the problem per icq :)

@all: be sure you have installed the newest version before posting small problems
if you have just one $closereason in your showthread.php its an old version and PsYc's bug can occur
if you have just $thread[closereason] in your showthread.php then it's the newest one ;)

brauner 08-03-2002 11:09 PM

Hallo
Beim öffnen des Threads verschwindet zwar der Rahmen aber nicht der eingegebene Text.

Wo liegt der Fehler?

Gruß
brauner

Xenon 08-03-2002 11:27 PM

sh mein obiges posting, in deinen templates darf kein $closereason mehr drinnen sein, nur noch ein $thread[closereason]

brauner 08-03-2002 11:57 PM

Meinst Du in dieser Zeile hier?
<textarea name="reason" rows="6" cols="45" wrap="virtual" tabindex="2">$threadinfo[closereason]</textarea>

Woanders kann ich nichts mehr finden.

<<<voll hilflos ist>>>

PS: Englisch klappt bei mir fast nur mit einem ?bersetzer daher habe ich obiges nicht ganz verstanden,sorry.

Hier mal die ?bersetzung:
PHP Code:

 @all:  seien Sie sicherdaSie die neueste Version vor bekanntgebenden kleinen Problemen angebracht habenwenn Sie gerade ein in $$closereason Ihrem seinem showthread.php eine alte Version haben und Wanze PsYcs auftreten kannwenn Sie gerade ] $$thread[closereason in Ihrem showthread.php habendanndas es das neueste ist 

:knockedout: :rolleyes:

Xenon 08-04-2002 12:03 AM

in deiner showthread.php muss das sein:
PHP Code:

 if (trim($thread[closereason])) { 
  
$thread[closereason]=bbcodeparse2($thread[closereason],0,1,1,1); 
  eval(
"\$thread[closereason] = \"".gettemplate("showthread_closereason")."\";"); 
  } else { 
    
$thread[closereason] = ""
  } 

das template showthread_closereason
muss $thread[closereason] enthalten

und das template showthread muss ebenfalls $thread[closereason] enthalten, und kein $closereason

brauner 08-04-2002 12:15 AM

Du wirst es nicht glauben aber ich habe nochmal nachgeschaut und es ist alles so wie du sagtest.

Was mache ich denn nun?

h???lfe

brauner 08-04-2002 12:43 AM

http://www.crazypalace.info/upload/test Kopie2.gif

Falls mir einer nicht glaubt *fg*
Oben der geschlossene Thread ==>alles in Ordnung
Unten der ge?ffnete Thread ==> Nicht so toll :-((

Xenon 08-04-2002 09:24 AM

PHP Code:

if ($thread[open]) { 
  
$replyclose="{replyimage}"
  
$thread[closereason]=""
} else { 
  
$replyclose="{closedthreadimage}"
  if (
trim($thread[closereason])) { 
  
$thread[closereason]=bbcodeparse2($thread[closereason],0,1,1,1); 
  eval(
"\$thread[closereason] = \"".gettemplate("showthread_closereason")."\";"); 
  } else { 
    
$thread[closereason] = ""
  } 


also wenn du genau diesen code da in deiner showthread.php hast, dann w?re es unm?glich, dass du das ergebnis hast das du hast ^^

beachte genau die obere if-abfrage: Wenn thread offen dann $thread[closereason]=""
....
wenn da ein $closereason="" oder garnix dergelichen steht isses falsch ;)

brauner 08-04-2002 10:01 AM

Das habe ich zweimal in meiner postings.php
PHP Code:

if ($s!=$session['dbsessionhash']) { 

K?nnte es daran liegen? Und welchen muss ich gegen
PHP Code:

if ($s!=$session['dbsessionhash'] && $reasonentered!=1) { 

tauschen?

Xenon 08-04-2002 10:05 AM

du musst nur die zweile in der openclose section austauschen.

und nein daran liegts nicht, es kann nur in der showthread.php oder zugehörigen templates liegen

brauner 08-04-2002 10:25 AM

Habe einfach alle nochmal gemacht und jetzt geht es <<<hüppel_im_Kreis_herum>>>

Was anderes.
Kann man das so machen, das wenn man keinen Grund angibt, ein vordefinierter Text da steht?

Xenon 08-04-2002 10:32 AM

ja kann man

in der postings.php
finde das:
PHP Code:

if($threadinfo[open]==0) {
    
$closereason=" closereason='".addslashes($reason)."', "
  } else {
    
$closereason="";
  } 

und ersetze es zb mit dem:

PHP Code:

if($threadinfo[open]==0) {
     if (
trim($reason)!=""$closereason=" closereason='".addslashes($reason)."', "
     else 
$closereason=" closereason='Wurde wegen Spam von ".$bbuserinfo[username]." geschlossen!', ";
  } else {
    
$closereason="";
  } 

oder eben ?hnliches

ach ja stell solche fragen zu erweiterungen besser in englisch, damit andre auch was davon haben ;)

brauner 08-04-2002 10:34 AM

DAnke Dir.
In Englisch?!
Dann versteht es gar keiner mehr ;-))

brauner 08-04-2002 11:28 AM

Quote:

und ersetze es zb mit dem:
PHP:

PHP Code:

if($threadinfo[open]==0) {
     if (
trim($closereason)==""$closereason=" closereason='".addslashes($reason)."', "
     else 
$closereason="Wurde wegen Spam von ".$bbuserinfo[username]." geschlossen!";
  } else {
    
$closereason="";
  } 

oder eben ?hnliches
No then nothing at all does not come

[Nein dann kommt gar nichts]

Xenon 08-04-2002 11:35 AM

yeah sorry was my fault, i have edited my post above, now it should work ;)

brauner 08-04-2002 11:48 AM

Sorry, no goes not yet

[Nein geht immer noch nicht]

Xenon 08-04-2002 11:56 AM

hab zu wenig geschlafen ^^

jetzt sollts gehen (zumindest auf meinem testserver gings nu)

brauner 08-04-2002 12:04 PM

Öhhhhhhm, leider nein.
Wenn ich jetzt was reinschreibe, erscheint der vordefinierte Text.
Lasse ich das Feld leer kommt nichts

Ist mir jetzt echt schon Peinlich.

Xenon 08-04-2002 12:08 PM

ersetze das == mit einem !=, hab ich in meinem post schon gemacht, daran lag ja der fehler

brauner 08-04-2002 12:16 PM

Super das war es.
Sagst mir nur nocg wie ich die Uhrzeit wann geschlossen wurde da rein bringe und ich lade Dich zum Kaffee ein

<<<<mal_doll_knuddelt>>>

Xenon 08-04-2002 12:21 PM

ersetze das $bbuserinfo[username] mit dem da:
$bbuserinfo[username]." um ".vbdate($timeformat,time())

das sollte gehn ;)

ich nehme dann einmal schwarzen kaffe ^^

brauner 08-04-2002 12:40 PM

So Kaffee ist fertig
Komm schnell her :-)

Noch ne Frage erlaubt?

Jetzt steht die Zeit aber nur drinne wenn ich keinen Grund angebe.

Kann das geändert werden, das die Zeit und wer geschlossen hat, auch drinne steht wenn ich selber Text eingebe?

Ach ja und anstatt die Uhrzeit leiber das Datum

<<<<mhhhhhhh, zum Kaffee gibt es Maulwurfkuchen von der Tochter>>>

Echt nett von Dir das mit dem Support

Boofo 08-04-2002 12:49 PM

Come on, guys, can we do it in English? :) Maybe we can learn something from waht is going on. :)

Xenon 08-04-2002 12:55 PM

Hehe, sorry boofo, most of the last text was off topic ;)

before
he asked about a standart reason if you don't enter one...

@brauner: naja das uhrzeit und wer auch dasteht wenn man was eingibt wollte ich mal machen, bin aber noch nicht dazugekommen... (kannste aber immer in den threadeigenschaften (edit thread) nachsehn

yes, just change $timeformat to $dateformat." ".$timeformat and you've date and time closed ;)

Boofo 08-04-2002 01:02 PM

No problem on the non-English. I tried to folllow it, but got lost a long way back in the converstaion. I was hopng you guys would switch to English sooner or later. :)

How do you add the date and time closed? I must have missed that. :)

Xenon 08-04-2002 01:05 PM

Quote:

Originally posted by Xenon
ersetze das $bbuserinfo[username] mit dem da:
$bbuserinfo[username]." at ".vbdate($dateformat." ".$timeformat,time())

das sollte gehn ;)

ich nehme dann einmal schwarzen kaffe ^^

it was this post ;)

Boofo 08-04-2002 01:11 PM

Ok, I saw that, but I still don't understand where it goes. :)

Xenon 08-04-2002 01:18 PM

in english:

replace $bbuserinfo[username] with
Code:

$bbuserinfo[username]." at ".vbdate($dateformat." ".$timeformat,time())

brauner 08-04-2002 01:37 PM

Can one limit all this to certain forums?

Boofo 08-04-2002 01:39 PM

No, I understood that part of it. I just don't see $bbuserinfo[username] anywhere in your closed reason code. I have "By: $thread[whoclosed]" from Lesane's addon.

Quote:

Originally posted by Xenon
in english:

replace $bbuserinfo[username] with
Code:

$bbuserinfo[username]." at ".vbdate($dateformat." ".$timeformat,time())



All times are GMT. The time now is 04:18 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01432 seconds
  • Memory Usage 1,875KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (4)bbcode_code_printable
  • (12)bbcode_php_printable
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete