TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

April 30, 2024, 12:59:36 PM

Login with username, password and session length
Members
  • Total Members: 3,885
  • Latest: Growner
Stats
  • Total Posts: 195,174
  • Total Topics: 21,220
  • Online today: 147
  • Online ever: 3,540 (September 03, 2022, 01:38:54 AM)
Users Online
  • Users: 0
  • Guests: 87
  • Total: 87

Download Manager - Files hosting

Started by Unknownn, February 14, 2006, 04:07:06 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Tucker

Yes, I understand. (understanding english is no prob for me, other than writing). Or did you mean the PHP-Code? ;-)

But as I wrote, i knew about manipulating the headers. But your hint is very welcome -> I don't have to google... So I will fix that.

And now about adding this to TP:
the mod is not that heavy. But what is about netiquette. What about promoting files from other servers (ok, that servers and their traffic might be paid by you as well)? But is there a chance of misusing that feature? (ok, any admin will see your referrer in his logs)

What are you thinking?

Unknownn

No just understand my idea  ;D

Maybe you are right but I need this feature for my forum. I don't like use my site to download files that's why my file is hosting in a free service (or paying soon). But I known that some people can misuse this feature.

What can I do now ?

Tucker

Ok, I got it. For your forum it will be ok.

By the way: adding this force-download - header did not do the trick. I think, we would have to open the remote location and stream the content to the client. But that's probably not what you want... (traffic on both servers).

But: My solution is working for zip or anything your browser ist going to download

Ok, and now?
I'm a newbie here, no alpha-tester ;-)
I could attach the two files, or post the diffs here. Just check them at your own risk.

Unknownn

It doesn't matter for the header. I will test but your solution is what I thought ;)

I'm a newbie here too with my english  :uglystupid2:

Else you can send me your files by PM if you are affraid to abuse the feature  ;D

Tucker

Attached them.
Perhaps someone else is interested, or will have a look at them. Anything modded is commented within MOD BEGIN and MOD END. There is one point: look at the comment UUUAAAAHHH  :uglystupid2:

And another thing to think about: currently you have two fields in the uploaddialog: one file-type and the new one, to fill in your link. If you do that, any file uploaded (within the same dialogue) will be ignored. If you want to upload a file, you have to leave the link-fiied empty. Ok?

cu, Tucker

[attachment deleted by admin]

Unknownn

Ok ! This is for me especially !!

Thank you (euh.. How do you say "infiniment"... infinitely ?)
So thank you infinitely Tucker ! You help is very appreciated !

Unknownn  :)

PS: I'm testing now  :D

Unknownn

Ok it works !

You can improve it by add text near the link-field and we can't see the new files in Download Manager ! (But I can modify in MySQL database directly ;))

Else I get a error :
Quote8: Undefined index: tp-dllinkfile
File: mysite/Themes/default/TPdlmanager.template.php (eval?)
Line: 181

Any ideas  ? ;)

Tucker

#17
Oh, I forgot one file: language file with a text string-field $txt[tp-dllinkfile].
That solves of course your problems.

Just add one line in your language file (or TPortal.english.php )

$txt['tp-dllinkfile'] = 'File to<br/>link to:';



Unknownn

Nice !

I've added
$txt['tp-dllinkfile'] = 'File to link to:';

And it's superb !

Thank you very much again. I hope everything is ok !

Tucker

Fine!

Feel free to post any problems. But for now I'm off.

Happy day, Tucker