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 08-04-2002 01:53 PM

@boofo: This post is meant ;)

@brauner:
Code:

else $closereason=" closereason='Wurde wegen Spam von ".$bbuserinfo[username]." geschlossen!', ";
replace with:
PHP Code:

else {
        if(
$thread[forumid]==xx$closereason=" closereason='Wurde wegen Spam von ".$bbuserinfo[username]." geschlossen!', ";
       elseif(
$thread[forumid]==y$closereason=" closereason='Wurde wegen Beleidigungen von ".$bbuserinfo[username]." geschlossen!', ";
       else 
$closereason=" closereason='', ";



brauner 08-04-2002 04:54 PM

Der vordefinierte Text funzt nun einwandfrei mit Name und Zeit etc.
Allerdings geht das nicht mit der Zeit Datum und Username wenn ich den Standarttext nicht benutzen m?chte.

In Englisch:
PHP Code:

The pre-defined text funzt now perfectly with name and time etc..  However with the time the date and username does not go not using if I the text of kind of condition would like


ZiRu$ 08-20-2002 03:55 PM

dope i shall install this

Boofo 08-22-2002 03:28 AM

Can anyone please tell me why I am getting this all of a sudden on a closed thread?

Quote:

Reason for Thread being Closed by (Boofo on Aug 21, 2002 pm31 11:21 pm):

eXtremeTim 08-22-2002 03:39 AM

Wow nice hack you guys. :)

I will proble install tommorrow.

Once again VERY NICE HACK.

Keep up the good work.

Donkeyballz 08-22-2002 07:51 AM

Nice hack, very usefull :)

Xenon 08-22-2002 08:04 PM

Boofo: seems you have corupted the timeformat part of the date/time addition of the hack ;)

Boofo 08-22-2002 08:08 PM

But I didn't chnage anyting in it. Any idea how to fix it? :)

Quote:

Originally posted by Xenon
Boofo: seems you have corupted the timeformat part of the date/time addition of the hack ;)

Xenon 08-22-2002 08:19 PM

if you haven't changed something then i don't have an idea ;)

Boofo 08-23-2002 10:13 AM

Well, Xenon, it kept bugging me so I kept at it until I found out (with some help) what the time problem was I was having. It turns out that it was my fault after all. You were right. The code you gave me for the time had this in it:

Code:

".vbdate($dateformat." ".$timeformat,time())."', ";
and I added an "at" to it, where, apparently, I shouldn't have. Like this:

Code:

".vbdate($dateformat." at ".$timeformat,time())."', ";
and the code I needed to change it to was this:

Code:

".vbdate($dateformat,time())." at ".vbdate($timeformat,time())."', ";
I guess I learned a little something from this after all. :)

Shepski 08-23-2002 10:28 AM

Ok, now I am lost with this mixture of english and german. I saw per post the porblem about closing and then opening a thread still displays the closed reason but without the box but I couldnt work where the fix was.

Can someone help me to what I need to change to sort this out :) (in english would be cool ;))

Xenon 08-23-2002 10:34 AM

completly deinstall the hack and install the really newest version there are no problems in it...

@boofo: :) yeah timeformat-string is no real outputstring ;)

Shepski 08-23-2002 10:38 AM

Quote:

Originally posted by Xenon
completly deinstall the hack and install the really newest version there are no problems in it...
If that was meant for me then I installed the version downloaded from https://vborg.vbsupport.ru/attachmen...&postid=264907

is that not the latest one?

Boofo 08-23-2002 10:41 AM

So when I want to put an "at" between the date and the time, I need to use the "long" string and if I don't need that, then I can used to "condensed" vesrion of the string, is that right? I mean, that is basically what I did there, isn't it? :)

Quote:

Originally posted by Xenon
@boofo: :) yeah timeformat-string is no real outputstring ;)

Xenon 08-23-2002 10:47 AM

yes it's because the "at" is also a formating option of date/timeformat.

look at http://www.php.net/manual/en/function.date.php to see which chars you cannot use in a formatstring because they are converted

Boofo 08-23-2002 10:51 AM

Thanks for taking the time to help me understand this a little better. Now that I know what I did wrong, maybe I can avoid this in the future when working with the date and time string in vb. :)

Dark Shogun 09-11-2002 05:09 PM

Can ANYONE tell me why this is happening? It only happened after I added this hack.

Dark Shogun

Dark Shogun 09-12-2002 12:25 AM

Problem fixed.

Dark Shogun

Ihsahn 09-24-2002 02:24 PM

Quote:

Originally posted by Dark Shogun
Problem fixed.

Dark Shogun

how did u fix that ?

Dark Shogun 09-24-2002 05:15 PM

I will have to go over the code again and tell you abit later. I works like a charm now.

Dark Shogun

Dark Shogun 09-26-2002 03:21 AM

When it says in the instructions to find:
Code:

if ($s!=$session['dbsessionhash']) {
and replace it with:

Code:

if ($s!=$session['dbsessionhash'] && $reasonentered!=1) {
You are actually supposed to find:
Code:

$s == $session['dbsessionhash'] )) {
and replaced it with:

Code:

$s == $session['dbsessionhash'] && $reasonentered!=1)) {
That made everything show.

I am having a small problem though. When you close a topic and put in the reason it works fine but when you open it the reason stays there except it isn't in the box.

Dark Shogun

Xenon 09-26-2002 10:46 AM

Quote:

Originally posted by Dark Shogun
I am having a small problem though. When you close a topic and put in the reason it works fine but when you open it the reason stays there except it isn't in the box.

Dark Shogun

That was a bug in one of the first versions of this hack, it shouldn't be in the latest version.
are you sure you've no parts of an old version in your files?

Dark Shogun 09-26-2002 04:14 PM

Xenon can you attach or tell me which version is the most up todate and how to make it so it shows who closed the topic?

Dark Shogun

Xenon 09-26-2002 05:26 PM

of course :)
latest version is in the attachment :)

to show who closed the topic:
change this line in the instructions:
$closereason=" closereason='".addslashes($reason)."', ";

into this:
$closereason=" closereason='".addslashes($reason)." (by $bbuserinfo[username])', ";

Dark Shogun 09-26-2002 05:50 PM

Works perfectly. :)

Dark Shogun

X-Fan 10-10-2002 06:26 AM

Quote:

Originally posted by Xenon
latest version is in the attachment :)
Does this work on 2.2.8, because in postings.php I'm not finding...

PHP Code:

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

But I am finding...

PHP Code:

// ############################### start do open / close thread ###############################
if ($HTTP_POST_VARS['action'] == 'openclosethread' OR ($action == 'openclosethread' AND == $session['dbsessionhash')) { 


Xenon 10-10-2002 08:57 AM

yes it should work with vb228 too (it does at my forum)

the code has changed a bit from 227 to 228, so normally all should be ok if you just leave out this step:
Code:

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


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


ZiRu$ 10-13-2002 03:53 AM

Installed the latest Version....still got a problem!

When you close a thread.....then open a thread....and then go to close it again....it has the last message in there and if you replace it all and type something new then it dosent have the thread closers username there......

Xenon 10-13-2002 09:04 AM

it should be that it still have the old message until you delte it and write another one..

the username isn't included in the official release, if you use the modifications i told in the thread, they should work, but it's not 100% because i didn't test em

C.Birch 10-13-2002 02:57 PM

how can i make it so it whys why a topic was closed in the topic list of a forum?

so its something like this

topic name
why it was closed if its a closed topic

Xenon 10-13-2002 03:08 PM

you should be able to use $thread[closereason] in your forumdisplaybit templates...

C.Birch 10-13-2002 04:03 PM

Tryed that did not work

PHP Code:

<tr align="center">
    <
td bgcolor="{firstaltcolor}"><img src="{imagesfolder}/$thread[newoldhot].gif" border="0" alt=""></td>
    <
td bgcolor="{secondaltcolor}">$thread[icon]</td>
    <
td bgcolor="{firstaltcolor}" align="left" width="70%"><normalfont>$thread[gotonew$paperclip$thread[movedprefix]$thread[typeprefix]<a href="showthread.php?s=$session[sessionhash]&threadid=$thread[threadid]">$thread[title$thread[closereason] </a></normalfont> <smallfont>$thread[pagenav]</smallfont></td>
    <
td bgcolor="{secondaltcolor}" width="30%" nowrap><normalfont>$thread[postedby]</normalfont></td>
    <
td bgcolor="{firstaltcolor}"><normalfont><a href="javascript:who($thread[threadid])">$thread[replycount]</a></normalfont></td>
    <
td bgcolor="{secondaltcolor}"><normalfont>$thread[views]</normalfont></td>
    
$threadrating
    
<td bgcolor="$backcolor">
        <
table cellpadding="0" cellspacing="0" border="0" width="100%" id="ltlink"><tr align="right">
            <
td nowrap><smallfont>$thread[lastreplydate] <font color="{timecolor}">$thread[lastreplytime]</font><br>
            
by <a href="member.php?action=getinfo&find=lastposter&threadid=$thread[threadid]"><b>$thread[lastposter]</b></a></smallfont></td>
            <
td nowrap>&nbsp;<a href="showthread.php?s=$session[sessionhash]&goto=lastpost&threadid=$thread[threadid]"><img src="{imagesfolder}/lastpost.gif" border="0" alt="Go to last post"></a></td>
        </
tr></table>
    </
td>
</
tr


ZiRu$ 10-13-2002 07:31 PM

Quote:

Originally posted by Xenon
it should be that it still have the old message until you delte it and write another one..

the username isn't included in the official release, if you use the modifications i told in the thread, they should work, but it's not 100% because i didn't test em

i know man....but i did test it.....i used your newest release and the showing name add-on

Xenon 10-14-2002 04:32 PM

sorry c.birch my fault, you have to edit forumdisplay.php
find this
PHP Code:

$threads=$DB_site->query("
SELECT 
$dotuserid $votequery ".iif($foruminfo[allowicons],'icon.title as icontitle,icon.iconpath,','')."
    thread.threadid,thread.title,lastpost, forumid,pollid,open,replycount,postusername,postuserid,
    lastposter,thread.dateline,views,thread.iconid,notes,thread.visible,sticky,votetotal,attach
    FROM thread
    "
.iif($foruminfo[allowicons],'LEFT JOIN icon ON (icon.iconid = thread.iconid)','')."
    
$dotjoin
    WHERE 
$threadids 

or similar and after votetotal,attach
add
,closereason

ziru$: well i can't give full support on add-on i posted i the thread because some wanted as long as i don't test them myself how the work...
i've planned to update the hack but i don't have much time these days...

N9ne 10-16-2002 05:34 PM

Zirus: I have this installed on 2.2.8, the instructions that Xenon posted a page back or so, they work fine. I closed a thread. It showed the reason and who did it. I opened it. I closed it, deleted the full reason already there, put in something else and it still showed who closed it.

N9ne 10-16-2002 07:44 PM

I've found a problem, when I close a thread, give a reason, then open it and then I go to newreply.php [I have a hack so that there's a checkbox to close thread upon newreply and newthread], when I close the thread in that way, the thread is closed but the reason comes up again! [it shouldn't, as I haven't given a reason!] and it uses the same username as the person who gave that reason when it was closed first...

Xenon 10-16-2002 09:46 PM

Tha Rock, that's a problem with your quickclose hack.

i don't know it exactly, but somewhere in newreply you'll find something similar like this:
Code:

$DB_site->query("UPDATE thread SET open=0.....
you have to change it to:
Code:

$DB_site->query("UPDATE thread SET open=0,closereason=''.....

!!!cyr0n_k0r 10-17-2002 04:55 AM

the screen shots dont work.

N9ne 10-17-2002 03:33 PM

Xenon: I can't find anything like that in newreply.php...I can't even find open=0...

Xenon 10-17-2002 07:41 PM

well i don't know the hack, so i can't help you out then, you should ask in the supportthread of that hack...

normally such a line has to be in it, because that would be the query to close a thread..


All times are GMT. The time now is 09:16 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.01686 seconds
  • Memory Usage 1,862KB
  • 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
  • (11)bbcode_code_printable
  • (6)bbcode_php_printable
  • (8)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)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