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)
-   -   Attachment Database (https://vborg.vbsupport.ru/showthread.php?t=45831)

corsacrazy 11-25-2002 08:05 PM

Quote:

Originally posted by corsacrazy
wood there be a way to order the attactments by a value set in the attach.php file ie, order by filesize, number of times downloaded, or extension. ? ?

i would still like there to be an option to order the attactments by date or number of downloads etc , :cry: wood this b possible ? cheers

LanciaStratos 02-10-2003 04:08 PM

This just killed my dedicated server, unfortunately! Too bad, it had a lot of potential. :(

TLfuRy 02-12-2003 02:20 PM

I guess nothing ever got done as far as fixing the load issue. I just installed it, and it loaded a few times....30+ seconds processing time for each pageload. Now my server is down. :(

This is a great idea, and I think this functionality should be part of vB. It would be great to also have the ability to see if the thread still exists, and let you delete selected attachments. Viewing size would be great too.

Martin64 02-12-2003 06:38 PM

I tried this one as well, I had to shut down mysql because it was killing it. Perhaps it's selecting too many attachments? I have an attachment database of 400 MB so maybe that's what caused it, because when installing it locally it worked.

Good idea with the hack though. :)

kuska 02-26-2003 05:45 AM

Well im sure you had good intentions but i had to remowe this hack from my shared server and as ive been told all the people running this hack had to remove it.
I highly dont recommend installing this hack due to the server kill it creates. This is two emails i just recieved from my host http://www.f5hosting.com:

Quote:

David,

You are running a hack file in your public_html folder called attach.php. That is horribly written code, complete garbage. It's got three JOIN's in it!! It's a total server killer. It could choke a dedicated server, much less a shared server. Please remove it. We can't allow it. It locks up mySQL for more than a minute at a time and drives the server load up by a factor of 5 or more. I had to get several sites to remove it, as did many other hosts, when it first came out. Thank you.

Michael

And after i removed the file this is the second email i recieved:




Quote:

Thanks, David. It's not your fault. We all have to be careful what hacks we put on our vB's. Some of them are great, but a lot of them are really bad. This one may be the all time champion server killer, the piece of crap. Some kid wrote it, and didn't know what he was doing.

Michael
lol , not to be mean, i dont know nothing about writing hacks, but Michael totally burned you !!!! :)

Bison 02-26-2003 12:12 PM

No doubt ... the code is bad.

Better let someone revise this hack. It has great potential! :)

Tim Wheatley 03-29-2003 09:25 PM

*bump* :)

mtha 04-18-2003 06:41 AM

Cool hack

I would link thread to the post which has the attachment, using
showthread.php?s=$session[sessionhash]&postid=$att[postid]#post$att[postid]" , and open them in new window:


Quote:

Template name: attachmentbit
Template:

<tr align="center">
<td bgcolor="#F1F1F1"><normalfont><img src="https://vborg.vbsupport.ru/vbimages/attach/$extension.gif" width="16" height="16" border="0" alt=""></normalfont></td>
<td bgcolor="#DFDFDF"><normalfont><a href="$link" target="_blank">$att[filename]</a></normalfont></td>
<td bgcolor="#F1F1F1"><normalfont><a href="member.php?s=$session[sessionhash]&action=getinfo&userid=$att[userid]" target="_blank">$att[username]</a></normalfont></td>
<td bgcolor="#DFDFDF"><normalfont>$att[counter]</normalfont></td>
<td bgcolor="#DFDFDF"><normalfont>$date</normalfont></td>
<td bgcolor="#DFDFDF" align="left"><normalfont><a href="showthread.php?s=$session[sessionhash]&postid=$att[postid]#post$att[postid] " target="_blank">$att[title]</a></normalfont></td>
</tr>


for big forum with many attachments, the script takes too long :((

rake 04-18-2003 06:47 PM

Quote:

02-26-03 at 07:45 AM kuska said this in Post #45
Well im sure you had good intentions but i had to remowe this hack from my shared server and as ive been told all the people running this hack had to remove it.
I highly dont recommend installing this hack due to the server kill it creates. This is two emails i just recieved from my host http://www.f5hosting.com:

And after i removed the file this is the second email i recieved:

lol , not to be mean, i dont know nothing about writing hacks, but Michael totally burned you !!!! :)

Well, at least he's right about my age, but you don't measure the speed of a query by the number of joins. I mean, wow! It's got three joins in it, it must be bad. Oh well, i shouldn't complain. It was my fault.

Here's the fix:
Run the following query:
ALTER TABLE `post` ADD INDEX ( `attachmentid` )

and replace attach.php with the attached file. Be sure to TEST IT.

Kars10 04-18-2003 07:44 PM

Can someone please test it? I have only my liveboard @ the moment but i need this hack! :)

Thanks in advance
Kars


All times are GMT. The time now is 01:45 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.01114 seconds
  • Memory Usage 1,746KB
  • 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
  • (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
  • (10)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