Re: ファイルのダウンロード制限
2016年1月7日 at 8:07
ご返答ありがとうございます。
初心者でまだよくわかっていない部分が多いのですが、
何とか下記のカスタムで動作しました。
ありがとうございます。
<?php
global $u;
if($u->isLoggedIn()) { ?>
<div class="ccm-block-file"><a href="<?php echo ($forceDownload ? $f->getForceDownloadURL() : $f->getDownloadURL()); ?>" class="d_button"><?php echo stripslashes($controller->getLinkText()) ?></a></div>
<?php }else{ ?>
<div class="ccm-block-file"><a href="<?php echo $this->url('/login', 'forward'). '/' . $c->getCollectionID() . '/';?>" class="d_button"><?php echo stripslashes($controller->getLinkText()) ?></a></div>
<?php }
?>
タグ:
Your post has been saved and will be published after approval by the forum moderator.