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)
-   -   Upload Hack (https://vborg.vbsupport.ru/showthread.php?t=37233)

Ember 12-18-2002 01:26 PM

I guess version 2 definatly isnt happening, its been like 4 months... never mind! I guess I will have a go at making my own then.

ScruffyDeluxe 01-20-2003 12:54 PM

I wanted a bit more control over how the page looks, so I integrated it with vBulletin's AdminCP cascading style sheet.

Here's my upload script (I'm using the Xelation CSS BTW):
http://www.phuck-ign.com/forums/upload.php

Other tweaks include the $bbtitle string (guess where that's used :P ) and the upload 'report' now shows the full path to the uploaded file.
I use this script specifically for Signature pictures, and my members are pleased with it. If anyone is interested in using the modified upload.php, I'll be happy to post it here.

Ember 01-20-2003 01:53 PM

Hey, looks good, I am interested :) Post it if you would :)

SemperFidelis 01-20-2003 03:09 PM

Thats rather good ScruffyDeluxe.
It would be great if you would post that here.
:)

ScruffyDeluxe 01-20-2003 04:18 PM

Added a few more bits here and there.
Let me know if anything looks or acts dodgy :paranoid:

Trident 02-28-2003 12:46 PM

I need the new version !!

Schorsch 03-01-2003 07:06 PM

yeah version 2 would be great!! :bunny:

Nickos 04-10-2003 09:51 AM

:(

Nickos 04-10-2003 11:18 AM

Quote:

04-09-02 at 07:41 PM Fazle said this in Post #8
Ok, can I upload to a different server? I am trying to separate attachments and have them uploaded to a server other than the one the forum is hosted on

Quote:

04-09-02 at 07:57 PM Slynderdale said this in Post #12
....theres already a hack though that uploads attachemnets to the server instead to the mysql database
where can i find this hack?

Opie 04-29-2003 07:45 PM

Right here:

https://vborg.vbsupport.ru/showthrea...threadid=35193

ipscone 04-30-2003 02:16 PM

I'm getting "Couldn't Copy File To Server" error. I have done some troublshooting on this...

1) I have checked the permissions and they are 777.
2) I have verified that the login is checked properly.
3) I have verified that the folder is created, for the user, when a file upload is attempted, in the upload directory.
4) I have verified that the copy path is correct. I put some test code in to see what the script thinks the path is and it returns:
/MyAbsolutePath/ipscone/MyTestFile.gif, which is the correct absolute path.
5) I have even manually copied a file to the upload/member folder and when I try to use the Upload.php program to upload that same file, it correctly sees that it's a duplicate. So that part works ok.
6) I have tried to view that directory with the View Files and even though there is one file that was manually copied, it doesn't display with the View Files.
7) I modified the upload.php file to do some debugging and found something I can't explain. In the case view: section, I modified the following:
Code:

$dir = opendir("$absolute_path/$PHP_AUTH_USER")
      or $list .= "<tr><td>Error: Can't open $absolute_path/$PHP_AUTH_USER</td></tr>";
while($file = readdir($dir)) {{

to see that the absolute path was right and it was. Now, I know there is one file in the directory but the code within the while loop does not execute even once. Since there is one file there (manually placed) it should go through this loop, at least once. Why not?

Can there be an incompatibility with php 4.3.1 that I'm using?

But the file just won't copy. I get "Couldn't Copy File to Server".

Any idea what might be causing this error? opendir adn copy seem to fail.

Is this the only UPLOAD program that produces individual folders for each of the members?

What version is included in the first post in this thread? Is there a newer version somewhere?

ipscone 05-01-2003 03:26 AM

Ok, I have a clue to the symptoms but no answer to the problem yet.

The opendir() and copy() fail because of the way the directory is created. The script uses the following to create the upload directory
PHP Code:

if (!is_dir("$absolute_path/$PHP_AUTH_USER")) {
   
$oldumask umask(0);
   
mkdir("$absolute_path/$PHP_AUTH_USER",0777); 
   
umask($oldumask);
   if (
$indexfile 
        
fopen("$absolute_path/$PHP_AUTH_USER/index.html""a")) {
      
$timenow time();
      
$name    strip_tags($PHP_AUTH_USER);
      
fwrite($indexfile"");
      
fclose($indexfile);
    }


With this code, the directory is created but the owner is "apache." When the owner is apache, the opendir() and copy() don't work in the script.

But if I manually create any directory that I plan to use, instead of the program doing it, everything works fine. I can upload and the opendir() and copy() work fine.

How does one change the script to avoid this problem? I believe it is normal for "apache" to be the owner of something created from the script but why doesn't the copy() and opedir() work for a directory that has "apache" as the owner? Any way around this?

ipscone 05-01-2003 08:30 PM

Now, I'm thinking this inability to use copy() and opendir() has to do with the open_basedir configuration.

The program works perfectly, if I manually create the folder and set the permissions. But if the program creates the directory, I can't open or copy to it.

Anyone know how I can get around this and open and copy files, if this is the case? Or, if this is not the problem what is?

kevinnguyen 05-19-2003 01:11 AM

man, where's v2? it sounds great
any1 here knows how to add more upload boxes?

LangTuDaTinh 05-19-2003 01:43 AM

Quote:

05-01-03 at 02:30 PM ipscone said this in Post #93
Now, I'm thinking this inability to use copy() and opendir() has to do with the open_basedir configuration.

The program works perfectly, if I manually create the folder and set the permissions. But if the program creates the directory, I can't open or copy to it.

Anyone know how I can get around this and open and copy files, if this is the case? Or, if this is not the problem what is?


i think u must go to telnet or SSH and change its chown from apache to that site's user.

corsacrazy 06-20-2003 07:36 AM

bump once again the creator if ur out there please share version 2 with us

Nebby 06-25-2003 12:15 PM

:(

ipscone 06-25-2003 01:10 PM

Here is one I'm working on...

Photo album

corsacrazy 06-25-2003 02:40 PM

looks good is it intergrated in to users database?

Nebby 06-26-2003 11:39 PM

Can it be edited to work with MP3's?

themonarch 08-26-2003 10:11 PM

Hey, this worked for me on vBulletin 2.3.2! I can't wait for version 2....uh....too. :)

themonarch 08-26-2003 10:19 PM

Quote:

06-27-03 at 01:39 AM Nebby said this in Post #100
Can it be edited to work with MP3's?
Just add .mp3 to the config file, like this..... around line 7

Code:

$extensions = array(".gif", ".jpg", ".jpeg", ".mp3", ".ra", ".txt", ".doc", ".swf", ".avi");

luke2kz71 02-13-2004 09:03 PM

it was working fine.. then all the sudden it keeps telling me my password is wrong :( i know its right :(

PIF 03-07-2004 06:09 PM

Hi,

I have downloaded and installed Slynderdale's Uploader.

How can I have the two boxes,(upload and view) alongside each other, rather than one in top of the other ?

yavar 04-09-2004 08:16 PM

Quote:

Originally Posted by Slynderdale
Im working on the upload hack version 2, if you want any thing custom added, please post and tell me what you want and ill see if i can add it into the new version for ou and so on.

1.working with ftp accounts no database because increase of database space maybe makes problems!
2.user post limit!!!
for example:user should have 200 posts to have a upload folder
___________-
I`m waiting for ver 2 :nervous:
sorry for my bad english
:speechless:

MeTaL_oRgY 04-10-2004 04:52 AM

Working wonderful! thnx for this hack!! Exelent for my Fan Art section!!!!

yavar 04-10-2004 08:16 AM

Dear Slynderdale,
we are waiting for you!

MeTaL_oRgY 04-13-2004 01:38 AM

Dear Slynderdale, I?m using this hack for my fan-art section:)... it works perfectly, but I qould like some features...
1) Would it be possible that n the index.html file of every fanartist folder appears the Fa?-Artist stats? Oo...
2) How can I change the option so that when the script creates the file automatically it saves itself as .php and not as .html ?

that?s it :) waiting your response :)...

and GREAT HACK!!!

MeTaL_oRgY 04-14-2004 06:22 PM

BTW, I can upload files and it creates everything but it don´t write on the index.htm file... why?? of course it´s CHMODED..... but it´s not writing on the file :s

yavar 04-16-2004 11:30 AM

:disappointed: whats up?
:ermm:

scratche 02-12-2005 02:00 AM

is there anyway you can set the hack up that only certain users.. or a user group only can use the upload.. not all of your users..

Rireal 02-14-2005 01:17 AM

Quote:

Originally Posted by scratche
is there anyway you can set the hack up that only certain users.. or a user group only can use the upload.. not all of your users..

Agreed. Also, could this be updated for vB3?

php4dev 03-17-2005 08:24 PM

Quote:

Originally Posted by Rireal
Agreed. Also, could this be updated for vB3?

could this be updated for vB3?

php4dev 03-18-2005 09:38 AM

could you update it for vB3 ????

:rolleyes:

Marco van Herwaarden 03-18-2005 10:05 AM

Updated probably not. The differences between vB2 and vB3 are probably too big, and i am not sure if the original coder is still available to do this.

php4dev 03-19-2005 09:21 AM

Mr. Slynderdale where are you ???

We are needing your help ...


All times are GMT. The time now is 11:22 PM.

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.01248 seconds
  • Memory Usage 1,818KB
  • 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_code_printable
  • (1)bbcode_php_printable
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (36)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