April 20, 2024, 06:55:54 am
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Welcome to Revolution X, where Coding meets Graphics.
 
  Home Help Search Arcade Affiliates Staff List Calendar Members Login Register  

Password Protect webpage

Pages: [1]   Go Down
  Print  
Author Topic: Password Protect webpage  (Read 441 times)
0 Members and 1 Guest are viewing this topic.
Lyle
MeTube
Member
Member
Offline Offline

Gender: Male
Posts: 69



View Profile
Badges: (View All)
« on: June 13, 2009, 05:36:45 pm »

Well, i requested this to be made, and i got inpatient, and started thinking how i could get it to work...

i read thru http://www.w3schools.com and found out all of the stuff i needed for this

Script Title: Password Protect Webpage V1

Description: Password protect your site!

Example: No example available for this script.

Credit: Script created by Lyle
 

Copy the following code into your Webpage
AdminCP>Webpage Editor>new>HTMlButton>paste(CTRL+V)
Create the original webpage you want to be password protected
add all of the content you need/want
and paste this script under it

Code:
<script language="JavaScript">
<!--Password Protect Webpage V1 Script Created By Lyle//-->
<!--

var username = prompt("Enter Username In the Box Below","")
var password = prompt("Enter Password In the Box Below","")

if (username !="USERNAME HERE" || password !="PASSWORD HERE")

{ top.location="about:Bad Username and/or Password" }
//-->
</script>

After
Quote
var username = prompt("Enter Username In the Box Below","")
var password = prompt("Enter Password In the Box Below","")
where the "" are enter the username and password
Report Spam   Logged

Share on Facebook Share on Twitter

Andrew
Exclusive
Exclusive
Offline Offline

Gender: Male
Posts: 539



View Profile WWW
Badges: (View All)
Combination Topic Starter Poll Voter
« Reply #1 on: June 13, 2009, 06:31:44 pm »

Very nice, I think im gonna use this one on the moderation center Grin

EDIT:
I tried it on an EzBlock Page, and it didnt work.
« Last Edit: June 13, 2009, 06:34:58 pm by Andrew » Report Spam   Logged

Lyle
MeTube
Member
Member
Offline Offline

Gender: Male
Posts: 69



View Profile
Badges: (View All)
« Reply #2 on: June 13, 2009, 08:10:28 pm »

Very nice, I think im gonna use this one on the moderation center Grin

EDIT:
I tried it on an EzBlock Page, and it didnt work.
ill add that in V2 when i make it
Report Spam   Logged
Andrew
Exclusive
Exclusive
Offline Offline

Gender: Male
Posts: 539



View Profile WWW
Badges: (View All)
Combination Topic Starter Poll Voter
« Reply #3 on: June 13, 2009, 08:30:13 pm »

Im taking a guess that this ONLYS works in webpage editor right now? Not on the EzPortal pages?
I pretty much thought they were the same thing  Shocked
Report Spam   Logged

Lyle
MeTube
Member
Member
Offline Offline

Gender: Male
Posts: 69



View Profile
Badges: (View All)
« Reply #4 on: June 13, 2009, 09:20:30 pm »

you guessed correctly...i will add ezPortal pages in next version
Report Spam   Logged
Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by EzPortal
Bookmark this site! | Upgrade This Forum
SMF For Free - Create your own Forum

Powered by SMF | SMF © 2016, Simple Machines
Privacy Policy