Adult Script Pro Community Forums

The forum is here for legacy reasons. No new posts will be created. User registration is disabled! If you have any questions, please email us or check https://www.adultscriptpro.com for more details!

You are not logged in.

#1 2016-05-27 06:01:15

discuss4u
Member
Registered: 2013-03-06
Posts: 163

Download property in multiserver setting

Hello, I would like to know what I should set for "Download Property"

when setting up video server

Seems that it is a new feature in 2.2.2 and it is not possible to add new server without setting it.

Thanks!

Offline

#2 2016-05-27 06:47:08

symtab
Administrator
Registered: 2010-08-23
Posts: 7,501
Website

Re: Download property in multiserver setting

In the tools folder there is a download.php and a .htaccess file. These two files need to be uploaded to the video server. The url you enter when you add a new server is the url to the download.php without the actual download.php. Basically if you would have http://videos.domain.com/download.php you will have as url, http://videos.domain.com also make sure you set secret the same as in download.php. This new feature allows users to download videos without actually showing the full url and its also always force download (no matter what kind of device the user uses).


Adult Scripts: Adult Script Pro - Adult Search Script
Adult Advertising/Traffic: Plug Rush - EXOClick - PopAds

Offline

#3 2016-05-27 07:29:07

discuss4u
Member
Registered: 2013-03-06
Posts: 163

Re: Download property in multiserver setting

Thanks. I have do the setting thing but it still did not work.

I have found two problems.

1. It will return invalid hash. But I have already set the secret both in download.php and admin

2. I have comment the line in download.php [die("invalid hash");]
Then it will return ERR_INVALID_RESPONSE in CHROME.

I suspect it is the problem of the line

header('X-Accel-Redirect: /files'.$file.secure_nginx($file)); 

or

header('X-Accel-Redirect: /files'.$file);  

Because it works if I change these two lines to

readfile($file_path);

Last edited by discuss4u (2016-05-28 05:21:09)

Offline

#4 2016-05-28 09:30:37

discuss4u
Member
Registered: 2013-03-06
Posts: 163

Re: Download property in multiserver setting

Hello symtab, please help to check the issue when you have time.

Thanks!

Offline

#5 2016-05-30 04:37:28

symtab
Administrator
Registered: 2010-08-23
Posts: 7,501
Website

Re: Download property in multiserver setting

Check the defines in the header and make sure both define('NGINX', true); and define('NGINX_SECURE_LINK', true); are set to false. Once this is done, to fix the invalid hash add this:

if ($file['0'] != '/') {
    $file   = '/'.$file;
}

after:

$slug   = (isset($_GET['slug'])) ? trim($_GET['slug']) : null;

Let me know if this fixes the problem.


Adult Scripts: Adult Script Pro - Adult Search Script
Adult Advertising/Traffic: Plug Rush - EXOClick - PopAds

Offline

#6 2016-05-30 16:47:50

discuss4u
Member
Registered: 2013-03-06
Posts: 163

Re: Download property in multiserver setting

Hello symtab. I have tried amending download.php, but the problem of invalid hash could not be fixed.

Offline

#7 2016-05-31 06:53:52

symtab
Administrator
Registered: 2010-08-23
Posts: 7,501
Website

Re: Download property in multiserver setting

Please email me FTP access to both servers and i will check and fix.


Adult Scripts: Adult Script Pro - Adult Search Script
Adult Advertising/Traffic: Plug Rush - EXOClick - PopAds

Offline

#8 2016-06-02 01:38:12

discuss4u
Member
Registered: 2013-03-06
Posts: 163

Re: Download property in multiserver setting

Hello symtab, I have sent you an email. Let me know if any further info is needed in order to fix the problem.

Thanks!

Offline

Board footer

Powered by FluxBB