Jump to content
xisto Community
Sign in to follow this  
squeaky

Asp On Trap17 To Make Password Protect Pages

Recommended Posts

I was wondering if I could use .asp pages on Xisto, because I am currently looking for a login script and all from my video pages. I've seen a script using .asp, but when I uploaded it and pointed my browser to it, it showed a download box. Would anyone happen to know of a place I can find a free login script? I've tried puma, and its great, but when iIview a protected page, I have to go to the main login page first, then i'm allowed to view the protected page. I don't want to have to login every single page I protect, and I want two access levels, of protected pages, like in puma, user and super user.

Share this post


Link to post
Share on other sites

Trap17 does not support ASP they have linux servers. ASP can be found on Windows servers. If you want a log in script you can use PHP which is like ASP. For tutorials on that go to http://www.pixel2life.com/ and search for a PHP tutorial. They show u what to do and how to edit it to your likings. Hopefully this has helped.

Share this post


Link to post
Share on other sites

There is another way of protecting files/directory. Using your cPanel you can "web protect" your site. This will open browser security login (very like the login you see for cPanel access site).Let's say you have file A, B, C and D you want to restrict from viewing. Place those files under folder called /secure or whatever. Your link to those files will be your-site.trap17.com/secure/A or your-site.com/secure/A etc.Anytime the link is clicked it will ask for security login and password since the whole directory to /secure is protected. This is one of easiest ways you can implement login and password without extra programming.Since squeaky didn't specify the whole "plan" of how and what should be protected, just to let you know that web protect has its limitation (such as maximum of 10 different login and password per direcoty). And since other possible obsticles were not represented by the topic starter this would be the best answer for your query.ASP requires license agreement which must be paid. Using PHP can result the same effect, if you know how. PHP is free. Xisto does not plan to impose the cost of implementing ASP or ASP.NET for Linux (license required) to Free Web Hosting, No Ads members.My professor used to tell me to K.I.S.S. = keep it simple, students (actually the last s is another word for "unintelligent" not that I am implying to anyone :D )

Share this post


Link to post
Share on other sites

trap is php base hosting

you must write php script

for more info about php login use this code :

 

Example Login file

<?php$username = "1"; // Username// Put Your Username in "user"$password = "1"; // Password// Put Your password in "pass"$randomword = "Farsi.Script";if (isset($_COOKIE['admincenter'])) {   if ($_COOKIE['admincenter'] == md5($password.$randomword)) {?>
And Here Insert HTMl code or you soruce

<?php	  exit;   } else {	  echo "<p align='right'><font face='Tahoma'  style='font-size: 8pt'>Bad Login , Please Delete Cookies</font></p>";	  exit;   }}if (isset($_GET['p']) && $_GET['p'] == "login") {   if ($_POST['name'] != $username) {	  echo "<p align=right><font face='Tahoma' style='font-size: 8pt'>Your username or password is not correct!</font></p>";	  exit;   } else if ($_POST['pass'] != $password) {	  echo "<p align=right><font face='Tahoma' ' style='font-size: 8pt'>Your username or password is not correct!</font></p>";	  exit;   } else if ($_POST['name'] == $username && $_POST['pass'] == $password) {	  setcookie('admincenter', md5($_POST['pass'].$randomword));	  header("Location: $_SERVER[PHP_SELF]");   } else {	  echo "<p align=right><font face='Tahoma' style='font-size: 8pt'>Your username or password is not correct!</font></p>";   }}?><form action="<?php echo $_SERVER['PHP_SELF']; ?>?p=login" method="post"><fieldset><label><font face='Tahoma' style='font-size: 8pt'>Username : </font></label> <input type="text" name="name" id="name" /><br /><label><font face='Tahoma'  style='font-size: 8pt'>Password : </font></label> <input type="password" name="pass" id="pass" /><br /><input type="submit" id="submit" value="Login" /></fieldset></form>

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.