![]() |
Protecting NON-VB Pages.
Okay, I search for such a hack, found a couple, some work, and others don't even make any sense.
Basically this is what I want: 1) Protect pages, so a user must be registered to view it. 2) Say I put a link on my front page that leads to a file... how do I block non members from clicking the link, so the download doesn't start and they get directed to the login/register page? 3) When they log in it directs them to the page they were trying to view. I have an idea how to do it, but I want to make sure I am choosing the right method. I know I would need to put something like this in the head section of the page I want to protect: <?php chdir("forums/"); require("global.php"); if ($bbuserinfo[userid]==0) { blah, blah.. ?> am I close? ;) my main focus it protecting links so people can't download my files if they aren't registerd. thanks. |
Yes...
Code:
<?php Satan |
Hmm.. getting include errors.
This is how I have my pages: Code:
<?php Code:
<?php |
okay apparently i need more code than just that....
I only got it to work by setting FULL path starting from /home :( and after I tried to view the page it inserted the VB login page INSIDE the non VB page LOL it was messy, broken images etc.... I found this hack but it's way sloppy: https://vborg.vbsupport.ru/showthrea...threadid=36934 how do I protect links like attachments? so people can't download the files that are on no vb page? |
you can't protect those files really, except if you save em into the db as attachments :)
|
Sure you can.
You can put them outside directory-tree that comprises your web-space and have some php-file output them. I imagine this is exactly what PPN's 'attachments as files'-hack does. |
Xenon, where did your reply go? i got an email and i don't see it here ;) LOL
someone try to make this hack, i know it's possible just don't have the knowledge. |
Quote:
|
so can you make a working hack? :)
|
<a href="https://vborg.vbsupport.ru/showthread.php?threadid=46963" target="_blank">https://vborg.vbsupport.ru/showt...threadid=46963</a>
|
All times are GMT. The time now is 02:07 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|