[DEV] Pafiledb [DOWNLOAD MOD] 0.0.9d

A place for MOD Authors to post and receive feedback on MODs still in development. No MODs within this forum should be used within a live environment! No new topics are allowed in this forum.
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: MOD Development Forum rules

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.
Locked
Mohd
Registered User
Posts: 263
Joined: Mon Jul 15, 2002 9:06 pm
Contact:

Post by Mohd »

ok do the following
open the file
pafiledb/includes/download.php

find this:

Code: Select all

$url = $board_config['server_name'];

if (!eregi($url,$_SERVER['HTTP_REFERER']))
{
	$template->assign_vars(array(
		"META" => '<meta http-equiv="refresh" content="3;url=' . append_sid("dload.php?action=file&id=" . $id) . '">')
	);

	$message = $lang['Directly_linked'];

	message_die(GENERAL_MESSAGE, $message);
}
And delete it.

I made this addition so no one can link to your file directly. ( you can link it to the file page)
Visit My Site Mohd Web Site!
My Current mod is PaFileDb Integration 0.0.8
Demo: Click Here
No support via PM
testebr
Registered User
Posts: 303
Joined: Thu Nov 28, 2002 5:05 am

Post by testebr »

wait please!
Last edited by testebr on Sun Feb 09, 2003 10:57 pm, edited 1 time in total.
Mohd
Registered User
Posts: 263
Joined: Mon Jul 15, 2002 9:06 pm
Contact:

Post by Mohd »

this not my file in my mod your not using my mod this is the original file I mean the one in your phpbb root directory pafiledb/includes/download.php
Visit My Site Mohd Web Site!
My Current mod is PaFileDb Integration 0.0.8
Demo: Click Here
No support via PM
Mohd
Registered User
Posts: 263
Joined: Mon Jul 15, 2002 9:06 pm
Contact:

Post by Mohd »

why don't you register in my site to get better support.
here http://www.hostsector.com/~mohd/main/index.php
Visit My Site Mohd Web Site!
My Current mod is PaFileDb Integration 0.0.8
Demo: Click Here
No support via PM
testebr
Registered User
Posts: 303
Joined: Thu Nov 28, 2002 5:05 am

Post by testebr »

It forgives for the error of this message!
testebr
Registered User
Posts: 303
Joined: Thu Nov 28, 2002 5:05 am

Post by testebr »

I removed the cited code but now I am with another problem!

The system only redirects for link real of the archive to put does not start download.

The URL of the archive in the navigator and the blank pagina is writing.
Mohd
Registered User
Posts: 263
Joined: Mon Jul 15, 2002 9:06 pm
Contact:

Post by Mohd »

could you give me the link please to see what is the problem?
Visit My Site Mohd Web Site!
My Current mod is PaFileDb Integration 0.0.8
Demo: Click Here
No support via PM
testebr
Registered User
Posts: 303
Joined: Thu Nov 28, 2002 5:05 am

Post by testebr »

ok

lets go in url:

http://64.191.5.137/~xistomy/forum/dloa ... =file&id=2

Login to tester is:

Login: teste
Password: teste123


My file download.php is:
<?php
/*
paFileDB 3.0
©2001/2002 PHP Arena
Written by Todd
todd@phparena.net
http://www.phparena.net
Keep all copyright links on the script visible
Please read the license included with this script for more information.
*/

if ( !defined('IN_PHPBB') )
{
die("Hacking attempt");
}

if ( isset($HTTP_GET_VARS['id']) || isset($HTTP_POST_VARS['id']) )
{
$id = ( isset($HTTP_GET_VARS['id']) ) ? intval($HTTP_GET_VARS['id']) : intval($HTTP_POST_VARS['id']);
}

$sql = "SELECT * FROM " . PA_FILES_TABLE . " WHERE file_id = '" . $id . "'";

if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Couldnt select download', '', __LINE__, __FILE__, $sql);
}

$file = $db->sql_fetchrow($result);

$time = time();

$sql = "UPDATE " . PA_FILES_TABLE . " SET file_dls=file_dls+1, file_last=" . $time . " WHERE file_id = '" . $id . "'";

if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Couldnt Update Files table', '', __LINE__, __FILE__, $sql);
}

header("Location: " . $file['file_dlurl']);

?>
Mohd
Registered User
Posts: 263
Joined: Mon Jul 15, 2002 9:06 pm
Contact:

Post by Mohd »

It is downloaded ok there no problem, so what is the problem that happen for you?
Visit My Site Mohd Web Site!
My Current mod is PaFileDb Integration 0.0.8
Demo: Click Here
No support via PM
testebr
Registered User
Posts: 303
Joined: Thu Nov 28, 2002 5:05 am

Post by testebr »

YES! YES! YES! YES! YES! YES! YES!


Now it is functioning perfectly!

Very obliged for its aid!

You intend to create add'ons or mod's for pafiledb?

I have some good ideas!
Mohd
Registered User
Posts: 263
Joined: Mon Jul 15, 2002 9:06 pm
Contact:

Post by Mohd »

register in my support site for this mod and give your idea there. there is a forum for suggestion related to this mod. http://www.hostsector.com/~mohd/main/index.php
Visit My Site Mohd Web Site!
My Current mod is PaFileDb Integration 0.0.8
Demo: Click Here
No support via PM
testebr
Registered User
Posts: 303
Joined: Thu Nov 28, 2002 5:05 am

Post by testebr »

How I make for the system of downloads to function with links of sig2dat of kazaa?

one example link of kazaa:

sig2dat:///|File:KLCheater.exe|Length:89088 Bytes, 87KB|UUHash:=byZyDwJf1u9Aixk5MkL83P+j/v8=|
Mohd
Registered User
Posts: 263
Joined: Mon Jul 15, 2002 9:06 pm
Contact:

Post by Mohd »

sorry don't have any idea
Visit My Site Mohd Web Site!
My Current mod is PaFileDb Integration 0.0.8
Demo: Click Here
No support via PM
testebr
Registered User
Posts: 303
Joined: Thu Nov 28, 2002 5:05 am

Post by testebr »

You intend to make some change to accept links of kazaa?

I am needing very this!
Mohd
Registered User
Posts: 263
Joined: Mon Jul 15, 2002 9:06 pm
Contact:

Post by Mohd »

I will see what I can do
Visit My Site Mohd Web Site!
My Current mod is PaFileDb Integration 0.0.8
Demo: Click Here
No support via PM
Locked

Return to “[2.0.x] MODs in Development”