Home > CMS Tutorial > DEDECMS > body text

How to prevent hotlinking in download.php of DreamWeaver download channel

藏色散人
Release: 2020-01-09 09:13:52
Original
2470 people have browsed it

How to prevent hotlinking in download.php of DreamWeaver download channel

How to prevent hotlinking in download.php of Dreamweaver download channel?

Dreamweaver DEDECMS download channel download.php anti-hotlinking

Recommended learning: Dreamweavercms

1.Download channel anti-hotlinking function The link display method must be set in the software channel settings: Request to enter the download address list page

2. Modify /plus/download.php

The modification method is as follows:

Find:

$row = $dsql->GetOne("Select $vname From ".$cu->ChannelInfos['addtable']." where aid='$aid'");
Copy after login

Add

if(!strstr($_SERVER['HTTP_REFERER'],$arcurl)) 
{ 
echo "<script language=&#39;javascript&#39;>location=\"$arcurl\";</script>"; 
}
Copy after login

above it and that’s it.

The above is the detailed content of How to prevent hotlinking in download.php of DreamWeaver download channel. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template