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)
-   -   Attachments as files (https://vborg.vbsupport.ru/showthread.php?t=35193)

mojotim 03-07-2002 09:43 AM

Hi, any updated instruction for the /admin/functions.php with vBulletin 2.2.3?

Scott MacVicar 03-07-2002 02:52 PM

Is the hack not working with vBulletin 2.2.3?

I haven't had a chance to look at 2.2.3 in any detail yet, John released this at a wierd time for someone who lives in the UK.

Destee 03-12-2002 10:38 PM

2.2.4 and all is well PPN! :)

thewiz 03-15-2002 06:33 PM

Hi

I have 2.2.4 and I do the whole install fine but when I get to the importer this is the error.

Warning: Supplied argument is not a valid File-Handle resource in /home/virtual/site9/fst/var/www/html/forum/admin/attachment_install.php on line 333

Imported makoact11.zip

on all my files it does not import anything.

Armando

Scott MacVicar 03-15-2002 08:34 PM

either your folder permissions are wrong, did you create the folder?

Did you set the path to this folder within the vBulletin options?

Check these and get back to me.

thewiz 03-15-2002 10:05 PM

The way the server was setup the path to the folder was incorrect now I got it all working. I have another Question I saw today in another forum at www.dssarea51.com/forum this was a nice feature you know when you have alot of Mods in your board how it extends the forum display they had a drop down list for the mods to keep the forum display not so wide. do you know how they did that.

Thanks for the help on the other issue
Armando

Tim Wheatley 03-18-2002 06:23 PM

Yes there's a hack for that, go to 'search' above and search for moderators drop down list.

waddy 03-19-2002 01:32 PM

The Hack works Great on 2.2.4

Fantastic Hack , thanks PPN

Couple of Questions :

You say drop the filedata table - would it be ok just to "empty" the Attachments Table.

If I delete a thread with an attachment - does it remove the attachment from my Attachment Folder ?

Scott MacVicar 03-19-2002 06:35 PM

Don't empty the attachments table, this is needed as it holds the attachment id and the file hash. You *MUST* drop the filedata column that is the only way.

If you delete a thread or delete an attachment while editing it will also remove it from the attachment folder.

waddy 03-19-2002 10:09 PM

Ok thanks PPN

What the SQL query to drop that table please

kidney 03-19-2002 11:34 PM

I seem llike I can't upload anything anymore, Can anyone help!!
I re-applied the hack, and still no result.....
I'm running a heavelly hacked 2.2.3.
I can send you my function.php files if required.

Freddie Bingham 03-20-2002 02:57 AM

ALTER TABLE attachment DROP filedata

..if I was you I wouldn't do that though as that can only cause you problems when you upgrade to v3.0

This would be better:

UPDATE attachment SET filedata = ''

waddy 03-20-2002 10:23 AM

Thanks Freddie,

I was concerned about dropping the filedata column = issues on future updates.

I hope v 3.0 has Attachments as files. My database has never run better since I did this hack.

Freddie Bingham 03-20-2002 02:24 PM

It might give you the option to choose at your whim ;)

NitroSimSev 03-20-2002 03:10 PM

PPN - I am currently running PHP portals and I am trying to get the attachment mod to work with a news program. Below is a block of code I would like to modify to get it to work. right now the images do not show up:

function centerblocks_topstories_block($row) {
include("config.php");
global $DB_site,$dateformat,$bburl;

$result=$DB_site->query("SELECT dateline,title,threadid FROM thread WHERE forumid=$topStoryForum ORDER BY dateline DESC LIMIT $topStoryNum");


$cc=1;
while ($topStory=$DB_site->fetch_array($result)) {
$postdate{$cc}=vbdate($dateformat,$topStory[dateline]);
$topStoryTitle{$cc}=$topStory[title];
$topStoryID{$cc}=$topStory[threadid];

$result1=$DB_site->query("SELECT pagetext,postid FROM post WHERE threadid=$topStory[threadid]");
$postinfo=$DB_site->fetch_array($result1);
$topStoryTeaser{$cc}=$postinfo[pagetext];
$topStoryImage{$cc}="$bburl/attachment.php?s=&postid=$postinfo[postid]";

The
$topStoryImage{$cc}="$bburl/attachment.php?s=&postid=$postinfo[postid]";
is the part of code I cant seem to get to work right. Any Ideas?

waddy 03-23-2002 08:34 AM

BUG ? : When Editing or Delelting a thread with an attachment i am now getting this in the header of the page

Warning: Unlink failed (No such file or directory) in /users/waddy/www.xp-erience.org/forum/admin/functions.php on line 1696

ALSO :

One of my users is uploading an attachment, yet when we try to view the image we get this error

Warning: stat failed for /users/waddy/attchvb/958a09ca32b93cb743bf90ce001d58c0.file (errno=2 - No such file or directory) in /users/waddy/www.xp-erience.org/forum/attachment.php on line 60

HellRazor 03-23-2002 07:46 PM

The only problem I am having is that once you select the file for uploading, the "Use Custom Avatar?" radio button turns off. People often miss that, and what happens is the avatar defaults to the first avatar in the normal list.

Is there any way to make this default to "use custom avatar" when a file is uploaded?

Wayne2k1.com 03-27-2002 10:17 AM

Quote:

Originally posted by HellRazor
The only problem I am having is that once you select the file for uploading, the "Use Custom Avatar?" radio button turns off. People often miss that, and what happens is the avatar defaults to the first avatar in the normal list.

Is there any way to make this default to "use custom avatar" when a file is uploaded?

Same problem 4 me...

Scott MacVicar 03-27-2002 03:39 PM

I'll look into this now, I presume that the avatar upload uses the accept_upload function within the admin panel and it might require a bit of editing.

xware 03-27-2002 06:04 PM

Quote:

Originally posted by HellRazor
The only problem I am having is that once you select the file for uploading, the "Use Custom Avatar?" radio button turns off. People often miss that, and what happens is the avatar defaults to the first avatar in the normal list.

Is there any way to make this default to "use custom avatar" when a file is uploaded?

Same to me.
IS a bug? :eek:

Renegade 03-27-2002 09:11 PM

I think I will wait until everything is resolved....

Scott MacVicar 03-27-2002 10:52 PM

This has nothin to do with my hack, i've just checked and it looks like this before my hack is installed.

jardragon901 03-28-2002 10:58 AM

hmm the instalation went fine, except whenever I try to upload anything it keeps giving me an invalid extension error. its a test board on XP, bb 2.2.4 anything i should check?
I also have it on a different disk than c: do I have to add the drive letter? also do I use "/" or "\" for the path?

Cocomiel 03-30-2002 04:50 AM

Quote:

Originally posted by xware

Same to me.
IS a bug? :eek:

Seems to be a bug in vb 2.2.4 : Edit modifyavatar_custom template and remove the following code:

PHP Code:

<script language="Javascript">
<!--
function 
checkCustom(formname) {
    
formname.avatarid[1].checked=true;
}
//-->
</script


waddy 03-31-2002 10:20 AM

WTF !

why has this thread gone to "My avatar doesnt work" ?

whos moderating here ?

I have legit bugs with this HACK, that the thread is about, and they are going on about avatars - eh ?

MIKdoubleE 03-31-2002 11:11 PM

I'm getting this parse error:

Parse error: parse error in /home/hiphopfu/public_html/forums/admin/attachment_install.php on line 345

Can i know exactly what to do??? I'm a newbie to MySQL and VB so i dont know much.

waddy 04-01-2002 07:25 AM

This only happens with about 4 /10 - The attachment is in the thread - People go to view it

And you get this error :

Warning: stat failed for /users/waddy/attchvb/0c4913343c10e31b4157235047602ccf.file (errno=2 - No such file or directory) in /users/waddy/www.xp-erience.org/forum/attachment.php on line 60

Warning: fopen("/users/waddy/attchvb/0c4913343c10e31b4157235047602ccf.file", "rb") - No such file or directory in /users/waddy/www.xp-erience.org/forum/attachment.php on line 61

Warning: Supplied argument is not a valid File-Handle resource in /users/waddy/www.xp-erience.org/forum/attachment.php on line 62

Warning: Supplied argument is not a valid File-Handle resource in /users/waddy/www.xp-erience.org/forum/attachment.php on line 63

Warning: Cannot add header information - headers already sent by (output started at /users/waddy/www.xp-erience.org/forum/attachment.php:60) in /users/waddy/www.xp-erience.org/forum/attachment.php on line 64

Warning: Cannot add header information - headers already sent by (output started at /users/waddy/www.xp-erience.org/forum/attachment.php:60) in /users/waddy/www.xp-erience.org/forum/attachment.php on line 65

Warning: Cannot add header information - headers already sent by (output started at /users/waddy/www.xp-erience.org/forum/attachment.php:60) in /users/waddy/www.xp-erience.org/forum/attachment.php on line 66

Warning: Cannot add header information - headers already sent by (output started at /users/waddy/www.xp-erience.org/forum/attachment.php:60) in /users/waddy/www.xp-erience.org/forum/attachment.php on line 67

Warning: Cannot add header information - headers already sent by (output started at /users/waddy/www.xp-erience.org/forum/attachment.php:60) in /users/waddy/www.xp-erience.org/forum/attachment.php on line 68

Warning: Cannot add header information - headers already sent by (output started at /users/waddy/www.xp-erience.org/forum/attachment.php:60) in /users/waddy/www.xp-erience.org/forum/attachment.php on line 74

Scott MacVicar 04-01-2002 07:53 AM

This only happens if the file doesn't exist, was it removed or is the disk space allotment for your account full?

MIKdoubleE 04-02-2002 12:26 AM

Yeah, i figured it out......but heres a question, is there anyway, i can change the url on the attachment....i mean, like my board is hosted on my server, www.hiphopfuture.com and i was wondering if i can tweak the hack and point the attachment uploads to another server. To save space on mine.....any way?????

Mutt 04-02-2002 12:58 AM

just upgraded to 224 and installed this hack. install went well and files were properly exported to the new dir. old attachments display properly. problem is, I can't upload any longer. :(

New uploads aren't saved in the dir, but at least the db info gets stored properly. Anyone else with this problem?

stored correctly
attachmentid userid dateline filename visible counter

stored incorrectly
filedata hash

hash is blank
filedata should be blank but instead says GIF89a? (note the one ")

Mutt 04-02-2002 02:27 AM

sorry, my bad

forgot to upload admin/functions.php

opps

thanks!! works great

MIKdoubleE 04-03-2002 02:58 AM

Quote:

Originally posted by MIKdoubleE
Yeah, i figured it out......but heres a question, is there anyway, i can change the url on the attachment....i mean, like my board is hosted on my server, www.hiphopfuture.com and i was wondering if i can tweak the hack and point the attachment uploads to another server. To save space on mine.....any way?????
HELLO!! is there any support for this hack?????!!!!!!!

Freddie Bingham 04-03-2002 03:05 PM

No.

Ninth Dimension 04-03-2002 03:45 PM

I've just installed this hack, and so far I can't see any problems with it, apart from .png files, they either don't upload at all, or they don't display correctly. has anyone else seen this at all?

Scott MacVicar 04-03-2002 06:49 PM

I've not noticed the problem with png files, though support for this was only added in 2.2.2 in attachment.php are you running 2.2.2 or later?

Mike if you don't have space for attachments on your server dont turn them on, simple as that!

Ninth Dimension 04-03-2002 07:08 PM

I'm running vB 2.2.4, it could have just been the file I was using to test it with, but it should not be a huge problem or anything like that :)

Scott MacVicar 04-03-2002 07:16 PM

at the bottom of attachment.php it should have

PHP Code:

elseif ($extension=="png") {
  
header("Content-type: image/png");


as part of the check for image type.

Ninth Dimension 04-03-2002 07:24 PM

Yup, it's got that, oh well

Oh, a quick word of warning, when I downloaded the file earlier today, you have not got the ?> at the end of the file, I added it myself and it worked fine, but you might wanna re-upload the file :)

waddy 04-03-2002 10:05 PM

Quote:

This only happens if the file doesn't exist, was it removed or is the disk space allotment for your account full?
Ive got tons of space and the files in question have not been deleted.


The forum says there is a file attached- when you click on the attachment to view it - you get this

http://www.xp-erience.org/forum/show...&threadid=7730

its driving me insane !

hypedave 04-12-2002 01:01 AM

I just installed this hack, and now when upload attachments, I get the followig errors

Warning: Unable to create '/images/temp/89ce924a310f80c7e6a83893410f7ded.file': No such file or directory in C:\Inetpub\wwwroot\forums\admin\functions.php on line 1705

Warning: Unable to move 'C:\WINNT\TEMP\php6A9.tmp' to '/images/temp/89ce924a310f80c7e6a83893410f7ded.file' in C:\Inetpub\wwwroot\forums\admin\functions.php on line 1705


All times are GMT. The time now is 04:20 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.01383 seconds
  • Memory Usage 1,830KB
  • 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
  • (2)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